Shopify SEO

How to do SEO on Shopify — fixed URL routes, duplicate product URLs, robots.txt.liquid customization, hreflang under Shopify Markets, the auto-generated sitemap, and the theme-dependent gap in product schema.

First published: Jun 25, 2026 · Last updated: Jul 19, 2026 · Advanced
demand #1 in Ecommerce Platforms#3 in Platform SEO#46 in Technical SEO#63 on the site

Shopify handles a surprising amount of SEO for you — an auto-generated XML sitemap, a canonical tag on every page, HTTPS on a fast CDN, and optional 301s when you change a URL. In return it locks down the URL structure (/products/, /collections/, /pages/, /blogs/), though robots.txt can be customized on any plan through a robots.txt.liquid template. The one Shopify-specific thing to understand is that every product reachable through a collection gets a duplicate /collections/.../products/... URL — which Shopify canonicalizes back to the clean /products/ URL automatically. hreflang is auto-generated once Shopify Markets is configured. Product and breadcrumb schema are theme-dependent, not guaranteed.

TL;DR — Shopify is a hosted platform, so the technical SEO floor is high and the ceiling is capped. It auto-generates /sitemap.xml, adds rel=canonical everywhere, runs HTTPS on a CDN, and offers 301s on URL change. The fixed URL structure (/products/, /collections/, /pages/, /blogs/) can’t be changed except with specialized routing approaches, and robots.txt can be customized through a Liquid template. The defining Shopify issue is the duplicate product URL: any product reachable through a collection gets a /collections/{c}/products/{p} URL alongside its canonical /products/{p} URL, and Shopify auto-canonicalizes the duplicate back to the clean one. Product and breadcrumb JSON-LD are theme-dependent, not platform-guaranteed.

Evidence for this claim Shopify generates robots.txt and supports customization through robots.txt.liquid. Scope: Current online-store themes; Shopify cautions against unnecessary changes. Confidence: high · Verified: Shopify: Edit robots.txt.liquid

The mental model: a high floor with a low ceiling

The useful way to think about Shopify SEO is that it’s a hosted SaaS platform. That cuts both ways. Compared with a self-hosted stack like WooCommerce, the technical floor is much higher — Shopify handles canonicalization, sitemaps, SSL, and CDN delivery for you, and you can’t easily break them. But the ceiling is lower: you don’t get server access and you can’t rewrite the URL structure. robots.txt is a partial exception — Shopify generates it, but any store can override parts of it via a robots.txt.liquid theme template. Most of Shopify SEO is understanding which levers exist and which are welded shut.

The fixed URL structure

Shopify uses fixed route prefixes for its main resource types:

Evidence for this claim Shopify resource URLs use platform route prefixes such as /products/ and /collections/. Scope: Standard Online Store resource routes. Confidence: high · Verified: Shopify: URL redirects Evidence for this claim Shopify generates robots.txt and supports customization through robots.txt.liquid. Scope: Current online-store themes; Shopify cautions against unnecessary changes. Confidence: high · Verified: Shopify: Edit robots.txt.liquid
  • Products: /products/{product-handle}
  • Collections: /collections/{collection-handle}
  • Static pages: /pages/{page-handle}
  • Blog: /blogs/{blog-handle}/{post-handle}

You can edit each handle (slug), but not the prefix. This is the cleanest point of comparison with other platforms: BigCommerce lets you strip prefixes entirely for a flat /{product-name}/ structure, and WooCommerce lets you reshape its permalink base. Shopify does not. The practical SEO impact, though, is small — Google’s John Mueller has said more than once that keywords or structure in a URL are, at most, a very lightweight ranking factor once a page has been crawled and Google understands its content. I wouldn’t migrate a store or fight the platform over the /products/ prefix.

(On Shopify Plus there are some workarounds — URL rewrites and apps — but they’re edge cases, not a general “turn off the prefix” toggle.)

The duplicate product URL — the defining Shopify issue

This is the one genuinely Shopify-specific thing you need to understand, so let me be precise about it.

