llms.txt is a plain markdown file at the root of a website, at /llms.txt, that gives AI assistants and answer engines a short, factual summary of the site and links to its most important pages. To add one, write a title, a one-paragraph summary, your key facts and a list of main pages with a line each, then serve it from the site root. It is a proposed convention rather than a search engine standard, so treat it as low-cost insurance.
This site has one at mohitgoyal.in/llms.txt. Below is what goes in it, how I structured it, and how to add one on Next.js or WordPress.
What is llms.txt for?
Large language models read websites differently from people. Many AI tools fetch a page and get a wall of navigation, scripts and layout before the content. Some do not run JavaScript at all, so a site that builds its content in the browser can look empty to them.
llms.txt gives them a clean shortcut: a single file in plain markdown that says who runs the site, what it offers and where to read more. The format was proposed in 2024 and has been adopted by a range of documentation sites, tools and personal sites since. Nothing forces an AI system to read it, but when one does, it gets your own words instead of a guess.
Set expectations
llms.txt is not a ranking factor and no major search engine has said it uses the file. I add it because it takes an hour, cannot hurt, and gives any AI tool that does read it accurate facts in my own words.
What should an llms.txt file include?
The proposal suggests a simple structure, and I follow it:
| Section | What goes in it | On my site |
|---|---|---|
| H1 title | The name of the site, person or company | My name |
| Blockquote summary | One or two sentences on who you are and what you do | Role, location, sites shipped, a call to action |
| Context paragraph | How the file relates to the site and how to use it | That the site is an interactive AI portfolio and this is its plain-text version |
| Key facts | A short list of facts an assistant might be asked | Role, location, years of experience, sites shipped, plugin installs, education |
| Sections as H2s | Lists of links, each with a one-line description | Site sections, services, free AI tools, projects |
| Contact | How to reach you | Booking link, email and profiles |
Here is the top of mine, trimmed:
# Mohit Goyal
> Senior Web Developer in Gurugram, India. 100+ fast, SEO-friendly sites
> shipped in 4+ years with Next.js, React and WordPress, including the
> procol.ai rebuild. Send me your next project.
## Key facts
- Role: Senior Web Developer, Next.js and WordPress
- Location: Gurugram, India
- Websites shipped: 100+
- Plugin installs: 1,000+
Notice what is missing: no adjectives, no claims I could not back up, and nothing that is not also on the site. Every number in the file appears on a page a person can check, which is what makes it safe for a model to repeat.
The context paragraph matters more than it looks. Mine says the file exists for AI assistants and crawlers that do not execute JavaScript, that everything in it is factual and written by me, and that it can be quoted with attribution. That tells a model how to treat the content.
How do you add llms.txt to a website?
- 1
Write the summary first
One blockquote that answers 'who is this and what do they offer' in two sentences. It is the part most likely to be quoted.
- 2
List the facts people ask about
Location, services, experience, prices if you publish them, contact details. Only facts that also appear on the site.
- 3
Map the important pages
Group links under H2s such as Services, Products, Docs or Case studies, with one line per link. Use full URLs.
- 4
Serve it from the root
The file must load at yourdomain.com/llms.txt as plain text, with a 200 status.
- 5
Keep it current
Regenerate or update it whenever a service, product or key fact changes.
On Next.js, the simplest option is a static public/llms.txt. If your pages come from a CMS or content files, a route handler at app/llms.txt/route.ts can build the file from the same data and return it as text, so it updates with the site.
On WordPress, upload the file to the site root through your host's file manager or SFTP, or check whether your SEO plugin offers to generate one. If you write it by hand, add it to your launch and content checklists so it does not drift.
On this site, the descriptions in llms.txt come from the same sources as the pages. Each free tool, for example, has one answer-first summary that appears under the tool's heading, in its JSON-LD and in llms.txt.
Does llms.txt replace robots.txt or a sitemap?
No. Each file does a different job:
- robots.txt controls who may crawl. Mine explicitly allows AI crawlers such as GPTBot, ClaudeBot, PerplexityBot and Google-Extended, and points to the sitemap. If you block those bots there, llms.txt will not help.
- sitemap.xml lists every indexable URL for search engines.
- llms.txt summarises the site and points to the pages that matter most.
Structured data is the fourth piece. JSON-LD on each page gives engines the same facts in a machine-readable form; see my guide to JSON-LD structured data.
What mistakes should you avoid with llms.txt?
- Pasting whole pages into it. Link to them instead. A long file buries the summary.
- Facts that disagree with the site. If llms.txt says 100+ sites and the about page says something else, you have taught the model to doubt both.
- Marketing copy. Write plain statements of fact. A model quoting "the best agency in town" helps nobody.
- Forgetting it exists. A stale file is worse than none. Generate it, or put it on the update checklist.
Is llms.txt worth adding?
For a business site, yes, as part of a wider effort to be readable by answer engines. It takes about an hour and has no downside. The bigger wins are still server-rendered pages, answer-first writing and consistent facts, which I cover in how to get cited in AI Overviews.
I add llms.txt, structured data and a crawl-friendly setup to the sites I build, and to existing sites through my technical SEO and Core Web Vitals service.



