Skip to content

ButterIX v1 is out: versions, multiple languages, Ask AI, and a per-site MCP server, all built in. →

Navigation

Organize the sidebar with tabs, sections, pages, links, folders, changelogs, and API sections, and control every page's URL precisely.

Basic structure

There are two ways to write navigation:

navigation:
  - section: Get started
    slug: start
    contents:
      - page: Introduction
        path: pages/introduction.mdx
        slug: introduction
      - page: Quickstart
        path: pages/quickstart.mdx
        slug: quickstart

As long as every entry in navigation is a - tab:, it's treated as tabbed navigation; referencing an id not declared in tabs: reports a config/tab error. When versions or products are configured, navigation lives in their respective files (which also support tabs:, merged with the tabs in docs.yml).

Node types

Section

- section: Webhook
  slug: webhooks
  icon: lucide:webhook
  path: pages/webhooks/overview.mdx   # Optional: section overview page; its URL is the section itself
  collapsed: true                     # Collapsed by default
  tags: Beta                          # Tag next to the title
  contents:
    - page: Verify signatures
      path: pages/webhooks/verify.mdx
      slug: verify
sectionstringRequired
Section title; translated through labels.yml in non-default locales.
contentsNavItem[]
Child nodes, which can include further nested sections.
pathstring
Overview page. Clicking the section title opens it.
slugstring
The URL segment the section contributes; generated from the title by default.
skip-slugboolean
Don't contribute a URL segment; child pages hang directly under the parent level.
iconstring
Icon.
icon-styleplain | tileDefault plain
Icon style; see Icon style.
collapsedboolean
Collapsed by default.
hiddenboolean
Not shown in the sidebar; pages are still built.
tagsstring | string[]
Tags next to the title; see Tags. They can also go in the overview page's frontmatter.

Page

- page: Authentication
  path: pages/authentication.mdx
  slug: authentication
  icon: lucide:key-round
  tags: Beta
pagestringRequired
Sidebar title. The page frontmatter's title takes precedence as the page heading, and sidebar-title takes precedence as the sidebar title.
pathstringRequired
The page file, .mdx or .md, relative to the project root.
slugstring
The page's URL segment.
iconstring
Icon (can also be set with icon in frontmatter).
icon-styleplain | tileDefault plain
Icon style; see Icon style.
hiddenboolean
Not shown in the sidebar and excluded from previous / next links and llms.txt, but the page is still reachable by URL.
noindexboolean
Adds noindex and removes the page from the sitemap.
tagsstring | string[]
Tags next to the title; see Tags. They can also go in the page's frontmatter, which wins.

Tags

tags show next to a section or page title, for hints such as "New", "Beta" or "Free trial"; several rotate in turn. Tags also show after the page title.

- page: Billing
  path: pages/billing.mdx
  tags: [New, Free trial]
  tags-position: right
  tags-color: warning

Writing them in the page's frontmatter (a section's overview page, for a section) is preferred, with the same fields; when both are set, the frontmatter wins field by field. On a multilingual site, write each language's tags in the frontmatter of its translations; anything left out follows the source. To turn a source setting back to the default, write it out: tags-style: background, tags-position: inline or tags-color: theme. For the navigation, see Per-language navigation files.

Items in the brackets need no quotes. Quote an item when it contains a comma, a bracket, : or #, starts with a symbol such as *, &, ! or @, or is exactly true, false or null, e.g. [New, "Save 20, today"].

