llms.txt best practices
Agent Web Map validates and scores every llms.txt it lists. These rules are what separates files that score well from files that are rejected or ranked low.
1. Make it a real text file
The single most common failure: the server returns the site's HTML app shell with a 200 status for any unknown path, so /llms.txt "exists" but is a web page. Serve the file with Content-Type: text/plain; charset=utf-8 (or text/markdown), and check it with curl -i https://yoursite/llms.txt.
2. Start with the H1 and the blockquote
The H1 is required and is what directories and agents use as your title. The blockquote right after it is the summary an agent reads first; write it for a reader who has never heard of you: what you are, for whom, what the docs cover.
3. Link to your own pages with absolute HTTPS URLs
Group links under H2 headings. Each link gets a short description after a colon. Use absolute URLs on your own domain; relative links and links that redirect elsewhere are skipped by many readers. Dead links cost quality: keep them working.
4. Keep it on the canonical domain
If example.us redirects wholesale to example.com, publish the file on example.com and let the alias redirect. A domain that only redirects elsewhere is not a publisher of its own.
5. Don't copy a template verbatim
A file that is identical across many unrelated sites reads as boilerplate, to directories and to agents alike. Language versions on separate domains are fine when they differ; write the French file in French.
6. Publish llms-full.txt too, if you can
One Markdown file with the complete documentation. Agents that want everything fetch it once; it also adds to the quality score.
7. Use ## Optional for the long tail
Readers with little context budget stop before the Optional section. Put changelogs, archives and legal pages there.
8. Keep it current
Freshness is part of the score, and files are re-checked over time. Verified owners get an alert when theirs breaks.
9. Mind the size
A few hundred bytes is too thin; a huge single line of data is not Markdown. Most good files are 1 to 20 KB.
10. Verify ownership
Add the verification line to your file (it links here, which is also how it proves ownership), then call the verify endpoint. sorted first in every listing and search result; "verified": true in API responses, and included in verified=true queries; +15 authority, and the featured tier (do-follow links) from 60 instead of 70. Tiers: featured at 70 (60 for verified owners), listed at 45.
Check your llms.txt against these rules → · Generate a draft → · Submit your site →
More: What is llms.txt? · llms.txt examples · checker · generator