Short description of issue
The documented robots.txt.liquid template outputs a different, older set of rules than the robots.txt Shopify serves when no template exists, so a store can’t customise robots.txt without losing the current default.
Reproduction steps
- On a store with no
templates/robots.txt.liquid, fetch/robots.txtand save it. - Add
templates/robots.txt.liquidcontaining the unmodified example from the robots.txt.liquid docs. - Fetch
/robots.txtagain (we usedshopify theme dev) and compare.
Expected: the same output, since the template only loops over robots.default_groups.
Actual: a different, older rule set (63 rules under User-agent: * against 45).
- Only in the managed default: the agent/UCP comment header,
Allow: /plus 20 moreAllowrules,Allow: /account/login, andDisallowfor/cart.js,/services,/sf_*,/<shop-id>and the locale-prefixed checkout/account paths. - Only in
default_groups:Disallow: /search,/policies/,/apple-app-site-associationand/services/login_with_shop, the*-remoteproduct rules, and groups for Nutch, Ahrefs, MJ12bot and Pinterest.
Additional info
This isn’t minor drift: /search goes from crawlable to disallowed depending on whether a template exists. The template only loops over the object, so nothing a merchant writes can restore the current rules.
Our case: we needed to drop one rule, Disallow: /collections/*sort_by*. Google held 258 of our sorted collection URLs as “Indexed, though blocked by robots.txt”, unable to crawl them to read their canonicals; three weeks after removing the rule it’s 13. The loop didn’t reproduce our default, so we pasted the managed output in as plain text, minus that rule. Our robots.txt is now frozen at 12 Sep 2026 and won’t pick up Shopify’s changes.
Expected fix: default_groups returns the current rules and header, or the docs say it doesn’t.
Related: an August request wants to add one line without losing the rest; we wanted to remove one.
What type of topic is this
Bug report