Clean page content
llms.txt or the page itself: which one to put in context
Decide when an AI app should read a site's llms.txt and when it should read the page, using the proposal's own format and 2026 data on who fetches the file.
By Curtis Mccann, Live Web Data team · Published
This article was drafted with AI assistance from the sources listed below and edited and published by the Live Web Data team. Disclosure: the Live Web Data API, which this article mentions, is this site's own product.
- The user named a URL: read that page, skip llms.txt.
- You only know the site: read llms.txt as a map of links, if it exists.
- Pick the linked pages that match the question; skip the Optional section when context is tight.
- Prefer a page's .md version when the site offers one.
- Put the page text in context, not the llms.txt notes about it.
A user asks your app a question about a site. The site publishes an llms.txt file. Should that file go into the model's context, or the page that holds the answer? The short version: llms.txt is a map, and the page is the source. Read the map only when you do not know which page to read, then put the page in context.
What an llms.txt file holds
Start from the format. The proposal on llmstxt.org, by Jeremy Howard, was first published on September 3, 2024. It describes a Markdown file at the site root or under a subpath, where it covers the pages under that path. When more than one file applies, an agent should use the most specific one.
The structure is short:
- An H1 with the site or project name. This is the only required section.
- A blockquote with a short summary.
- Detail sections of any kind except headings.
- H2 sections with lists of links, each written as
[name](url)and optionally followed by a colon and notes. - An H2 named "Optional" by convention, for secondary links an agent can skip when it needs less context.
So a full llms.txt is mostly a list of links with a line of notes each. The proposal also says what it was for: "Our expectation was that llms.txt would mainly be useful for inference rather than training." That fits reading at question time. It does not make the file the answer.
Default: the page goes into context
The decision comes first. When the user names a URL, or your app already knows which page answers the question, read that page and skip llms.txt. That is 1 fetch instead of 2.
The reason is what each file contains. The notes in an llms.txt are a summary someone wrote about each page. The page is what the site serves to every reader. A version number, a limit or a policy sentence sits in the page, and the notes may leave it out or describe an older state of it. When the two disagree, the page is the one to quote.
Keep the fetch time next to the page text either way, so the model knows how old the copy is.
When llms.txt earns its fetch
Change the default when you know the site but not the page. Here llms.txt can save work. The Chrome Lighthouse docs describe the file as a machine-readable summary of a site for LLMs and agents, and note that without it an agent may have to crawl more of the site to learn its structure.
A read order that keeps context small:
- Fetch
/llms.txtfrom the site root, or from the most specific subpath that applies. - If it returns 404, fall back to the site's own navigation. Lighthouse marks a missing file as Not Applicable because the file is "optional at the moment", so a missing file is normal.
- Pick the few linked pages whose names and notes match the question. Leave the "Optional" section out when context is tight.
- Fetch those pages and pass their text to the model. Drop the llms.txt itself from the final prompt unless the user asked about the site's structure.
curl -sS -o llms.txt -w '%{http_code} %{content_type}\n' https://example.com/llms.txt
A 200 with a text type means there is a file to read. Anything else means you go to the pages directly.
Prefer the page's Markdown version when it exists
The proposal also asks sites to offer Markdown copies of their pages at the same URL with .md added (page.html.md) or with the extension replaced (page.md). URLs without a file name use index.html.md or index.md. Clients can discover these copies through rel="alternate" type="text/markdown" links in the HTML or in an HTTP Link header.
That part of the proposal is the useful one for a reader: it is still the page, just without the markup. If a site offers it, request it. If not, convert the HTML yourself, or ask for Markdown with a header as our post on Accept: text/markdown explains. The Markdown vs HTML guide covers which format to pass.
How often the file is there and read
Do not build a flow that depends on llms.txt. Ahrefs looked at 137,210 domains in its analytics that had traffic in May 2026. 28% of them published an llms.txt file, a figure the authors call an upper bound because their users skew technical. 97% of those files got zero requests in May 2026.
Of the requests that did arrive, 96% came from bots. The authors write that "77% of the bots fetching llms.txt aren't AI tools at all", with SEO audit tools the largest group at 21.7% of requests. Named AI bots made 19.5% of requests together. The authors point to coding agents and training crawlers as the most likely readers, and they warn that a fetch does not prove a bot read or acted on the file.
Search does not ask for it either. Google Search Central states: "You don't need to create new machine readable files, AI text files, or markup to appear in these features."
Reading the page live
On Live Web Data API, each URL comes back as Markdown, plain text or HTML, and verbosity set to compact returns the main content while full keeps the whole page. Every request fetches the page live; there is no cache. Failed fetches cost 0 credits. The docs list the request fields.
Public pages only: check the site's robots.txt and terms before you read it.
Frequently asked questions
Is llms.txt a replacement for reading the page?
No. The llms.txt proposal describes a Markdown file with a site name, a short summary and lists of links with optional notes. It points to pages; the facts a user asks about are in the pages themselves. Use llms.txt to choose which pages to read, then read them.
What is the only required part of an llms.txt file?
An H1 with the name of the project or site. The blockquote summary, the detail sections and the H2 lists of links are all optional under the proposal on llmstxt.org.
Do AI tools actually request llms.txt files?
Rarely, by one large count. Ahrefs looked at 137,210 domains in May 2026: 28% published an llms.txt file, and 97% of those files got zero requests that month.
Does Google need an llms.txt file to show a site in AI features?
Google Search Central says no. Its page on AI features states that you do not need new machine-readable files, AI text files or markup to appear in them.
Sources
- The /llms.txt file (llmstxt.org) (Documentation)
- We Analyzed 137K Sites: 97% of llms.txt Files Never Get Read (Ahrefs) (Blog)
- llms.txt audit (Chrome Lighthouse docs) (Documentation)
- AI features and your website (Google Search Central) (Documentation)