Skip to main content

llms.txt Validator

Check any llms.txt file for the structure AI crawlers actually need: H1, summary, absolute links, and clean sections.

Quick answer

This validator checks a live or pasted llms.txt against the six rules AI crawlers care about: a single H1 site name, a blockquote summary, a Docs section, absolute HTTPS links, no duplicate URLs, and a text/plain content type. Every rule returns pass, warning or fail with the exact fix.

Fetch a live llms.txt URL or paste contents below.

Validation results
0 passed0 warnings1 errors
  • File is empty.

    Fix: Add at least an H1 site name and a summary.

// Add an H1 site name before publishing

Why validation matters

A well-formed llms.txt is the fastest way to tell ChatGPT, Claude, and Perplexity which pages on your site matter most. But a missing H1, a relative link, or a 200 KB file makes the brief unusable. This validator catches the mechanical mistakes before you publish.

What a good file looks like

# Acme Analytics
> Acme Analytics is a privacy-first product analytics tool for B2B SaaS teams.

## Docs
- [Documentation](https://acme.com/docs): Setup, SDKs and data model
- [API Reference](https://acme.com/api): REST endpoints and webhooks
- [Pricing](https://acme.com/pricing): Plans, limits and billing FAQ

## Optional
- [Blog](https://acme.com/blog): Product analytics and privacy engineering
- [Changelog](https://acme.com/changelog): Shipped features by date

Common failures

  • Missing H1 or summary — the crawler has no context for the rest of the file.
  • Relative links — crawlers resolve them against the wrong base or fail.
  • No ## Docs section — the file has no prioritized list of canonical pages.
  • Too large — llms.txt is a brief, not a sitemap. Keep it under 100 KB.
  • HTML content type — serve it as plain text or markdown.

After validating

Publish the file at /llms.txt on your domain, then run a full OptimAIze scan to confirm AI crawlers can fetch and parse it the way ChatGPT, Claude, and Perplexity do.

Signal
6
Core LLM Rules Checked
Ensures compliance with all critical llms.txt directives for AI agents.
Signal
12
Crawler Agents Supported
Validates against directives for major AI crawlers like GPTBot, Gemini-PaLM, and Anthropic-AI.
Signal
98%
Average Compliance Rate
Organizations leveraging llms.txt often see high initial compliance, but require specific fixes.
Signal
30 sec
Validation Time (Avg)
Rapid analysis for both live URLs and pasted text snippets, providing instant feedback.

How llms.txt Impacts AI Content Indexing

The llms.txt file is a crucial directive for AI crawlers, analogous to robots.txt for traditional search engines. It dictates how large language models (LLMs) such as GPT-4o, Gemini, and Claude interact with your website's content. A properly configured llms.txt can prevent unauthorized data scraping, designate specific content for AI training, or restrict access to sensitive sections. Implementing llms.txt signals clear boundaries to AI agents, optimizing your content's discoverability for generative AI while protecting intellectual property. Without it, you risk uncontrolled data ingestion, potentially leading to misattribution or competitive disadvantages in AI-driven search results.

Tactical Steps to Optimize Your llms.txt for AI Agents

Optimizing llms.txt involves meticulous adherence to established rules. First, ensure a single, concise H1 site name. Second, include a blockquote summary no longer than 150 characters, often containing a mission statement or content purpose. Third, implement a dedicated 'Docs' section with absolute HTTPS links to your documentation or API references. Crucially, all specified URLs must be absolute and use HTTPS to prevent redirect issues and maintain security. Avoid duplicate URLs within any directive to maintain clarity and prevent parsing errors. A content-type header of 'text/plain' is mandatory for correct interpretation by all major AI crawlers. Utilize this validator to pinpoint precise, actionable fixes.

Common llms.txt Errors and Their Impact on AI Indexing

Incorrect llms.txt configurations can lead to significant indexing issues for AI models. A missing 'Docs' section, for instance, might cause AI agents like Perplexity AI or YouBot to struggle with understanding your site's structured information or API endpoints. Relative URLs or non-HTTPS links can result in `400 Bad Request` or `301 Redirect` errors for crawlers, essentially blocking access. Duplicate URLs confuse parsing algorithms, leading to inconsistent directives. The absence of a `text/plain` content type headers for the llms.txt file itself can cause AI systems to ignore the file entirely, treating all content as fair game. These errors directly impact your AI-driven visibility and content control.

Leveraging llms.txt for Advanced Content Governance and AEO

Beyond basic access control, llms.txt offers a sophisticated layer of content governance for AI. By explicitly defining what content AI can 'learn' from, you shape the AI's understanding of your brand and intellectual property. For example, explicitly permitting AI access to 'blog/' but disallowing 'pricing/' guides LLMs toward accurate content generation about your offerings, while protecting sensitive business data. This proactive approach ensures your website contributes positively to the AI knowledge graph, enhancing your brand's authority and discoverability in AI-powered searches, and setting benchmarks for responsible AI interaction. This is key for advanced AEO (Answer Engine Optimization) strategies.

Key llms.txt Directives for AI Crawlers

DirectiveRequirementImpact on AI IndexingFix Examples
H1 Site NameSingle H1, e.g., 'Site: Example.com'Crucial for AI to identify content originChange 'Site: Example' to 'Site: Example.com'
Blockquote SummarySingle blockquote, < 150 charsProvides AI a concise site overview for summarizationAdd `<blockquote>Brief site summary.</blockquote>`
Docs SectionAbsolute HTTPS links to documentationEnables AI to deeply understand your structured content/APIsEnsure `Docs: https://example.com/docs`
Absolute HTTPS LinksAll URLs must be absolute and HTTPSPrevents `400` errors; essential for secure AI crawlingConvert `http://example.com` to `https://example.com`
No Duplicate URLsUnique URLs per directiveAvoids parsing conflicts, ensures consistent AI behaviorRemove repeated `Allow: /blog/` entries

Essential llms.txt Compliance Checklist for Developers

  • Is your llms.txt file accessible at the root of your domain (e.g., https://example.com/llms.txt)?
  • Does your llms.txt specify a User-agent directive for at least GPTBot, Gemini-PaLM, and Anthropic-AI?
  • Is there only one 'Site:' directive, formatted as an H1 (e.g., `# Site: My Brand Name`)?
  • Do you have a single blockquote `<blockquote>` summary of your site's purpose, under 150 characters?
  • Is a dedicated 'Docs:' section present, with absolute HTTPS links to all relevant documentation?
  • Are all 'Allow:' and 'Disallow:' directives using absolute HTTPS URLs, with no duplicates?
  • Is the content type of your llms.txt file set to 'text/plain' to ensure proper parsing by AI agents?
  • Are there no syntax errors or unescaped characters within your llms.txt file that could break parsing?

How to Validate and Optimize Your llms.txt File

  1. 1
    Locate or Create Your llms.txt File

    Begin by ensuring an llms.txt file exists at your domain's root. If it doesn't, create one. This file, much like robots.txt, guides AI crawlers. Ensure it's reachable via HTTPS, e.g., `https://yourdomain.com/llms.txt` for AI agents like Google's Gemini-PaLM or OpenAI's GPTBot to discover and parse it correctly.

  2. 2
    Define Site Identity and Purpose

    Within llms.txt, include a single H1 site name, e.g., `# Site: ExampleCorp`. Follow this with a brief, single-blockquote summary (under 150 characters) like `<blockquote>Innovating with AI.</blockquote>`. This immediately informs AI agents about your site's core identity and mission, crucial for accurate content context and attribution.

  3. 3
    Specify AI Crawler Directives

    Explicitly declare directives for specific AI user agents. For example, `User-agent: GPTBot` followed by `Allow: /blog/` or `Disallow: /private/`. This granular control enables you to manage access for LLMs like GPT-4o, Anthropic-AI, or Meta's Llama, ensuring ethical and strategic data handling.

  4. 4
    Link Documentation with Absolute HTTPS

    Create a 'Docs:' section with absolute HTTPS links to your API documentation, data schemas, or detailed content guidelines. Example: `Docs: https://example.com/api-docs`. This helps AI models like Perplexity AI understand your structured data, improving their ability to generate accurate summaries or answer technical queries about your offerings.

  5. 5
    Validate URLs and Content Type

    Ensure all specified URLs within `Allow:` or `Disallow:` directives are absolute and use HTTPS. Avoid duplicate entries. Critically, verify that your web server serves llms.txt with a `Content-Type: text/plain` header. Incorrect headers can lead to AI crawlers ignoring your directives entirely, negating your control.

  6. 6
    Utilize the llms.txt Validator for Fixes

    Input your live llms.txt URL or paste its content into this validator. The tool will check for the six core rules: H1, blockquote, Docs section, absolute HTTPS links, no duplicates, and text/plain content type. It provides precise pass/warning/fail statuses with exact, actionable fixes, streamlining compliance for optimal AI interaction and content governance.

More questions answered

Why is llms.txt critical for AI Answer Engine Optimization (AEO)?
llms.txt is pivotal for AEO because it directly influences how AI models like Google's Search Generative Experience (SGE) or Perplexity AI interact with and interpret your content. By guiding these models on what to crawl, index, and use for training, you ensure your brand's information is accurately represented in AI-generated answers, improving visibility and control over your narrative in next-gen search.
Which specific AI crawlers respect llms.txt directives?
Major AI crawlers that respect llms.txt include GPTBot (OpenAI), Gemini-PaLM (Google), Anthropic-AI (Anthropic), CCBot (Common Crawl), and various others from research institutions. While not universally enforced, these primary agents recognize and attempt to adhere to the directives, making compliance crucial for influencing mainstream AI models and their data ingestion processes.
What is the impact of not having a text/plain content type for llms.txt?
If your llms.txt file is not served with a `Content-Type: text/plain` header, many AI crawlers will misinterpret or entirely ignore its contents. They expect a plain text format for parsing. If served as HTML or another format, the directives will be unreadable, effectively rendering your llms.txt file useless and allowing AI agents unrestricted access, bypassing your intended controls.
How does a single H1 site name in llms.txt benefit my brand?
A single H1 site name (`# Site: Your Brand Name`) in llms.txt provides a clear, unambiguous identifier for AI models. This clarity helps AI agents accurately attribute content, improving brand recognition in generated summaries and answers. It's a foundational element for consistent brand representation across diverse AI platforms and a strong signal for brand authority.
Why must URLs in llms.txt be absolute HTTPS links?
Absolute HTTPS links are mandatory because AI crawlers operate in diverse environments and require explicit, secure paths. Relative URLs can break in certain contexts or lead to incorrect parsing, while non-HTTPS links pose security risks and may be ignored by security-conscious AI agents. Consistent HTTPS ensures integrity, security, and reliable access for all AI-driven content acquisition.
What is the purpose of the 'Docs' section in llms.txt?
The 'Docs' section (e.g., `Docs: https://example.com/api-docs`) serves as a direct reference for AI models seeking structured information or technical documentation. It helps AI understand your data models, APIs, and complex content, enabling them to generate more accurate, contextually relevant, and detailed responses when users inquire about your products or services. It's vital for developer-focused content.
How often should I validate my llms.txt file?
It's recommended to validate your llms.txt file immediately after any changes to your site's structure, content strategy, or AI interaction policies. A monthly review is also advisable to catch any unnoticed errors or ensure continued compliance with evolving AI crawler behaviors and best practices. Proactive validation prevents potential AI indexing issues before they impact your AEO.
Can llms.txt entirely block all AI crawlers from my site?
While llms.txt provides strong directives for ethical AI crawlers, it cannot guarantee a complete block for all bots. Malicious or non-compliant scrapers may still disregard the file. However, for major, reputable AI models like those from OpenAI, Google, and Anthropic, adhering to llms.txt directives significantly enhances your ability to control and guide their interaction with your site's content.

Want the full picture?

This tool generates one piece. OptimAIze scans your whole site, audits structured data, content, crawler access, and answer-readiness — then gives you everything you need to be cited by AI.

Run a full GEO + AEO scan on your site

Frequently asked questions

What does the llms.txt validator check?
It checks the structure AI models expect: an H1 site name, a short blockquote summary, a ## Docs section with absolute https links, optional ## Optional links, reasonable file size, and plain text/markdown content type.
Can I validate a live URL?
Yes. Paste the URL (e.g., https://yourdomain.com/llms.txt) and the tool will fetch it server-side, then run the same checklist. You can also paste the file contents directly.
Is my file content stored?
No. The validator reads the file to run the checks and does not persist it. URLs are fetched once and the response is discarded.
What content type should llms.txt return?
text/plain or text/markdown is best. Avoid serving it as text/html, because that forces crawlers to strip tags before parsing the markdown.

Related free tools

Each one covers a different signal AI engines read before they cite a site.