What is llms.txt?
llms.txt is a markdown file served at /llms.txt that describes your site to AI systems in a form they can read cheaply: who you are, one line about what you do, and curated lists of links to the pages that matter. Think of it as a table of contents written for a reader with a token budget, rather than a sitemap written for a crawler with none.
It is a community convention, not a standard from a standards body, and no vendor is contractually obliged to read it. That is worth knowing before you plan around it. What it costs you is one static file; what it buys you is that a system which does look will find a clean index instead of guessing your structure from your navigation.
| File | Audience | What it says |
|---|---|---|
robots.txt | Crawlers | What you may and may not fetch |
sitemap.xml | Search crawlers | Every URL, with change metadata |
llms.txt | AI systems | The curated subset that matters, in prose |
The distinction from a sitemap is curation. A sitemap lists everything; an llms.txt lists what you would point a new colleague at. Publishing three hundred URLs in it defeats the purpose, because the file is only useful while it is cheaper to read than the site.
The llms.txt format, exactly
The shape is small enough to state completely: an H1 with the site name, a blockquote with a one-line description, then H2 sections containing markdown link lists. A link may carry a note after a colon.
# Basecamp Supply Co
> Independent outdoor gear shop. Packs, tents and trail equipment, shipped from Colorado.
## Products
- [Alpine Trail Pack 28L](https://basecamp-supply.example/products/alpine-trail-pack-28l): $148.00, in stock
- [Ridge Tent 2P](https://basecamp-supply.example/products/ridge-tent-2p): $329.00, in stock
## Policies
- [Shipping](https://basecamp-supply.example/policies/shipping): Free US shipping over $75
- [Returns](https://basecamp-supply.example/policies/returns): 60-day returns, unused with tags- One H1, at the top. Your site or organisation name, nothing else.
- One blockquote, immediately after. A single sentence a stranger could repeat back accurately.
- H2 sections with link lists. Group by what a reader would be looking for: products, docs, policies, guides.
- Absolute https URLs. A relative link in a file being read out of context is a dead link.
- Notes carry facts, not adjectives. "$148.00, in stock" earns its bytes; "our most popular pack" does not.
You can write one by hand, build one in the browser with the free generator, or have the gateway emit it from the same source of truth your pages render from. The last option is the one that does not drift: a hand-maintained index disagrees with the site within a quarter, and a disagreeing index is worse than none.
Does llms.txt actually work?
On its own, the evidence says no, and this is the part most guides skip. A 300k-domain study in mid-2026 found llms.txt alone produced no measurable citation lift. The same study measured content negotiation, answering the Accept header with clean text, at roughly 4.2x more effective for accurate retrieval.
- Content negotiation vs llms.txt, accurate retrieval
- ~4.2x
- 300k-domain study, mid-2026
- Context reduction, gateway markdown vs product-page HTML
- 98.6%
- Rebilder reference capture
The reason is structural rather than a matter of adoption. llms.txt tells a system where your pages are. It does nothing about what those pages return when the system goes and fetches one. If a product page answers with ninety kilobytes of theme HTML, a perfect index has done nothing except deliver the assistant more efficiently to the same wall.
What moves the number instead
If llms.txt is the index, content negotiation is the mechanism. An agent sends Accept: text/markdown; a server that understands the header answers with clean structured text rather than a rendered page. Same substance, different format, and the difference is measurable:
| Measure | Before: full product-page HTML | After: gateway markdown |
|---|---|---|
| Bytes | 91,226 | 1,315 (−98.6%) |
| Approx tokens | ~22,789 | ~328 |
| First price location | Character offset 23,185, inside a JSON blob | Line 4 |
Roughly 69× less context for the same facts, and the facts arrive front-loaded rather than recovered by markup archaeology. The full guide to this work covers the other levers, but the ordering is stable: unblock the fetch, answer the header, front-load the facts, then publish the index.
Four ways an llms.txt goes wrong
- It drifts. Written by hand in January, wrong by April. Generate it from the same data your pages render from, or accept that it will be a list of stale links.
- It lists everything. A file with hundreds of URLs stops being a curated map and becomes a sitemap in a worse format. Curate to what you would show a new colleague.
- It is unreachable. A CDN rule, an auth redirect, or a framework route that only matches after JavaScript will all make it a 404 to the systems it is for. Fetch it from a terminal to be sure.
- It is treated as the strategy. The measurable failure mode: the file gets published, the pages stay unreadable, and six months later the conclusion drawn is that AI search optimization does not work.