Skip to main content
Field NotesGEO Playbook7 min read

llms.txt for Shopify — the 20-minute setup

Publishing an llms.txt is the single highest-leverage thing a Shopify merchant can do to become citable by AI assistants this quarter. Here is the exact template, the Shopify hosting workaround, and what changes once GPTBot starts fetching it.

Harry Parker
Co-founder, Onviqa Inc. · Surfient
llms-txt-token-budget.svg
TL;DR
  • llms.txt is a plain-text manifest at your root that tells AI assistants which of your pages to treat as canonical — it is the commerce equivalent of robots.txt + a curated sitemap.
  • Shopify doesn't host root-level files by default, so you either publish via the App Proxy, a theme-level /pages/llms route with a redirect, or a Cloudflare Worker in front of the store.
  • Expect the first GPTBot/PerplexityBot fetch within 7–14 days of publishing. First citations typically follow within 4 weeks on commercial prompts.

If you do one GEO task this quarter, do this one. A valid llms.txt at your store's root is the first thing the four big AI crawlers look for when they visit a domain, and it takes about twenty minutes to ship — plus a small Shopify-specific wrinkle we'll handle below.

What an llms.txt actually is

llms.txt is a plain-text manifest that sits at yourstore.com/llms.txt and tells AI assistants three things: who you are, which pages you consider canonical sources for which topics, and which sections of your site they should prioritise when answering questions about your brand.

It borrows its shape from robots.txt but its purpose from a sitemap. The difference is that llms.txt is curated. You don't dump every URL in it — you pick the fifteen or twenty pages you most want quoted when a shopper asks an assistant about your category.

Annotated preview of a Shopify store's /llms.txt file. Five canonical sections appear in order: H1 title with a one-sentence store summary (800 tokens), About with three linked bullets (800 tokens), Products with a short list of top SKUs plus a reference to /products.ndjson (4,800 tokens), Policies for shipping/returns/privacy (1,600 tokens), and Guides linking to non-commercial educational pages (1,200 tokens). Each annotation card on the right explains the section's job and which prompt types lean on it.
Figure 1 — The /llms.txt file a Shopify store should ship. Five canonical sections (H1, About, Products, Policies, Guides), each annotated with its purpose, its token cost, and which shopper prompts lean on it most heavily.

A Shopify-ready template

Here is the skeleton we ship for every Surfient customer. Copy it, swap the bracketed placeholders, and you have a valid file.

# [Your Store Name]

> [One-sentence description: what you sell, who you sell it to, what
> makes your catalogue different. Assistants quote this line verbatim
> more than any other in the file.]

