Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .vale/styles/FernStyles/Acronyms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,4 @@ exceptions:
- MDX # Fern-specific
- SEO # Fern-specific
- AWS # Fern-specific
- LLM # Fern-specific
1 change: 1 addition & 0 deletions fern/products/docs/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@ navigation:
path: ./pages/seo/redirects.mdx
- page: llms.txt
path: ./pages/seo/llms-txt.mdx
slug: llms-txt
- section: Authentication
collapsed: true
contents:
Expand Down
59 changes: 30 additions & 29 deletions fern/products/docs/pages/seo/llms-txt.mdx
Original file line number Diff line number Diff line change
@@ -1,39 +1,40 @@
---
title: llms.txt
subtitle: Enable tools like Cursor, GitHub Copilot, ChatGPT, and Claude to quickly understand your documentation.
description: Learn how your documentation becomes accessible to AI tools using the llms.txt standard. Make your docs AI-friendly.
layout: guide
title: llms.txt and llms-full.txt
description: Enable tools like Cursor, GitHub Copilot, ChatGPT, and Claude to understand your documentation.
---

## What is llms.txt?
[LLMs.txt](https://llmstxt.org/) is an emerging standard so that websites can easily expose information to AI developer tools.
LLMs thrive on concise, structured information, and `llms.txt` help them locate and interpret key information in your developer documentation with ease.
No configuration required--your `llms.txt` files are automatically generated and maintained, just like a `sitemap.xml` or `robots.txt`.

### llms.txt
- **Small and fast**: Quick to load and easy to parse.
- **Summary-focused**: Each page distilled into a one-sentence description with its URL.
- **Structured for AI**: Helps tools understand the overall structure of your documentation.

See an example: [docs.cohere.com/llms.txt](https://docs.cohere.com/llms.txt)

### llms-full.txt
- **Comprehensive**: Includes the full content of your documentation.
- **API-Ready**: Automatically incorporates your full API reference and SDK snippets (if generated by Fern).
- **Token efficient**: Removes unnecessary formatting to be as token-efficient as possible.

See an example: [docs.cohere.com/llms-full.txt](https://docs.cohere.com/llms-full.txt)

## View in Action

Check out the llms.txt files for this site:
- `https://buildwithfern.com/learn/llms.txt`
- `https://buildwithfern.com/learn/llms-full.txt`
[llms.txt](https://llmstxt.org/) is a standard for exposing website content to AI developer tools. Fern automatically generates and maintains `llms.txt` and `llms-full.txt` files for your documentation site. When Fern detects an LLM bot accessing your documentation, it automatically serves Markdown instead of HTML, reducing token consumption by 90%+.

<Frame>
<img
src="./llms-txt.png"
alt="Example of using llms.txt"
className="rounded-lg border border-gray-200 dark:border-gray-700"
/>
</Frame>
</Frame>

## `llms.txt`

Contains a lightweight summary of your documentation site with each page distilled into a one-sentence description and URL. The format is structured to help AI tools parse and understand your documentation's hierarchy and organization.

`llms.txt` is available at any level of your documentation hierarchy (`/llms.txt`, `/docs/llms.txt`, `/v1/api-reference/llms.txt`, etc.).

Examples from Eleven Labs:
- Developer documentation (Prompting directory): [elevenlabs.io/docs/best-practices/prompting/llms.txt](https://elevenlabs.io/docs/best-practices/prompting/llms.txt)
- API Reference (Create speech endpoint): [elevenlabs.io/docs/api-reference/text-to-speech/convert/llms.txt](https://elevenlabs.io/docs/api-reference/text-to-speech/convert/llms.txt)

## `llms-full.txt`

Contains complete documentation content including the full text of all pages. For API documentation, this includes your complete API Reference with resolved OpenAPI specifications and SDK code examples for enabled languages. Each API endpoint page includes its full OpenAPI spec.

`llms-full.txt` is available only at the root of your documentation site.

Example from Cash App: [developers.cash.app/llms-full.txt](https://developers.cash.app/llms-full.txt)

## Analytics and monitoring

The [Fern Dashboard](https://dashboard.buildwithfern.com/) provides comprehensive analytics for `llms.txt` usage including:
- Traffic by LLM provider (Claude, ChatGPT, Cursor, etc.)
- Page-level breakdowns of bot vs. human visitors for Markdown and `llms.txt` files

This visibility helps you understand LLM traffic patterns and optimize your documentation for AI consumption.