tagsstring | string[]
One or more tags. Several rotate in turn; text that doesn't fit rests for 2 seconds, then slides so readers can see all of it.
tags-positioninline | rightDefault inline
Position in the sidebar: inline right after the title, right at the right end of the row. After the page title they always follow the title.
tags-stylebackground | borderDefault background
Style: background is a light fill, border an outline.
tags-colorstring
Color; the theme color by default (or write theme). Use a Callout intent — note, info, warning, success, error, tip, check, launch, danger — for the same colors, or a color code such as "#e5484d" (quote it in YAML, since it starts with #).
tags-intervalnumberDefault 6
Seconds between tags. When a tag needs to slide, it finishes one round first.
tags-weightnumber
How many half-width characters of a tag to show; a CJK character counts as 2, so 8 fits about 4 CJK characters. Longer text slides. Without it, about 96px in the sidebar and 180px after the page title.

Icon style

An item's icon shows to the left of its title. With icon-style: tile, the icon sits in a small outlined square that fills with the accent color, with a white icon, on hover and on the current page: a way to set a few key entries apart from ordinary pages. Sections, pages, links, folders, changelogs, API sections and tabs (when shown in the sidebar) all take it; sidebar links use this style by default.

- page: Quickstart
  path: pages/quickstart.mdx
  icon: lucide:rocket
  icon-style: tile

Pages can also set it in their frontmatter. When both are set the navigation wins; write icon-style: plain there to switch back to the plain style.

icon-styleplain | tileDefault plain
plain shows just the icon, tile puts it in a small square. No effect without an icon.
- link: Status
  href: https://status.acme.com
  icon: lucide:activity

href can be an external URL or an internal path (for example, the link to /llms.txt at the bottom of this site's sidebar).

Folder

Generates a section automatically from a directory, with no need to register each page:

- folder: pages/tutorials
  title: Tutorials
  slug: tutorials
  collapsed: false
  • .md / .mdx files in the directory are sorted by file name; numeric file name prefixes (01-, 02_, 3.) are used only for sorting and are stripped from the URL and default title.
  • Page titles come from the frontmatter title, or the file name when absent (first letter capitalized, - / _ turned into spaces).
  • Subdirectories become nested sections, with titles generated from the directory names.

For example, with the configuration above under the "Guides" tab, pages/tutorials/01-install.mdx lives at /guides/tutorials/install.

Changelog

- changelog: changelog      # Directory
  title: Changelog
  slug: changelog
  icon: lucide:history

Every .md / .mdx file in the directory whose name starts with a date (YYYY-MM-DD, MM-DD-YYYY, or MM-DD-YY) is an entry; it generates a timeline index page, a detail page per day, and RSS / Atom / JSON feeds. blog: is an alias (default title "Blog"). See Changelog for how to write entries, the overview page, layouts (including the blog), search and filtering on the index page, and URL rules.

API section

- api: API Reference
  api-name: payments        # API id: unrelated to the URL; used for download URLs and snippet references
  openapi: openapi/payments.yml
  summary: pages/api/overview.mdx   # Optional: overview page body
  slug: reference
  tags: [Payments, Refunds]  # Optional: only include endpoints with these tags
  flattened: true            # Optional: don't group by tag
  collapsed: true
apistringRequired
Section title, also used as the title of the API overview page.
openapistringRequired
OpenAPI 3.x / Swagger 2 spec (YAML or JSON).
api-namestring
API id; generated from the title by default. The spec is published at /openapi/<api-name>.json and other URLs, and components like <EndpointRequestSnippet endpoint="<api-name>::POST /path"> use it to tell multiple APIs apart. Setting it explicitly is recommended when the title isn't ASCII.
summarystring
MDX body for the overview page; falls back to the spec's info.description when unset.
tagsstring[]
Only include groups with these OpenAPI tags.
flattenedboolean
List all endpoints directly under the section instead of grouping by tag; URLs don't include a group segment either.
slug / skip-slug / icon / icon-style / collapsed / hidden
Same as for sections.

See Import OpenAPI for details.

Hiding, collapsing, and status

Desired effectHow
Page exists but isn't in the sidebarhidden: true
Page exists but isn't indexed by search enginesnoindex: true (or noindex: true in page frontmatter)
Section collapsed by defaultcollapsed: true
Tab not shown in the headertabs.<id>.hidden: true
Show a tag such as "Beta" next to the titletags: Beta (several rotate: tags: [New, Free trial])

Slug rules

A page's final URL is made up of the following segments joined together (empty segments are omitted):

<basepath> / <locale> / <product> / <version> / <tab> / <section…> / <page>

Variant prefix

basepath, plus /<lang> for non-default locales, /<slug> for the product, and /<slug> for non-default versions. See Core concepts.

Tab segment

tabs.<id>.slug, generated from display-name by default; omitted with skip-slug: true.

Section segments

Each level of section contributes its slug (generated from the title by default), omitted with skip-slug: true. An API section's segment is omitted automatically when it's the same as its parent's (e.g. the "API Reference" section inside the "API Reference" tab).

Page segment

slug, generated from the page title in the navigation by default. A section overview page (path) has no segment of its own; its URL is the section's URL.

Generated from the title uses the same algorithm as GitHub heading anchors: lowercase, spaces become -, punctuation removed. Non-Latin characters such as Chinese are kept, so page: 快速开始 produces /快速开始 by default. Always set slug for non-Latin titles.

Override the full path with frontmatter

A slug in the page frontmatter replaces the tab, section, and page segments, keeping only the variant prefix:

pages/legacy/auth.mdx
---
title: Authentication (legacy)
slug: auth
---

No matter where it sits in the navigation, its URL is /auth in the default locale, /en/auth in English, and /v0/auth in v0.

Conflict detection

When two pages end up with the same URL, biti check reports a nav/duplicate-slug error and suggests setting an explicit slug on one of them.

URL examples from this site

Navigation positionURL
Guides › Get started › Quickstart/guides/get-started/quickstart
Components › Overview (section skip-slug)/components/overview
Components › Callouts and labels (section skip-slug) › Callouts/components/callout
API Reference › Platform API (skip-slug) › Sites › Create site/api-reference/sites/create-site
Changelog (tab skip-slug)/changelog
English › Quickstart/en/guides/get-started/quickstart
v0 › Quickstart/v0/guides/get-started/quickstart