## Core catalogue
- [/collections/bestsellers](https://yourstore.com/collections/bestsellers): Your most cited SKUs
- [/collections/new](https://yourstore.com/collections/new): Recent additions
- [/products/hero-product](https://yourstore.com/products/hero-product): Flagship product page

## Policies
- [/pages/shipping](https://yourstore.com/pages/shipping): Shipping, returns, warranty
- [/pages/sustainability](https://yourstore.com/pages/sustainability): Materials and sourcing
- [/pages/sizing](https://yourstore.com/pages/sizing): Size chart and fit guide

## About
- [/pages/about](https://yourstore.com/pages/about): Brand story and team
- [/pages/press](https://yourstore.com/pages/press): Press and reviews coverage

## Optional
- [/blog](https://yourstore.com/blog): Long-form guides and buying advice
- [/pages/faq](https://yourstore.com/pages/faq): Answers to frequent shopper questions

The Shopify hosting wrinkle

Shopify does not let you serve a static file from the domain root directly. There are three workable paths; pick the one that matches your stack.

Option A — App Proxy (recommended)

If you have any Shopify app that includes an App Proxy (Surfient does, but so do most SEO or headless apps), route /llms.txt through the proxy to a server you control. This is the only option that serves the file from the actual root with no redirect, which is what GPTBot and PerplexityBot expect.

Option B — Theme page + redirect

Create a page at /pages/llms with the Markdown as its body (rendered as <pre>), then add a URL redirect in Online Store → Navigation → URL Redirectsfrom /llms.txt to /pages/llms. GPTBot and ClaudeBot follow the 301; Perplexity is sometimes flaky on redirects but currently does follow them.

Option C — Cloudflare Worker

If you already run Cloudflare in front of your Shopify store (common for stores with a custom domain), a 15-line Worker that serves the file for the /llms.txt path and passes everything else to Shopify is the cleanest long-term option. Zero app dependency, zero redirect.

Budgeting the file: 12,000 tokens, split five ways

The file itself has a ceiling. The retrievers we've profiled cap the ingest at roughly 12,000 tokens (about 48 KB of English prose) before they start truncating. That's more than enough for any reasonable Shopify store — but only if you spend it with intent. Our default split, shown in Figure 2, reserves 30% of the budget as growth headroom so the file can absorb new SKUs, policies, and guides without a rewrite.

Donut chart showing the recommended token split for a 12,000-token /llms.txt file on a typical Shopify store. Products 40 percent (4,800 tokens), About 6.7 percent (800), Policies 13.3 percent (1,600), Guides 10 percent (1,200), and Reserved headroom 30 percent (3,600). Each slice is paired with a legend card warning of a common anti-pattern for that section.
Figure 2 — How to spend a 12,000-token budget. Products get 40% (4,800 tokens), Policies 13.3% (1,600), Guides 10% (1,200), About 6.7% (800), with a deliberate 30% reserved headroom (3,600) for growth.

What to actually include

  • A one-sentence brand description using the exact phrasing you want assistants to quote back to shoppers — this is the single most frequently lifted line.
  • Your top 3–5 collection URLs, each with a one-line description that mentions the category and the key differentiator.
  • Every policy page (shipping, returns, warranty, sizing, sustainability) — assistants cite these constantly when shoppers ask pre-purchase questions.
  • Your 5–10 best-selling PDPs by name, with a plain-language sentence describing what the product is. Skip the SKU gibberish; write for a shopper.
  • Your About page and any press page — assistants weight these for brand authority signals.
  • Your blog or buying-guide hub if you have one. Models preferentially cite long-form guides over marketing copy when asked for advice.

What not to include

Your cart, checkout, account, and search-results pages. Your order tracking page. Any page behind a password or gated by JavaScript. Any page you don't want to be cited as authoritative — which for most stores means your outdated blog archive and any old landing pages you built for a campaign that ran in 2023.

After you publish

Once the file is live, log the deployment date. The four major crawlers hit the root with different cadences, but in our telemetry:

  • GPTBot fetches the new file within 7–10 days on average.
  • PerplexityBot is the fastest — usually within 72 hours.
  • ClaudeBot polls weekly on most domains, so allow up to 14 days.
  • Google's AI Overviews crawler doesn't specifically fetch llms.txt yet, but it benefits from the same canonical pages you've surfaced.

First citations on commercial prompts typically start within four weeks of the file going live. You won't see them in Shopify analytics — they show up as direct traffic or don't show up at all — so the only reliable way to measure impact is citation monitoring: running your prompt list against the four assistants on a schedule and comparing week over week.

Tags:llms.txtShopifyGPTBotClaudeBotGEO

Frequently asked questions

Try Surfient free

See how your Shopify store scores with AI engines

Surfient audits every signal ChatGPT, Perplexity, Claude, and Google AI Overviews read on your store — in under 60 seconds, with no install, no card, no catch.

  • ChatGPT, Perplexity, Claude, and AI Overviews
  • Store-by-store score with fix priorities
  • 60-second audit, no install or card
Harry Parker
Co-founder, Onviqa Inc. · Surfient

Harry has led SEO and e-commerce engineering for over 12 years and has been shipping Shopify software since Onviqa was founded in 2014. He writes about where commerce is headed when shoppers stop typing queries and start asking assistants.

Related reading

All posts