search ]

How to Add llms-full.txt to WordPress (Serve Full Markdown Content to AI)

The llms.txt standard gives AI systems a summary of your site – a curated index of your most important pages. But what if you want AI to access the full content, not just links and descriptions?

That’s what llms-full.txt is for. It extends llms.txt by embedding the actual content of each referenced page in a single Markdown file. AI systems can read your entire knowledge base in one request instead of crawling individual pages.

In this guide, you’ll learn how llms-full.txt works, how to structure it, and how to serve it from a WordPress site – manually or with a plugin.

“llms-full.txt is an optional extension that provides the full content of documents referenced in llms.txt, formatted as Markdown. It allows LLMs to ingest an entire site’s knowledge in a single request.” – llmstxt.org specification.

What Is llms-full.txt?

While llms.txt is a directory – a list of links with short descriptions – llms-full.txt is a complete document. It contains the actual text content of each page listed in your llms.txt, converted to Markdown and organized under the same heading structure.

The file lives at your site root, next to llms.txt: https://yoursite.com/llms-full.txt.

When an AI system like ChatGPT, Claude, or Perplexity encounters your llms-full.txt, it can consume all your content in one pass. No need to follow links and crawl pages individually.

llms.txt vs. llms-full.txt

Here’s how the two files compare:

Featurellms.txtllms-full.txt
PurposeIndex of key pagesFull content of those pages
ContentLinks + short descriptionsComplete Markdown text
File sizeSmall (a few KB)Large (can be hundreds of KB)
AI behaviorDiscovers what exists, then crawlsReads everything in one request
Best forLarge sites with many pagesFocused sites, documentation, blogs
Required?RecommendedOptional

Think of llms.txt as a table of contents and llms-full.txt as the entire book.

llms-full.txt is optional. You don’t need it to benefit from the llms.txt standard. Start with llms.txt first, and add llms-full.txt when you want AI systems to have deeper access to your content without crawling each page.

How to Structure llms-full.txt

The file follows the same Markdown hierarchy as llms.txt, but replaces links with actual content. Here is the basic structure:

# Your Site Name

> A brief description of your site and what it covers.

## Section Name

### Page Title

Full content of the page goes here, converted to Markdown.
Paragraphs, lists, code blocks, and headings are all preserved.

### Another Page Title

Full content of this page...

## Another Section

### Page Title

Content here...

Key Rules

