Write content

Create documentation pages using MDX
View as Markdown

Documentation pages are written in MDX, which combines Markdown with React components. Create .mdx files in the docs/pages/ directory and reference them in your docs.yml navigation.

Basic page structure

docs/pages/my-page.mdx
1---
2title: Page title
3subtitle: Optional subtitle
4slug: my-page
5---
6
7Your content here. Use standard Markdown formatting like **bold**, *italic*, and `code`.
8
9## Headings
10
11Use headings to organize your content.

Using components

Fern provides built-in components for common documentation patterns:

Highlight important information with callouts.

Markdown
1<Note>
2Highlight important information with callouts.
3</Note>
4
5<CardGroup cols={2}>
6 <Card title="First card" href="/page-one">
7 Card description
8 </Card>
9 <Card title="Second card" href="/page-two">
10 Another description
11 </Card>
12</CardGroup>