Technical Protocol Guide

What is the llms.txt Standard?

An in-depth look at the emerging AI sitemap convention. Learn how a simple text file at your root directory can drastically improve how LLM agents and coding assistants index your site.

1. The AI-Sitemap Concept

Traditional search bots crawl the web using HTML page parses and classic XML sitemaps. However, Large Language Models (LLMs) and autonomous AI developer agents process information differently.

When an AI-powered coding assistant (like Cursor or custom developer agents) attempts to learn a new framework or library from online documentation, it has to scrape and parse standard HTML. This comes with major downsides:

  • Clutter & Noise: Navigation headers, footers, sidebars, advertisements, and cookie consent overlays add irrelevant tokens.
  • Token Waste: Crawling hundreds of small, separate HTML files consumes vast context window space and increases developer API bills.
  • Slicing Problems: Scraping code snippets often separates context descriptions from actual code.

The llms.txt proposal is a community-driven convention to solve this. Placed at the root of a domain (e.g., https://example.com/llms.txt), it acts as an index that guides LLM parsers to clean, raw Markdown files containing the core content, bypassing all website wrapper markup.

Community Driven

Popularized by teams like Answer.ai, the llms.txt file is designed to be a lightweight "sitemap for AI". It allows you to specify a clean API for crawlers looking to ingest your site's knowledge base.

2. The File Specification

The specification defines the `llms.txt` file as a simple plain-text file formatted in standard Markdown. It is organized into three distinct parts:

  1. H1 Title (`#`): The name of the project, library, or website.
  2. Blockquote (`>`): A concise summary of the project and what information the site contains. This serves as the high-level system prompt indicator for crawling bots.
  3. H2 Sections (`##`) and Link Lists: Labeled groups of links pointing to the actual documentation files. Each link is written as standard Markdown [Name](url) followed by a short description. These linked pages should ideally serve raw, clean Markdown text rather than full-blown HTML.

The companion file (`llms-full.txt`): In addition to the index, sites are encouraged to host an llms-full.txt file. This companion file bundles the entire documentation base into a single, flattened Markdown file. AI agents can read this single file to get up-to-speed on the entire site without making dozens of individual network calls.

3. Adoption & Support

To understand the value of `llms.txt`, it is important to separate formal standards from actual developer adoption:

The Limitations

No major search engine or foundational model provider (such as OpenAI or Google) officially enforces `llms.txt` as a required standard. It is not currently utilized as a ranking factor or general search index instructions file in the way robots.txt is.

The Reality

Despite lacking formal web-standard status, `llms.txt` has seen explosive adoption among major tech companies and developer platforms. Brands like Anthropic, Stripe, Vercel, Supabase, Cloudflare, and LangChain actively host `llms.txt` files on their sites.

Why? Because AI code assistants (like Cursor, Cline, and LLM-driven command-line interfaces) are explicitly programmed to search for `/llms.txt` when users ask them to reference external documentation. Providing this file dramatically improves the code-generation accuracy for developers working with your APIs.

4. Standard Examples

Here is what a standard, valid `llms.txt` index file looks like:

# LLMAO API Docs
> A plain-English documentation hub for AI search engine optimizations.

## Getting Started
- [Beginner's Guide](/start-here/beginners-guide.md): The core guide to AEO and GEO.
- [AI Search Checklist](/tools/ai-checklist.md): Practical steps to verify crawlability.

## Advanced Guides
- [AEO vs GEO vs SEO](/guides/aeo-vs-geo-vs-seo.md): Comparing optimization layers.
- [Schema Markup for AI](/guides/schema.md): Implementing JSON-LD structured data.

5. Auto-Generating the Files

You do not need to maintain your `llms.txt` and `llms-full.txt` files manually. If your website is built on a markdown-centric generator, you can automate this:

  • Static Site Generators: Community plugins exist for popular builders like Docusaurus, VitePress, Astro, and Next.js that compile your markdown pages into a flat `/llms.txt` map automatically during build time.
  • CMS Integrations: WordPress and Drupal have community modules that output taxonomies and post content into raw text feeds.
  • Crawl APIs: Third-party scrapers (like Firecrawl or Mendable) can scan your public HTML pages, strip the markup, and output compiled `llms.txt` structures automatically.

6. Implementation Checklist

If you decide to deploy `llms.txt` to help AI agents understand your content, use this verification checklist:

The file is uploaded directly to the root directory and is publicly accessible at /llms.txt.
Verified that the file uses standard H1, blockquote, and list structures without custom HTML wrappers.
Links in the file point to clean, raw markdown files (.md) or distraction-free pages instead of busy HTML layouts.
Compiled all linked resources into a single, flattened file hosted at /llms-full.txt.
Configured a build script or plugin to regenerate the files automatically whenever the site content changes.