1. Home
  2. ChevronRightAdvanced
  3. ChevronRightMeta Loaders

Meta Loaders

Control sidebar groups with meta.json or _meta.json — per-directory metadata for titles, icons, order, and collapsible state.

Boltdocs automatically loads meta.json or _meta.json files from your docs directories to control sidebar group metadata without editing every individual page.


How It WorksLink

Place a meta.json file in any folder inside docs/. Boltdocs scans for these files at build time and applies the metadata to that directory's sidebar group.

docs/
├── guides/
│   ├── meta.json          ← applies to all guides/ pages
│   ├── index.md
│   ├── installation.md
│   └── configuration.md
└── api/
    ├── _meta.json         ← also works with underscore prefix
    └── reference.md

meta.json ReferenceLink

PropertyTypeDescription
titlestringDisplay name for this sidebar group.
orderstring[] | numberExplicit ordering — either a position number or an array of page slugs in desired order.
iconstringLucide icon name or raw SVG string for the group icon.
collapsiblebooleanWhether users can collapse/expand this group. Default: true.
collapsedbooleanWhether the group starts collapsed on page load. Default: false.

ExamplesLink

Basic Group ConfigurationLink

{
  "title": "Getting Started",
  "icon": "Rocket"
}

Collapsed by DefaultLink

{
  "title": "Advanced Topics",
  "collapsed": true,
  "collapsible": true
}

Custom OrderingLink

{
  "title": "Guide",
  "order": ["installation", "configuration", "deployment"]
}

Or use a numeric position:

{
  "title": "Guide",
  "order": 2
}

Full ExampleLink

docs/
├── (guides)/
│   ├── meta.json
│   ├── index.md
│   ├── installation.md
│   └── configuration.md
└── (api)/
    ├── meta.json
    └── reference.md

guides/meta.json:

{
  "title": "Guides",
  "icon": "BookOpen",
  "collapsible": true,
  "collapsed": false
}

api/meta.json:

{
  "title": "API Reference",
  "icon": "Code2",
  "collapsed": true
}

Difference Between meta.json and _meta.jsonLink

Both work identically. The underscore variant is useful when you want the file to be hidden from the docs but still loaded:

  • meta.json — Visible in some IDEs, may appear in file browsers
  • _meta.json — Excluded from routing like other underscore-prefixed paths

Use whichever fits your workflow.


PrecedenceLink

Meta.json settings are applied in this order (later overrides earlier):

  1. theme.sidebarGroups in config (global)
  2. meta.json / _meta.json in folder
  3. Frontmatter on folder's index.md (e.g., groupTitle, groupPosition)

DebuggingLink

If meta.json isn't taking effect:

  1. Verify the file is named exactly meta.json or _meta.json
  2. Check for valid JSON (no trailing commas)
  3. Ensure the file is inside a folder containing .md or .mdx files
  4. Check the console for "[Boltdocs] Failed to read meta.json" warnings
Last updated on July 27, 2026

Was this page helpful?