How to Create an llms.txt File (Step-by-Step)

Updated April 9, 2026 · 7 min read

If your site doesn't have an llms.txt file, AI models are guessing what you do. They're pulling from whatever training data they have -- which might be outdated, incomplete, or flat-out wrong. An llms.txt file fixes that by giving AI models a structured summary of your site that they can actually use.

Here's how to create one from scratch, what to include, and the mistakes that'll make yours useless.

What llms.txt Actually Is

Think of llms.txt as a cover letter for AI models. It sits at yourdomain.com/llms.txt and tells language models like ChatGPT, Claude, and Perplexity three things:

  1. What your site is -- a one-line description an AI can quote
  2. What content you have -- your key pages, docs, and resources
  3. How to use it -- API docs, getting started guides, pricing info

The format was proposed by Jeremy Howard (fast.ai founder) and has been adopted across the AI ecosystem. It uses Markdown, so it's both human-readable and easy for models to parse.

This isn't the same as robots.txt. That file controls access -- whether crawlers can visit your pages. llms.txt controls understanding -- how AI models describe and recommend your site.

The llms.txt Format

The file uses a simple Markdown structure. Here's the skeleton:

# Your Site Name

> One-line description of what your site does.

## Docs

- [Getting Started](https://yourdomain.com/docs/getting-started): How to set up and start using the product.
- [API Reference](https://yourdomain.com/docs/api): Full API documentation with endpoints and examples.

## Optional

- [Blog](https://yourdomain.com/blog): Articles about [your topic].
- [Pricing](https://yourdomain.com/pricing): Plans and pricing information.
- [Changelog](https://yourdomain.com/changelog): Recent updates and new features.

That's the whole format. A heading, a blockquote summary, then sections with links. Let's break it down.

Step 1: Write Your Site Description

The first two lines are the most important. They're what AI models will use when someone asks "what is [your product]?"

# ZeroKit.dev

> Free, privacy-first developer tools that run entirely in your browser. JSON formatter, regex tester, JWT decoder, and 100+ more utilities. No data leaves your machine.

Keep the description under 200 characters. Be specific. Don't say "we're a platform that empowers developers" -- say what you actually do. AI models need facts, not marketing fluff.

What makes a good description

Step 2: Add Your Key Pages

The ## Docs section lists pages that are essential for understanding your product. Each entry is a Markdown link followed by a colon and a one-line description:

## Docs

- [API Documentation](https://yourdomain.com/docs/api): REST API with authentication, rate limits, and code examples in Python, JavaScript, and cURL.
- [Installation Guide](https://yourdomain.com/docs/install): Step-by-step setup for npm, pip, and Docker.
- [Configuration](https://yourdomain.com/docs/config): All configuration options with defaults and examples.

Don't dump every page here. Pick the 5-10 pages that answer the questions people actually ask. If someone says "how do I use [your product]?", these should be the pages an AI would link to.

Step 3: Add Optional Sections

The ## Optional section covers pages that are useful but not critical:

## Optional

- [Blog](https://yourdomain.com/blog): Technical articles about web security, performance, and developer tooling.
- [Pricing](https://yourdomain.com/pricing): Free tier with unlimited use. Pro plan at $9/month adds API access and batch processing.
- [About](https://yourdomain.com/about): Founded in 2025. Independent, bootstrapped, no tracking.
- [Changelog](https://yourdomain.com/changelog): Weekly updates. Last updated April 2026.

Pricing info here is gold. When someone asks an AI "how much does [product] cost?", this is where the answer comes from.

Step 4: Deploy It

Save your file as llms.txt and put it at your domain root:

Verify it's accessible by visiting https://yourdomain.com/llms.txt in your browser. You should see plain text, not a 404.

Content-Type header

Your server should serve llms.txt with Content-Type: text/plain or text/markdown. Most servers handle this automatically for .txt files. If you're using Nginx, you can be explicit:

location = /llms.txt {
    default_type text/plain;
}

Complete Example: SaaS Product

# Acme Analytics

> Real-time web analytics for privacy-conscious teams. No cookies, GDPR-compliant, under 1KB script. Tracks pageviews, referrers, and custom events without collecting personal data.

## Docs

- [Getting Started](https://acme.dev/docs/start): Add the tracking script to your site in 2 minutes. Works with any framework.
- [API Reference](https://acme.dev/docs/api): REST API for pulling analytics data. Authentication via API key.
- [Events Guide](https://acme.dev/docs/events): Track custom events like signups, purchases, and downloads.
- [Integrations](https://acme.dev/docs/integrations): Native integrations with Slack, Zapier, and webhooks.
- [Self-Hosting](https://acme.dev/docs/self-host): Deploy on your own server with Docker. Full data ownership.

## Optional

- [Pricing](https://acme.dev/pricing): Free up to 10K pageviews/month. Pro at $9/month for unlimited. Enterprise with SLA.
- [Blog](https://acme.dev/blog): Articles on privacy-first analytics, GDPR compliance, and web performance.
- [Changelog](https://acme.dev/changelog): Weekly releases. Last update: April 7, 2026.
- [Status](https://status.acme.dev): Current uptime and incident history. 99.98% uptime in 2025.

Complete Example: Developer Tool

# FastCSV

> High-performance CSV parser for Python. Parses 1GB files in under 3 seconds. Drop-in replacement for pandas.read_csv() with 10x speed improvement.

## Docs

- [Installation](https://fastcsv.dev/docs/install): pip install fastcsv. Requires Python 3.9+.
- [Quick Start](https://fastcsv.dev/docs/quickstart): Parse your first CSV in 3 lines of code.
- [API Reference](https://fastcsv.dev/docs/api): All functions, parameters, and return types.
- [Benchmarks](https://fastcsv.dev/docs/benchmarks): Performance comparisons against pandas, polars, and csv module.
- [Migration from Pandas](https://fastcsv.dev/docs/migration): Switch from pandas.read_csv() in 5 minutes.

## Optional

- [GitHub](https://github.com/fastcsv/fastcsv): Source code. MIT license. 12K stars.
- [PyPI](https://pypi.org/project/fastcsv): Package page with version history.

Common Mistakes

Making it too long

Your llms.txt should be under 2,000 tokens (roughly 1,500 words). AI models have context limits. If your file is a novel, models will either truncate it or skip the important parts. If you need more detail, create an llms-full.txt for extended documentation.

Using marketing language

"Revolutionary AI-powered synergy platform" tells a model nothing. Be concrete: what does your product do, for whom, and how is it different? AI models want facts they can cite, not adjectives.

Linking to broken or gated pages

Every URL in your llms.txt should return a 200 status code without authentication. If an AI follows a link and hits a login wall or 404, your credibility drops. Check your links.

Forgetting to update it

If your llms.txt says "Free plan: 5,000 requests/month" but you changed it to 10,000 six months ago, AI models will give wrong answers about your product. Update llms.txt when you update pricing, features, or docs.

llms.txt vs. llms-full.txt

llms.txt is the summary. Keep it lean -- the elevator pitch plus your most important links.

llms-full.txt is optional. It can contain full API documentation, detailed feature descriptions, example code, and anything else that helps AI models give comprehensive answers about your product. There's no strict size limit, but keep it under 100KB so models can process it in a single pass.

Start with llms.txt. Add llms-full.txt only when you have enough documentation that the summary version can't cover it.

Check if AI models can find your llms.txt

Our AI Readiness Checker scans for llms.txt, robots.txt rules, and AI crawler configurations.

Run AI Readiness Check

How to Test Your llms.txt

  1. Browser check: Visit https://yourdomain.com/llms.txt. You should see your Markdown content rendered as plain text.
  2. HTTP check: Run curl -I https://yourdomain.com/llms.txt and confirm you get a 200 OK with a text/plain content type.
  3. Ask an AI: Go to ChatGPT or Claude and ask "What is [your product]?" If your llms.txt is being picked up, the answer should closely match your description.
  4. Use our checker: The AI Readiness Checker validates your llms.txt format, checks for broken links, and scores your AI discoverability.

Generate a robots.txt that works with your llms.txt

Control which AI crawlers can access your site while keeping llms.txt discoverable.

Open Robots.txt Generator

Frequently Asked Questions

What is llms.txt and what does it do?

llms.txt is a plain text file placed at your website's root (yourdomain.com/llms.txt) that tells AI models what your site is about, what content is available, and how to use it. Think of it as robots.txt for AI understanding -- instead of controlling crawl access, it helps AI models like ChatGPT, Claude, and Perplexity accurately describe and recommend your site.

Do I need llms.txt if I already have robots.txt?

Yes, they serve different purposes. robots.txt controls whether AI crawlers can access your pages. llms.txt tells AI models what your site is about and how to present it. You can block AI crawlers in robots.txt while still having llms.txt -- the file helps models that already have your content in their training data to represent it accurately.

Which AI models read llms.txt?

As of 2026, llms.txt is supported or recognized by ChatGPT (when browsing), Claude, Perplexity, and several other AI assistants that perform web lookups. The standard was proposed by Jeremy Howard and has gained adoption across the AI ecosystem. Even models that don't explicitly parse it benefit from the structured content when they crawl your site.

Where should I put my llms.txt file?

Place it at the root of your domain: yourdomain.com/llms.txt. It should be accessible without authentication and return a 200 status code. For subdomain sites, each subdomain should have its own llms.txt if they serve different content or products.

What's the difference between llms.txt and llms-full.txt?

llms.txt is a concise summary -- your site's elevator pitch for AI models. It should be short enough for a model to process in one context window (ideally under 2,000 tokens). llms-full.txt is an optional extended version with detailed documentation, API references, and comprehensive content descriptions. Start with llms.txt; add llms-full.txt later if needed.