Every product has a canonical URL of the form /products/{product-handle}. But the moment a product is part of a collection, it also becomes reachable at:

/collections/{collection-handle}/products/{product-handle}

So a product in three collections is reachable at four URLs (the canonical plus one per collection). On the face of it, that’s textbook duplicate content. What saves you is that Shopify automatically emits a rel=canonical pointing every collection-scoped variant back to the bare /products/{product-handle} URL. The duplicates exist, but they’re correctly consolidated by default.

The product may have several reachable paths; verify both the canonical output and the URLs your theme links internally.

Two collection-context URLs and the clean products URL reach the same product. Collection-scoped pages emit a canonical signal toward the clean products URL, while theme-generated internal links independently determine which paths crawlers repeatedly discover. Both outputs require live verification.

That means the canonical side of this is handled — but two things are still worth doing:

  1. Link to the canonical URL internally. If your theme links products from collection pages using the long /collections/.../products/... form, you’re spending internal link signals and crawl requests on URLs that just canonicalize away. Many modern themes already link to the clean /products/ URL; it’s worth checking yours.
  2. Don’t fight the canonical. I’ve seen people try to “fix” this by noindexing collection-scoped product URLs or blocking them. You don’t need to. The canonical already does the consolidation; piling on noindex or robots blocks just adds risk. (If you want the deeper reasoning on why a robots block is not a deindex tool, see the duplicate content and canonicalization write-ups.)

robots.txt: generated by default, customizable with Liquid

