Docs

Frontmatter reference

Every supported frontmatter field.

The schema lives in src/content.config.ts and is enforced at build time — invalid frontmatter fails the build.

Fields#

FieldTypeDefaultDescription
titlestring(required)Shown as <h1> and in <title>.
descriptionstring—Subtitle on the page; used as <meta description>.
sidebar.labelstringtitleLabel in the sidebar.
sidebar.ordernumber999Sort key within a section; lower wins.
sidebar.hiddenbooleanfalseIf true, the page is omitted from the sidebar (still routable).
template"doc" | "splash""doc"Reserved for future use.

Example#

---
title: Configuring the cache
description: TTLs, eviction, and observability.
sidebar:
  label: Cache
  order: 30
---

Validation errors#

Astro will fail the build with a path and message:

[InvalidContentEntryFrontmatterError]
guides/cache.md:
  title: Required

Fix the frontmatter and re-run.