Follow these rules when creating the file:

  • H1 (#): Your site or brand name. Used once at the top.
  • Blockquote (>): A one-line description of your site, right after the H1.
  • H2 (##): Section headings that group related content (e.g., “Guides”, “API Reference”, “Blog Posts”).
  • H3 (###): Individual page titles. The full content of each page appears below its H3 heading.
  • Format: Pure Markdown. No HTML tags, no shortcodes, no JavaScript.
  • Encoding: UTF-8, served with text/plain or text/markdown MIME type.

Example: Blog With Three Posts

Here’s what a llms-full.txt might look like for a small blog:

# Savvy Blog

> Professional WordPress development, SEO, and performance optimization guides.

## WordPress SEO

### What Is llms.txt?

llms.txt is a proposed standard that helps AI systems understand your site.
It acts as a curated directory, written in Markdown, that lists your most
important pages with brief descriptions...

(full article content continues here)

### How to Block AI Crawlers with robots.txt

AI crawlers visit your website every day. OpenAI's GPTBot, Anthropic's
ClaudeBot, and dozens of others scrape content to train large language
models...

(full article content continues here)

## WordPress Development

### How to Create a Child Theme

A child theme inherits the functionality of a parent theme while allowing
you to customize styles and templates without modifying the original...

(full article content continues here)

How to Create llms-full.txt Manually

If your site is small or you prefer full control, you can create the file by hand. Here are the steps:

  1. Open a plain text editor (VS Code, Sublime Text, or similar)
  2. Start with your H1 site name and a blockquote description
  3. For each page you want to include, add an H3 heading with the page title
  4. Paste the content of that page, converted to Markdown – strip all HTML, shortcodes, and scripts
  5. Group related pages under H2 section headings
  6. Save the file as llms-full.txt
  7. Upload it to your site’s root directory via FTP or your hosting file manager

Converting HTML to Markdown means replacing <h2> with ##, <strong> with **, <a href="..."> with [text](url), <ul><li> with -, and so on. Remove all WordPress shortcodes, widgets, and sidebar content – keep only the main article text.

Using a WordPress Plugin

Several WordPress plugins can generate llms-full.txt automatically by converting your posts to Markdown:

  • LLMs.txt and LLMs-Full.txt Generator – generates both files from your published posts. Supports Yoast, Rank Math, and custom post types. Files are saved to your site root and can be regenerated when content changes.
  • Markdown Mirror – serves Markdown versions of posts on-the-fly by appending .md to any URL. Also auto-generates an llms.txt index. Zero configuration required.
  • LLM-Friendly WP – converts posts to Markdown accessible via ?md=1 query parameter. Creates an llms.txt directory from your published content.

For most WordPress sites, the LLMs.txt and LLMs-Full.txt Generator plugin is the simplest option. Install it, select which post types to include, and it builds both files for you.

Custom PHP Approach

If you want full control without a plugin, you can generate llms-full.txt with a custom function in your theme’s functions.php or a custom plugin. Here’s a basic approach:

add_action( 'init', function() {
    if ( ! isset( $_GET['llms-full'] ) ) {
        return;
    }

    $posts = get_posts( array(
        'post_type'      => 'post',
        'post_status'    => 'publish',
        'posts_per_page' => -1,
        'orderby'        => 'date',
        'order'          => 'DESC',
    ) );

    header( 'Content-Type: text/plain; charset=utf-8' );

    echo "# " . get_bloginfo( 'name' ) . "\n\n";
    echo "> " . get_bloginfo( 'description' ) . "\n\n";

    $categories = array();
    foreach ( $posts as $post ) {
        $cats = get_the_category( $post->ID );
        $cat_name = ! empty( $cats ) ? $cats[0]->name : 'Uncategorized';
        $categories[ $cat_name ][] = $post;
    }

    foreach ( $categories as $cat_name => $cat_posts ) {
        echo "## " . $cat_name . "\n\n";
        foreach ( $cat_posts as $post ) {
            echo "### " . $post->post_title . "\n\n";
            $content = wp_strip_all_tags( $post->post_content );
            $content = strip_shortcodes( $content );
            echo $content . "\n\n";
        }
    }

    exit;
} );

This basic example strips HTML and shortcodes, then outputs all posts grouped by category. Access it at https://yoursite.com/?llms-full=1.

For a production-ready solution, you’d want to add proper Markdown conversion (preserving headings, lists, and links), caching with a transient, and a rewrite rule so the file is served at /llms-full.txt instead of a query parameter.

The PHP approach above uses wp_strip_all_tags(), which removes all HTML but doesn’t convert it to Markdown. For proper conversion that preserves heading hierarchy, lists, and links, consider using a PHP Markdown library like league/html-to-markdown or generate a static file instead.

Best Practices

Follow these guidelines to get the most out of your llms-full.txt:

  • Keep it focused. Don’t dump every page into the file. Include only your best, most valuable content – the pages you want AI to cite and reference.
  • Update regularly. When you publish or update important content, regenerate the file. Stale content leads to outdated AI responses.
  • Mind the file size. LLMs have context window limits. A file that’s hundreds of pages long may be truncated. Prioritize quality over quantity.
  • Use clean Markdown. No HTML, no shortcodes, no inline styles. Pure Markdown parses better and wastes less of the AI’s context window.
  • Pair it with llms.txt. Always maintain an llms.txt alongside llms-full.txt. Some AI systems prefer the summary, others want the full content. Serve both.
  • Complement your robots.txt strategy. If you block AI training crawlers but allow citation crawlers, llms-full.txt gives those citation crawlers a clean, structured version of your content.

How to Test Your llms-full.txt

After creating the file, verify it works correctly:

  1. Visit https://yoursite.com/llms-full.txt in your browser and confirm it loads as plain text
  2. Check the MIME type returns text/plain or text/markdown
  3. Validate the Markdown structure – each section should have proper H2/H3 headings
  4. Confirm the content matches your current published posts (no outdated or draft content)
  5. Test with an AI assistant – paste the URL into ChatGPT or Claude and ask it to summarize your site based on the file

You can also check the file size. If it exceeds 1-2 MB, consider trimming less important content or using llms.txt alone for Generative Engine Optimization (GEO) purposes.

FAQs

Common questions about llms-full.txt in WordPress:

What is the difference between llms.txt and llms-full.txt?
llms.txt is a directory - it lists your key pages with links and short descriptions. llms-full.txt contains the actual full content of those pages, converted to Markdown. Think of llms.txt as a table of contents and llms-full.txt as the entire book. Both are served from your site root.
Do I need llms-full.txt if I already have llms.txt?
No. llms-full.txt is optional. llms.txt alone provides AI systems with a structured overview of your site. Add llms-full.txt when you want AI to access your complete content in one request, which is especially useful for documentation sites, focused blogs, and knowledge bases.
How large should llms-full.txt be?
There is no official size limit, but keep in mind that LLMs have context window limits. A file under 1-2 MB works well for most AI systems. If your site has hundreds of posts, include only your most important content rather than everything. Prioritize quality and relevance over quantity.
Should I include HTML or shortcodes in llms-full.txt?
No. llms-full.txt should contain pure Markdown only. Strip all HTML tags, WordPress shortcodes, inline styles, and JavaScript. Clean Markdown is easier for AI systems to parse and wastes less of their context window. Convert headings to # syntax, links to [text](url), and lists to - or 1. format.
How often should I update llms-full.txt?
Update it whenever you publish or significantly edit important content. If you use a WordPress plugin that generates it automatically, make sure to regenerate the file after content changes. Stale content in llms-full.txt can lead to AI systems providing outdated information about your site.
Which AI systems read llms-full.txt?
The llms.txt standard (including llms-full.txt) is a proposed convention, not a universally adopted protocol yet. AI systems like ChatGPT, Claude, and Perplexity can read and use it when prompted or when their crawlers discover it. Adoption is growing as more sites implement the standard and more AI providers recognize it.

Summary

llms-full.txt extends the llms.txt standard by embedding your full page content in a single Markdown file. AI systems can read your entire site’s knowledge base in one request instead of crawling pages individually.

For WordPress sites, you can create the file manually, use a plugin like the LLMs.txt Generator, or build a custom PHP solution. Focus on your best content, keep the Markdown clean, and update the file when your content changes.

Pair llms-full.txt with llms.txt for complete coverage: the summary for AI systems that want a quick overview, and the full version for those that want everything.

Join the Discussion
0 Comments  ]

Leave a Comment

To add code, use the buttons below. For instance, click the PHP button to insert PHP code within the shortcode. If you notice any typos, please let us know!

Savvy WordPress Development official logo