Shopify generates robots.txt by default, and you can customize it by adding a templates/robots.txt.liquid file to the theme. The generated defaults remain the safest baseline for most stores. The defaults are sensible (cart, checkout, and account spaces are kept out). If you genuinely need custom rules — say you want to keep crawlers out of a specific filtered URL space — you have two options:

  • When custom rules are justified: edit robots.txt by adding a robots.txt.liquid template to your theme, which lets you add or remove rules programmatically. Shopify’s default rules are output through {{ robots }}, so a typical override extends rather than replaces them — for example, to keep crawlers out of a filtered collection URL space:

    {%- comment -%} theme file: templates/robots.txt.liquid {%- endcomment -%}
    {{ robots }}
    
    User-agent: *
    Disallow: /collections/*+*
    Disallow: /collections/*%2B*
    Disallow: /collections/*filter*
  • Reach for noindex for indexing decisions, not robots.txt: when the goal is keeping a specific page out of the index rather than blocking crawlers from a URL pattern, use meta robots / noindex via theme Liquid instead. Remember the usual rule — robots.txt controls crawling, noindex controls indexing, and they’re not interchangeable.

The auto-generated sitemap

Shopify generates an XML sitemap automatically at /sitemap.xml. It’s actually a sitemap index that links out to child sitemaps for products, collections, pages, and blog posts. You submit yourstore.com/sitemap.xml to Google Search Console and Bing Webmaster Tools and Shopify keeps it current. You can’t hand-edit it; if you want a URL out of the sitemap you control that through the page’s indexing settings / theme, not by editing the file.

Structured data is theme-dependent, not platform-guaranteed

This is the gap that trips up the most stores. Shopify does not reliably output Product JSON-LD on every theme, and the same goes for BreadcrumbList. Whether your product pages are eligible for rich results — price, availability, review stars — depends entirely on whether your theme emits the markup. Some of the newer Shopify themes do include Product schema; plenty of older or third-party themes don’t, or emit an incomplete version.

Google’s own guidance is worth keeping in front of you here. Its Product structured data documentation spells out what merchant-listing-grade product markup is for:

“Merchant listings: For pages where customers can purchase products from you. This markup has more options for specifying detailed product information, like apparel sizing, shipping details, and return policy information.”

And the same page is explicit that pairing on-page structured data with a Merchant Center feed maximizes your eligibility:

“Providing both structured data on web pages and a Merchant Center feed maximizes your eligibility to experiences and helps Google correctly understand and verify your data.”

Practically, this means: check what your theme actually outputs with the Rich Results Test, and if it’s missing or thin, add it — either by editing the theme’s Liquid templates or with a schema app. Don’t assume Shopify did it for you.

One caution worth stating plainly: structured data is a visibility and CTR play, not a ranking shortcut. It can win you rich results; it won’t, on its own, move your position.

International SEO: Shopify Markets and hreflang

If your store uses Shopify Markets, Shopify adds hreflang tags to your theme automatically — through the content_for_header object that your theme renders in the <head> of layout/theme.liquid. Those tags reflect each market’s language and region (a country-specific market produces a region-qualified tag like fr-ca; a broader market produces a language-only tag like fr), they update automatically whenever you add, remove, or change a market’s domains or languages, and they stay in sync with each page’s canonical URL so localized versions read as related pages, not duplicates.

Two things worth knowing before you touch this yourself:

  • Don’t stack your own hreflang tags on top of the automatic ones. Shopify’s own documentation is blunt about the risk: doing so “can produce duplicate or conflicting annotations, which can hurt your store’s search ranking.” If a theme or app is already emitting hreflang, turn the automatic tags off first (Online Store > Preferences > Social sharing and SEO > Automatic hreflang tags) rather than layering more on top.
  • Manual hreflang is for edge cases Markets can’t coordinate — the documented example is linking alternate-language versions of a page across separate Shopify stores on different domains. If you do go manual, build the tags from the store’s localization data rather than hardcoding product or collection handles, since a handle can differ per language.

Collections, facets, and the URL explosion

Collection pages are usually your highest-value landing pages, and they’re where the real ecommerce SEO work lives — the same faceted-navigation problem you’d have on any platform.

  • Write unique collection descriptions. They’re empty by default, leaving the page as a bare product grid. This is the single most common on-page miss on Shopify.
  • Watch sort and filter parameters. Shopify’s filtering and sorting append URL parameters (e.g. ?sort_by=, and tag/filter paths). At scale these multiply into a large near-duplicate URL space — the classic faceted-navigation crawl problem. Shopify’s canonicals help, but for filter combinations you don’t want indexed, lean on canonicals to the clean collection URL and noindex where appropriate. The full strategy lives in the Ecommerce SEO hub.
  • Mind pagination. Give each paginated page its own URL and a self-referencing canonical; don’t try to noindex deep pages, and don’t rely on rel=prev/next (Google stopped using those in 2019).

Where Shopify sits versus other platforms

AreaShopifyWhat it means
URL structureFixed /products/, /collections/, etc.Can’t strip prefixes (vs BigCommerce); minor ranking impact
robots.txtGenerated by default; customizable via LiquidUse meta robots for indexing control
SitemapAuto-generated /sitemap.xmlNo manual editing; submit and forget
Canonical tagsAuto on every page; consolidates collection product URLsThe duplicate-URL issue is handled for you
Product schemaTheme-dependent, not guaranteedVerify with Rich Results Test; add via theme/app if missing
SSL / CDNIncludedSolid speed/security baseline
App ecosystemVery large (hundreds of SEO apps)Plenty of schema/redirect/meta tooling available
hreflangAuto-added once Markets is configured; syncs with canonicalDon’t add manual tags on top — turn automatic tags off first if a theme/app already emits them

The honest summary: Shopify removes a lot of the ways you can hurt yourself and a few of the ways you can help yourself. The defaults are good; the work that’s left is content, schema verification, and faceted-navigation discipline — not fighting the platform.

  • Ecommerce SEO — the pillar, including the faceted-navigation deep dive that collection/filter URLs depend on.
  • Canonicalization — how rel=canonical consolidates duplicates (the mechanism behind Shopify’s auto-canonicals).
  • Duplicate content — why duplicate URLs usually aren’t a penalty, and why you shouldn’t block them.
  • Canonical tag (rel=canonical) — the tag itself, in depth.

Add an expert note

Pin an expert quote

New person? Create their unclaimed profile at /admin/experts/ → Pin an expert quote first.