What is sectioned navigation in Hygraph and when should I use it?
Sectioned navigation in Hygraph is a content model that organizes navigation items into clusters or subjects using enumerations and nested components. It's ideal for large projects where you need to group navigation items for better structure and scalability. Note: For smaller projects, a simpler navigation model may be more appropriate.
What are the prerequisites for building sectioned navigation in Hygraph?
You need a Hygraph account and an active project. You can create a new project, clone the Navigation Cookbook project, or use an existing project (with possible schema adjustments). Plan limits may affect how many recipes you can add. Note: Adjustments may be needed if integrating into an existing schema.
What schema elements are used in sectioned navigation?
Sectioned navigation uses enumerations (for theme selection), reusable components (navigation item and navigation section), references (to link to other models like Product, Blog, Store), and fields such as slugs and booleans. This modular approach allows for flexible and scalable navigation structures. Note: Overly complex navigation may not be necessary for simple sites.
How do I implement sectioned navigation in Hygraph?
Follow these steps: 1) Create models (e.g., Product, Blog, Store, Sectioned Navigation), 2) Create a theme enumeration (e.g., Light, Dark), 3) Build components (Navigation item and Navigation section), 4) Add fields to the Sectioned Navigation model (slug for ID, sections, theme). You can follow the step-by-step guide or clone the Navigation Cookbook project for a ready-made schema. Note: Customization may be required for your specific use case.
What are enumerations and how are they used in navigation models?
Enumerations in Hygraph are predefined sets of values (e.g., Light, Dark themes) that can be used as dropdown options in your navigation model. They help standardize options and simplify configuration. For more, see the Enumerations documentation. Note: Enumerations are best for fixed option sets; frequent changes may require a different approach.
How do components work in sectioned navigation?
Components are reusable sets of fields. In sectioned navigation, you create a Navigation item component (with fields like link label, new item toggle, references, and external link) and a Navigation section component (with section title and navigation items). This allows you to nest navigation items within sections for flexible navigation structures. See the Components documentation for details. Note: Overuse of nested components can increase schema complexity.
Can I add both internal and external links in sectioned navigation?
Yes, the Navigation item component supports both internal links (via references to models like Product, Blog, Store) and external links (via a slug field with URL validation). You can choose which to use for each navigation item. Note: Only one link type should be used per item to avoid confusion.
Is there a way to quickly get started with sectioned navigation without building from scratch?
Yes, you can clone the Navigation Cookbook project, which contains all navigation recipes, including sectioned navigation. This allows you to explore and compare different navigation configurations without manual setup. Access the clone link in the guide or clone the project here. Note: You may need to adapt the cloned schema to your project's requirements.
Where can I find more resources or documentation about navigation models in Hygraph?
What are the key features of Hygraph that support advanced navigation and content management?
Hygraph offers a GraphQL-native architecture, content federation, reusable components, enumerations, references, and support for both internal and external links. It also provides enterprise-grade features like granular permissions, localization, and Smart Edge Cache. Note: Some advanced features may require higher-tier plans or additional configuration.
Does Hygraph support integrations with other platforms?
Yes, Hygraph integrates with platforms such as Aprimo, AWS S3, Bynder, Cloudinary, Imgix, Mux, Scaleflex Filerobot, Netlify, Vercel, Akeneo, Adminix, Plasmic, BigCommerce, and EasyTranslate. For a full list, visit the Hygraph Marketplace. Note: Integration setup may require technical configuration.
What APIs does Hygraph provide for content and navigation management?
Hygraph provides a GraphQL Content API (for querying and manipulating content), a Management API (for project structure), an Asset Upload API, and an MCP Server API for AI assistant integration. See the API Reference documentation for details. Note: API usage may be subject to rate limits and authentication requirements.
Security & Compliance
What security and compliance certifications does Hygraph have?
Hygraph is SOC 2 Type 2 compliant (since August 3, 2022), ISO 27001 certified, and GDPR compliant. These certifications ensure high standards for information security and data privacy. For more, see the Secure Features page. Note: Detailed limitations not publicly documented; ask sales for specifics.
Implementation & Onboarding
How long does it take to implement Hygraph and get started with navigation models?
Implementation time varies by project complexity. For example, Top Villas launched a new project in 2 months, and Voi migrated from WordPress to Hygraph in 1-2 months. Hygraph offers structured onboarding, starter projects, and extensive documentation to accelerate adoption. Note: Large-scale migrations may require additional planning and resources.
Use Cases & Success Stories
Who can benefit from using Hygraph for navigation and content management?
Hygraph serves developers, content creators, product managers, and marketing professionals in enterprises and high-growth companies across industries like SaaS, eCommerce, media, healthcare, automotive, and more. Its flexibility supports both technical and non-technical users. Note: Small teams with basic needs may find simpler CMS solutions sufficient.
What are some real-world examples of companies using Hygraph?
Notable customers include Samsung (15% improved engagement), Komax (3x faster time-to-market), AutoWeb (20% increase in monetization), Voi (scaled content in 12 countries), and Dr. Oetker (enhanced digital experience). See more at the case studies page. Note: Results may vary by implementation and use case.
Pain Points & Limitations
What common challenges does Hygraph address for navigation and content management?
Hygraph helps reduce developer dependency, modernize legacy tech stacks, ensure content consistency, streamline workflows, lower operational costs, and accelerate speed-to-market. It also simplifies schema evolution and integration with third-party systems. Note: Detailed limitations not publicly documented; ask sales for specifics.
This guide shows how to build a sectioned navigation using enumerations and nested components.
Our sectioned navigation will be a content model containing an ID, nested components for sections and navigation items, and a dropdown to select styling options. This way, to create a navigation using this configuration, you can create a content entry with its own ID, and as many navigation items as you need.
This navigation model is a good choice for large projects where you need to group your navigation items into clusters or specific subjects.
REQUIRED: You need to have a Hygraph account. If you don't have one, you can sign up here.
REQUIRED: You need to have a Hygraph project.
OPTION 1:Create a project. This is the way to go if you want to follow the entire tutorial for learning purposes.
OPTION 2:Clone the cookbook project. This is the way to go if you're curious about how the Navigation elements are made but don't want to follow the step-by-step creation process. This project contains the entire Navigation Cookbook so you can compare them, or look into what instances they contain.
OPTION 3:Use an existing project of yours. If you have a project already and want to add this Navigation to it, this is the way to go. In this case, you may need to adjust parts of the tutorial to your own project schema.
Take plan limits into consideration when adding a recipe to your own project.
In this guide, you'll work with enumerations, references, components and basic component fields. Let's look into these concepts:
Enumerations: an enumeration is a predefined set of values that represents a list of possible options. You can use them to group values within a type.
Component: a predefined set of fields that can be reused across models and content entries. You can think of a component as a flexible, reusable template: you define the fields that will be used inside a component once, and then fill them with different content every time you use it in a content entry.
Basic component field: a component is a special field type in your Hygraph schema that defines which components of which type can be used in a model. Component fields can be of basic or modular types. A basic component field can only have one component attached to it. You can limit the number of component instances to one, or allow multiple component instances to be added in the content entry.
References: References are relations between two or more content entries in your project. With references, you can reuse content entries by connecting them. Once the relation is configured, you can also use it to create related content from the content creation screen.
Path 1: Use this guide to create a sectioned navigation that you can use in your Hygraph projects.
Path 2: Clone the project that contains the entire Navigation cookbook to compare the different navigation configurations without having to clone multiple projects.
This cookbook contains all the recipes we have so far to create navigation elements, so you can compare the different navigation configurations without having to clone multiple projects.
To find this particular recipe in the cookbook project, navigate to the schema and look for "Sectioned Navigation".
We'll start by creating three sample models - Product, Store, and Blog - that we will use as referenceable models later to create our navigation items.
Pro Tip
In a real situation, you would use actual content models that you planned and built for your project, but for the sake of this example, we will simply create three empty content models so we can later on reference them.
We'll click + Add next to Models and use the following information:
Field
Input
Display Name
Product
API ID
Product
API ID Plural
Products
Create the models
We'll click Add Model to save.
Normally, we'd add fields to these models, but for the sake of this example, we'll simply leave them empty.
Repeat the process to create a second model:
Field
Input
Display Name
Blog
API ID
Blog
API ID Plural
Blogs
We'll click Add Model to save.
And one final time for our third model:
Field
Input
Display Name
Store
API ID
Store
API ID Plural
Stores
We'll click Add Model to save.
Finally, we will create one more model for our sectioned navigation, using the following information:
Field
Input
Display Name
Sectioned navigation
API ID
SectionedNavigation
API ID Plural
SectionedNavigations
We'll click Add Model to save. This model won't stay empty, but before we can start adding fields to it, we need to build an enumeration and a component.
We want our navigation to have nested components. We will create a navigation item component that will allow us to add multiple links to our navigation. We will then nest this component into a navigation section component. The objective is to be able to add several sections with links.
The first component that we will create is the Navigation item component. We'll click + Add next to Components and add it using this information:
Field
Input
Display Name
Navigation item
API ID
NavigationItem
API ID Plural
NavigationItems
Navigation item component
We'll click Add component to save. We can now start adding instances to this component.
We'll start by adding a Single line text field by clicking on it on the Add fields right sidebar.
We'll use the following information:
Tab
Field
Input
Settings
Display Name
Link label
Settings
API ID
linkLabel
Settings
Use as title field checkbox
Select this checkbox
Validations
Make field required checkbox
Select this checkbox
Navigation item component - Link label
We'll click Add to save. This field will let us add a label to our links.
Next, we want our navigation to indicate if an item is new. To do this, we'll add a boolean field using the following information:
Tab
Field
Input
Settings
Display Name
New item toggle
Settings
API ID
newItemToggle
Navigation item component - Toggle
We'll click Add to save.
We want our navigation to offer the possibility to add both internal and external links. We'll add a reference for the internal links, and a slug field for the external ones. In this case, we won't be making them required fields, because users will either use one or the other.
We'll start with the reference field. We'll find the Reference field on the Add fields right sidebar, click on it, and use the following information:
Tab
Field
Input
Define
Reference type
Select Allow multiple models to be referenced (Union Type)
Define
Models to reference
Use the dropdown menu to select Product, Blog and Store
Define
Reference direction
Select One-way reference
Define
Relation cardinality
Select One to One
Configure reference
Display Name
Page
Configure reference
API ID
page
Navigation item component - Reference
We'll click Add to save. We've configured the reference in such a way that when we find this field in a content entry, it will allow us to select an entry from the models that we configured.
Finally, we'll add a slug field for our external URLs, using the following information:
Tab
Field
Input
Settings
Display Name
External Link
Settings
API ID
externalLink
Settings
Lowercase checkbox
Leave this checkbox selected
Validations
Set field as unique checkbox
Leave this checkbox selected
Validations
Match a specific pattern checkbox
Leave this checkbox selected, and use the dropdown to select the URL pattern. Write "Input value does not match the expected format." in the Custom error message field.
Navigation item component - External URL
We'll click Add to save.
Now that we created our Navigation item component, we can start working on our Navigation section component.
We'll click + Add next to Components and add it using this information:
Field
Input
Display Name
Navigation section
API ID
NavigationSection
API ID Plural
NavigationSections
Navigation section component
We'll click Add component to save. We can now start adding instances to this component.
We'll add a Single line text field by clicking on it on the Add fields right sidebar and using the following information:
Tab
Field
Input
Settings
Display Name
Section title
Settings
API ID
sectionTitle
Settings
Use as title field checkbox
Select this checkbox
Validations
Make field required checkbox
Select this checkbox
Navigation section component - Title
We'll click Add to save. This field will let us add a title to our navigation sections.
Now it is time to add the navigation item component that we created earlier. We'll click on the Basic component field in the Add fields right sidebar and use the following information:
Tab
Field
Input
Settings
Display Name
Navigation items
Settings
API ID
navigationItems
Settings
Allow multiple values checkbox
Select this checkbox
Settings
Select component
Use the dropdown to select the "Navigation item" component
Navigation section component - Navigation item
We'll click Add to save.
In this case, we've allowed multiple values, because that way we can add as many links as we want to our navigation section.
We'll go back into our Sectioned Navigation model now, to add fields to it. The reason we're creating this navigation as a model, is so that we can then create an entry per navigation that we want to build using this configuration.
First, we will add a slug field that will be our navigation ID. We'll click on the Slug field in the Add fields right sidebar and use the following information:
Tab
Field
Input
Settings
Display Name
Navigation ID
Settings
API ID
navigationId
Settings
Lowercase checkbox
Leave this checkbox selected
Settings
Use as title field checkbox
Select this checkbox
Validations
Set field as unique checkbox
Leave this checkbox selected
Validations
Match a specific pattern checkbox
Leave this checkbox selected, and use the dropdown to select the Slug pattern. Write "Input value does not match the expected format." in the Custom error message field.
Sectioned navigation model - Navigation ID
We'll click Add to save.
Now it is time to add the Navigation section component that we created earlier. We'll click on the Basic component field in the Add fields right sidebar and use the following information:
Tab
Field
Input
Settings
Display Name
Sections
Settings
API ID
sections
Settings
Allow multiple values checkbox
Select this checkbox
Settings
Select component
Use the dropdown to select the "Navigation section" component
Sectioned navigation model - Sections
We'll click Add to save. In this case, we've allowed multiple values, because that way we can add as many links as we want to our navigation.
Finally, we'll add the theme enumeration that we created earlier. We'll find the Enumeration field on the Add fields sidebar, and add it using this information:
Tab
Field
Input
Settings
Display Name
Theme
Settings
API ID
theme
Settings
Enumeration
Select "Navigation theme" from the dropdown menu
Sectioned navigation model - Theme
We'll click Add to save.
Pro Tip
We've created a sectioned navigation model that contains enumerations, components, as well as other schema elements, and that allows you to add internal content entries and external links.
You could potentially use this model to create different navigation elements for your project.
Our sectioned navigation model should look like this:
Sectioned navigation
This guide helped you create the schema element yourself. Alternatively, you can clone a project containing all our navigation recipes.
This guide shows how to build a sectioned navigation using enumerations and nested components.
Our sectioned navigation will be a content model containing an ID, nested components for sections and navigation items, and a dropdown to select styling options. This way, to create a navigation using this configuration, you can create a content entry with its own ID, and as many navigation items as you need.
This navigation model is a good choice for large projects where you need to group your navigation items into clusters or specific subjects.
REQUIRED: You need to have a Hygraph account. If you don't have one, you can sign up here.
REQUIRED: You need to have a Hygraph project.
OPTION 1:Create a project. This is the way to go if you want to follow the entire tutorial for learning purposes.
OPTION 2:Clone the cookbook project. This is the way to go if you're curious about how the Navigation elements are made but don't want to follow the step-by-step creation process. This project contains the entire Navigation Cookbook so you can compare them, or look into what instances they contain.
OPTION 3:Use an existing project of yours. If you have a project already and want to add this Navigation to it, this is the way to go. In this case, you may need to adjust parts of the tutorial to your own project schema.
Take plan limits into consideration when adding a recipe to your own project.
In this guide, you'll work with enumerations, references, components and basic component fields. Let's look into these concepts:
Enumerations: an enumeration is a predefined set of values that represents a list of possible options. You can use them to group values within a type.
Component: a predefined set of fields that can be reused across models and content entries. You can think of a component as a flexible, reusable template: you define the fields that will be used inside a component once, and then fill them with different content every time you use it in a content entry.
Basic component field: a component is a special field type in your Hygraph schema that defines which components of which type can be used in a model. Component fields can be of basic or modular types. A basic component field can only have one component attached to it. You can limit the number of component instances to one, or allow multiple component instances to be added in the content entry.
References: References are relations between two or more content entries in your project. With references, you can reuse content entries by connecting them. Once the relation is configured, you can also use it to create related content from the content creation screen.
Path 1: Use this guide to create a sectioned navigation that you can use in your Hygraph projects.
Path 2: Clone the project that contains the entire Navigation cookbook to compare the different navigation configurations without having to clone multiple projects.
This cookbook contains all the recipes we have so far to create navigation elements, so you can compare the different navigation configurations without having to clone multiple projects.
To find this particular recipe in the cookbook project, navigate to the schema and look for "Sectioned Navigation".
We'll start by creating three sample models - Product, Store, and Blog - that we will use as referenceable models later to create our navigation items.
Pro Tip
In a real situation, you would use actual content models that you planned and built for your project, but for the sake of this example, we will simply create three empty content models so we can later on reference them.
We'll click + Add next to Models and use the following information:
Field
Input
Display Name
Product
API ID
Product
API ID Plural
Products
Create the models
We'll click Add Model to save.
Normally, we'd add fields to these models, but for the sake of this example, we'll simply leave them empty.
Repeat the process to create a second model:
Field
Input
Display Name
Blog
API ID
Blog
API ID Plural
Blogs
We'll click Add Model to save.
And one final time for our third model:
Field
Input
Display Name
Store
API ID
Store
API ID Plural
Stores
We'll click Add Model to save.
Finally, we will create one more model for our sectioned navigation, using the following information:
Field
Input
Display Name
Sectioned navigation
API ID
SectionedNavigation
API ID Plural
SectionedNavigations
We'll click Add Model to save. This model won't stay empty, but before we can start adding fields to it, we need to build an enumeration and a component.
We want our navigation to have nested components. We will create a navigation item component that will allow us to add multiple links to our navigation. We will then nest this component into a navigation section component. The objective is to be able to add several sections with links.
The first component that we will create is the Navigation item component. We'll click + Add next to Components and add it using this information:
Field
Input
Display Name
Navigation item
API ID
NavigationItem
API ID Plural
NavigationItems
Navigation item component
We'll click Add component to save. We can now start adding instances to this component.
We'll start by adding a Single line text field by clicking on it on the Add fields right sidebar.
We'll use the following information:
Tab
Field
Input
Settings
Display Name
Link label
Settings
API ID
linkLabel
Settings
Use as title field checkbox
Select this checkbox
Validations
Make field required checkbox
Select this checkbox
Navigation item component - Link label
We'll click Add to save. This field will let us add a label to our links.
Next, we want our navigation to indicate if an item is new. To do this, we'll add a boolean field using the following information:
Tab
Field
Input
Settings
Display Name
New item toggle
Settings
API ID
newItemToggle
Navigation item component - Toggle
We'll click Add to save.
We want our navigation to offer the possibility to add both internal and external links. We'll add a reference for the internal links, and a slug field for the external ones. In this case, we won't be making them required fields, because users will either use one or the other.
We'll start with the reference field. We'll find the Reference field on the Add fields right sidebar, click on it, and use the following information:
Tab
Field
Input
Define
Reference type
Select Allow multiple models to be referenced (Union Type)
Define
Models to reference
Use the dropdown menu to select Product, Blog and Store
Define
Reference direction
Select One-way reference
Define
Relation cardinality
Select One to One
Configure reference
Display Name
Page
Configure reference
API ID
page
Navigation item component - Reference
We'll click Add to save. We've configured the reference in such a way that when we find this field in a content entry, it will allow us to select an entry from the models that we configured.
Finally, we'll add a slug field for our external URLs, using the following information:
Tab
Field
Input
Settings
Display Name
External Link
Settings
API ID
externalLink
Settings
Lowercase checkbox
Leave this checkbox selected
Validations
Set field as unique checkbox
Leave this checkbox selected
Validations
Match a specific pattern checkbox
Leave this checkbox selected, and use the dropdown to select the URL pattern. Write "Input value does not match the expected format." in the Custom error message field.
Navigation item component - External URL
We'll click Add to save.
Now that we created our Navigation item component, we can start working on our Navigation section component.
We'll click + Add next to Components and add it using this information:
Field
Input
Display Name
Navigation section
API ID
NavigationSection
API ID Plural
NavigationSections
Navigation section component
We'll click Add component to save. We can now start adding instances to this component.
We'll add a Single line text field by clicking on it on the Add fields right sidebar and using the following information:
Tab
Field
Input
Settings
Display Name
Section title
Settings
API ID
sectionTitle
Settings
Use as title field checkbox
Select this checkbox
Validations
Make field required checkbox
Select this checkbox
Navigation section component - Title
We'll click Add to save. This field will let us add a title to our navigation sections.
Now it is time to add the navigation item component that we created earlier. We'll click on the Basic component field in the Add fields right sidebar and use the following information:
Tab
Field
Input
Settings
Display Name
Navigation items
Settings
API ID
navigationItems
Settings
Allow multiple values checkbox
Select this checkbox
Settings
Select component
Use the dropdown to select the "Navigation item" component
Navigation section component - Navigation item
We'll click Add to save.
In this case, we've allowed multiple values, because that way we can add as many links as we want to our navigation section.
We'll go back into our Sectioned Navigation model now, to add fields to it. The reason we're creating this navigation as a model, is so that we can then create an entry per navigation that we want to build using this configuration.
First, we will add a slug field that will be our navigation ID. We'll click on the Slug field in the Add fields right sidebar and use the following information:
Tab
Field
Input
Settings
Display Name
Navigation ID
Settings
API ID
navigationId
Settings
Lowercase checkbox
Leave this checkbox selected
Settings
Use as title field checkbox
Select this checkbox
Validations
Set field as unique checkbox
Leave this checkbox selected
Validations
Match a specific pattern checkbox
Leave this checkbox selected, and use the dropdown to select the Slug pattern. Write "Input value does not match the expected format." in the Custom error message field.
Sectioned navigation model - Navigation ID
We'll click Add to save.
Now it is time to add the Navigation section component that we created earlier. We'll click on the Basic component field in the Add fields right sidebar and use the following information:
Tab
Field
Input
Settings
Display Name
Sections
Settings
API ID
sections
Settings
Allow multiple values checkbox
Select this checkbox
Settings
Select component
Use the dropdown to select the "Navigation section" component
Sectioned navigation model - Sections
We'll click Add to save. In this case, we've allowed multiple values, because that way we can add as many links as we want to our navigation.
Finally, we'll add the theme enumeration that we created earlier. We'll find the Enumeration field on the Add fields sidebar, and add it using this information:
Tab
Field
Input
Settings
Display Name
Theme
Settings
API ID
theme
Settings
Enumeration
Select "Navigation theme" from the dropdown menu
Sectioned navigation model - Theme
We'll click Add to save.
Pro Tip
We've created a sectioned navigation model that contains enumerations, components, as well as other schema elements, and that allows you to add internal content entries and external links.
You could potentially use this model to create different navigation elements for your project.
Our sectioned navigation model should look like this:
Sectioned navigation
This guide helped you create the schema element yourself. Alternatively, you can clone a project containing all our navigation recipes.