How to Create an llms.txt File for Your SaaS (With a Real Example)
By Ankit (@ankitshx), who builds startups.townllmstxt.org spec, crawler headers, and Next.js / static hosting checked
Let's get the honest part out of the way first: adding an llms.txt file will not magically push your startup to the top of ChatGPT or Google tomorrow. Anyone promising that is selling hype.
What it does solve is much simpler and more practical. Most SaaS sites are packed with navigation menus, interactive pricing toggles, cookie banners, and client-side JavaScript. When an AI assistant, coding agent, or buyer using Perplexity or Claude tries to look up what your product does, half its context gets wasted wading through HTML noise. A clean /llms.txt hands it a plain Markdown cheat sheet in a single request.
It takes about ten minutes to write once, costs nothing to host, and keeps your product description accurate wherever AI tools read your site. Here is how to build one that is actually useful.
Want a head start from your live site?
Paste your URL into our free llms.txt Generator to validate an existing file or draft a clean spec-compliant one from your homepage and sitemap.
How llms.txt fits next to robots.txt and sitemap.xml
Founders often mix these files up or worry that one replaces another. They do completely different jobs:
| File | Format | Built for | What it does |
|---|---|---|---|
| /robots.txt | Plain text rules | Search & AI crawlers | Says which bots are allowed or blocked from fetching paths. |
| /sitemap.xml | XML URL list | Google, Bing, crawlers | Lists every indexable URL and when it last changed. |
| /llms.txt | Short Markdown index | AI assistants & agents | Curated map of your 10–25 most important pages with plain descriptions. |
| /llms-full.txt | Long Markdown dump | Coding & research agents | Optional full-text version of docs or key pages in one fetch. |
Think of /llms.txt as the README at the front door of your website. You do not need /llms-full.txt unless you have API documentation or long guides that developers regularly paste into Cursor or Claude.
The exact format (with a copy-paste SaaS example)
The spec from llmstxt.org is intentionally tiny. Only one element is strictly required (the top H1 heading), and four pieces make up a good SaaS file:
- H1 title: Your exact product or company name.
- Blockquote summary: One or two plain sentences explaining what the product does and who it is for.
- Short context block (optional): Key facts like pricing tiers, supported platforms, or main differentiators.
- H2 sections with link lists: Markdown links using
- [Title](URL): plain description. Put nice-to-have links under an## Optionalheading so tools with tight context limits know what they can skip.
Here is what a clean, real-world SaaS file looks like:
# MetricPulse
> MetricPulse is a lightweight uptime and webhook monitoring tool for small SaaS teams. It pings APIs every 30 seconds and sends Slack or email alerts before customers notice.
Built for bootstrapped teams that do not want to configure Datadog. Free tier covers 5 monitors; paid plans start at $19/month with unlimited seats.
## Product
- [Homepage](https://metricpulse.example/): Overview of uptime checks, status pages, and alert routing.
- [Pricing](https://metricpulse.example/pricing): Free plan (5 monitors), Starter ($19/mo, 50 monitors), Team ($49/mo, 250 monitors).
- [Status Pages](https://metricpulse.example/status-pages): Public incident pages on a custom domain with zero branding on paid plans.
## Documentation
- [Quickstart](https://metricpulse.example/docs/quickstart): Add your first HTTP or webhook monitor in under two minutes.
- [Slack & PagerDuty Alerts](https://metricpulse.example/docs/alerts): Alert rules, quiet hours, and escalation setup.
- [REST API](https://metricpulse.example/docs/api): Create monitors and pull uptime history programmatically.
## Optional
- [Changelog](https://metricpulse.example/changelog): Monthly product updates and new regions.
- [Terms & Privacy](https://metricpulse.example/privacy): Data retention and GDPR summary.Want to inspect a live production version? You can open Startups Town's own /llms.txt and /llms-full.txt directly in your browser.
Five mistakes that make llms.txt useless
When we audited dozens of early startup llms.txt files, the same five issues showed up over and over:
- 1Dumping your entire sitemap into it: If you paste 400 blog URLs into /llms.txt, you just rebuilt sitemap.xml in Markdown. Keep /llms.txt curated to the 10 to 25 pages someone actually needs to understand your product: homepage, pricing, core features, docs, and top comparison pages.
- 2Writing ad copy instead of facts: AI models do not care that your tool is 'the next-generation platform for modern teams.' Write what it does, who uses it, what it integrates with, and what it costs. Concrete numbers beat adjectives every time.
- 3Accidentally serving HTML with a 200 status: Single-page apps and catch-all routes often catch /llms.txt and return your homepage HTML with a 200 OK. Always check with curl or a validator that the response is actually text/plain or text/markdown.
- 4Blocking AI crawlers in robots.txt or Cloudflare: An llms.txt file sits there unread if your CDN firewall or robots.txt blocks OAI-SearchBot, PerplexityBot, or Claude-SearchBot. Check crawler access first before spending time tuning Markdown.
- 5Never updating it after a pricing or URL change: If your llms.txt still says '$9/month' six months after you raised prices to $29, assistants will repeat the old price to prospects. Treat it like your pricing page and update it whenever core details move.
How to publish /llms.txt in two minutes
Pick whichever setup matches your stack. For most marketing sites, the static file option is all you need.
Option 1: Static file (Next.js, Astro, Vite, HTML)
Save your Markdown as public/llms.txt. Next.js, Vercel, Netlify, and Cloudflare Pages all serve files inside public/ directly at /llms.txt with a text/plain content type.
Option 2: Dynamic Route Handler (Next.js App Router)
If your product list, docs, or stats change often, create src/app/llms.txt/route.ts and return a Response with Content-Type: text/plain; charset=utf-8 and a Cache-Control header so it stays fast without rebuilding on every request.
Quick 60-second verification checklist
Before you move on to other launch work, verify three things:
- Confirm headers and status: Run
curl -i https://yourdomain.com/llms.txtor test it in the llms.txt Validator to make sure it returns200 OKand plain Markdown, not a redirect or HTML shell. - Check AI crawler access: Run your domain through the AI Crawler Checker so you know
OAI-SearchBot,Claude-SearchBot, andPerplexityBotare not blocked by robots.txt or a WAF rule. - Pair it with structured data and external mentions: Add clean JSON-LD schema on your homepage and list your startup on reputable directories. AI engines trust what your site says much more when third-party pages corroborate it.
Frequently asked questions
Does llms.txt help with Google SEO?
No. Google has stated it does not use llms.txt as a search ranking signal, so do not expect it to move your blue-link rankings. Its job is helping AI assistants, coding agents, and LLM-powered tools read your product facts cleanly without parsing heavy page markup.
What is the difference between llms.txt and llms-full.txt?
llms.txt is a short table of contents (usually 1 to 4 KB) linking to your most important pages with brief descriptions. llms-full.txt is an optional companion file that inlines the full Markdown text of those pages so an agent can read everything in a single request.
Where should llms.txt be placed on a website?
Always at the root domain: https://yourdomain.com/llms.txt. In Next.js, Astro, Vite, or most static hosts, placing a file at public/llms.txt serves it at the root automatically.
How long should a SaaS llms.txt file be?
Aim for 10 to 25 links and roughly 1 to 5 KB of text. If it takes a human more than 60 seconds to skim, it is probably too long; move secondary pages into an ## Optional section or a separate /llms-full.txt.
Do I still need robots.txt and sitemap.xml if I have llms.txt?
Yes. robots.txt controls crawler permissions and sitemap.xml drives search engine discovery. llms.txt sits alongside them as a clean summary for AI tools, not a replacement.
Related founder guides
All guides →Want an extra AI-readable citation for your startup?
List your startup on Startups Town for a permanent profile page, a 3D building on the map, and a spot in our public llms.txt feed.
Launch for free