← Guides

llms.txt in WooCommerce: automatic and manual

How llms.txt in WooCommerce is different

The general idea of the file is covered in the llms.txt for your store guide: a short curated map of your shop for language models. This guide is about the WooCommerce specifics, where two things are different.

First, the catalog is alive: prices, stock and categories change constantly in WooCommerce. A static file built once by hand goes stale within a week. Second, WordPress routes URLs its own way, so a physical file in the root behaves differently from a virtual route served by a plugin. That gives WooCommerce two paths: build llms.txt automatically or place it by hand.

Why it is worth the effort at all: by the AI traffic index, a two-week window across a panel of three stores drew about 1,005,146 AI-bot requests, and the single most-read product pulled 73,715. Bots already crawl catalogs at scale — llms.txt helps them grasp your store's structure faster than parsing dozens of HTML pages.

The two paths at a glance

Automatic (plugin)Manual
Who builds itthe plugin, from the catalogyou
Updatesitself, when the catalog changesby hand after every edit
Categories and productspulled from WooCommercetyped in manually
Best fora live cataloga small, static one

Automatic: the Botmetria plugin

The Botmetria plugin for WooCommerce generates llms.txt from your own catalog and keeps it current. It pulls data straight from the store:

The point is that the file updates when the catalog changes. Add a category, mark a product out of stock, edit the returns page — llms.txt rebuilds itself. You do not keep it current by hand, and that is exactly where it usually breaks: the file is built once and forgotten.

The same plugin also outputs a correct JSON-LD Product with price, currency and availability, so your catalog becomes readable for AI from both sides: the map in llms.txt and the product data in the markup.

Manual: a file in the root

If you would rather not install the plugin, you can place llms.txt by hand. WooCommerce gives you two working ways.

Option 1 — a physical file. Through your host's File Manager or over FTP, drop a text file named llms.txt into the site root — next to wp-config.php and .htaccess (usually public_html). The standard WordPress .htaccess serves existing files directly instead of routing them — that is what the RewriteCond %{REQUEST_FILENAME} !-f rule does. The file opens at https://your-store.com/llms.txt.

Option 2 — a virtual route. If you have no file access, serve the file with a snippet. Add this to your child theme's functions.php or a code-snippets plugin:

add_action('init', function () {
  if (trim($_SERVER['REQUEST_URI'], '/') === 'llms.txt') {
    header('Content-Type: text/plain; charset=utf-8');
    echo "# Example Store\n\n> What we sell and how we ship.\n\n## Catalog\n- ...\n";
    exit;
  }
});

What goes inside is covered in the general guide: a title, a description line, 3-4 sections of 3-6 links. For WooCommerce, link to categories (/product-category/), a few key products and your policy pages — not the whole catalog of hundreds of items.

Where it lives and how to check

  1. Open https://your-store.com/llms.txt in a browser. You should see plain text, not a styled page and not a 404.
  2. Check the response type. WordPress is tricky: a missing address is sometimes served as an HTML 404 page but with a 200 OK code. To AI that is garbage. llms.txt must be served as text/plain with a 200 code. The fastest check is curl -sI https://your-store.com/llms.txt — look for HTTP/2 200 and content-type: text/plain in the response.
  3. Confirm the links inside point to live catalog pages, not 404s and not http.
  4. Run a free Botmetria audit — it checks whether llms.txt is present and correct and shows whether AI bots have requested it. This is the discovery category, 20% of the AI-readiness score.

Common WooCommerce mistakes

FAQ

Do I need the plugin to have llms.txt in WooCommerce?

No. You can place the file by hand — physically in the site root or served by a functions.php snippet. The Botmetria plugin's advantage is that it rebuilds the file from your catalog automatically, so it never goes stale when categories, prices or stock change.

Does the Botmetria plugin create a physical or a virtual file?

A virtual route: the plugin serves fresh content at /llms.txt, assembled from your live WooCommerce catalog. So the file always stays in sync with categories, products and policies — you never store or update it by hand.

llms.txt opens in my browser but the audit does not see it. Why?

Most likely WordPress serves its own HTML 404 page with a 200 code, or the response content-type is text/html. To AI that is invalid. Check with curl -sI: you need a real 200 code and content-type text/plain.

Related guides

Check your store for free

A 60-second audit shows how ready your store is for AI agents — and exactly what to fix first.

Run the free audit