Seo variant urls not canonicalized
Moderate effortFound on 1% of audited stores.
Add a canonical tag to every product variant URL pointing back to the base product page, so Google consolidates ranking signals onto one authoritative URL instead of splitting them across hundreds of near-duplicate pages.
What it is
When a shopper picks a color, size, or other option on a product page, most ecommerce platforms create a new URL — for example, `/products/my-shirt?color=Red` or `/products/my-shirt?size=L`. These variant URLs contain almost identical content to the main product page. A canonical tag is a small HTML snippet you place in the `<head>` of each variant page that says to Google: "The definitive version of this content lives at [base product URL] — please treat that as the real one." It does not redirect shoppers; it only guides search engines.
Why it matters
Without canonical tags on variant URLs, Google sees hundreds or thousands of near-duplicate product pages and must guess which one to rank. This splits your "link equity" (the ranking power earned from backlinks and user signals) across all variants instead of concentrating it on your main product page, pushing every version lower in search results. It also wastes your crawl budget — Googlebot spends time re-crawling colour and size variants instead of discovering new products or categories. Stores with large catalogues (hundreds of products × multiple variants) can lose significant organic traffic this way. Fixing canonicalisation is one of the highest-ROI SEO tasks for any product-rich store.
How to fix it
- Identify every URL pattern your platform generates for product variants (e.g. query-string parameters like ?color=, ?size=, ?variant=, or path segments like /products/shirt-red).
- For each variant URL, determine the correct canonical — almost always the clean base product URL with no variant parameters (e.g. /products/my-shirt).
- Add a <link rel="canonical" href="https://www.example.com/products/my-shirt"> tag inside the <head> of every variant page, referencing the absolute base product URL.
- Ensure the base product page also has a self-referencing canonical tag pointing to itself (same absolute URL).
- After publishing, verify with Google Search Console's URL Inspection tool: paste a variant URL, fetch it, and confirm the 'Canonical' field shows the base product URL.
- If your platform generates sitemaps automatically, confirm variant URLs are excluded from the sitemap (only canonical base product URLs should appear).
<link rel="canonical" href="https://www.example.com/products/base-product-slug">Fix it on your platform
Pick your platform for the exact steps.
How to fix seo variant urls not canonicalized on Shopify
- Shopify automatically adds a self-referencing canonical to base product pages, but variant URLs (e.g. ?variant=12345) do NOT get a canonical pointing to the base by default in most themes.
- In your Shopify admin, go to Online Store → Themes → your active theme → ⋯ (Actions) → Edit code.
- Open theme/layout/theme.liquid (or the equivalent layout file).
- Locate the existing <link rel="canonical"> line. Shopify's default canonical uses {{ canonical_url }}, which resolves to the variant URL when a variant is selected.
- Replace or wrap that line so variant pages always point to the product's base URL. The safest Liquid snippet is: {% if template == 'product' %}<link rel="canonical" href="{{ shop.url }}{{ product.url }}">{% else %}<link rel="canonical" href="{{ canonical_url }}">{% endif %}
- product.url in Liquid always returns the root product URL without variant parameters, so this forces all variant pages to canonicalise back to the base product.
- Save the file, then use Google Search Console's URL Inspection tool on a ?variant= URL to confirm the canonical shows the clean product URL.
How to fix seo variant urls not canonicalized on Shopify Plus
- Follow the same steps as Shopify above — Shopify Plus uses identical theme architecture.
- If you use a custom storefront (Hydrogen/Remix), add the canonical <link> server-side in your product route's loader, outputting the base product URL (without searchParams) inside the <head> component for every variant route.
- For headless setups, ensure your meta component or document HEAD template outputs <link rel="canonical" href={productBaseUrl}> where productBaseUrl strips all query/variant parameters.
How to fix seo variant urls not canonicalized on WooCommerce
- Install the free Yoast SEO or Rank Math SEO plugin if not already present (Plugins → Add New, search for 'Yoast SEO' or 'Rank Math').
- WooCommerce variable products generate URLs like /products/my-shirt/?attribute_pa_color=red. Yoast SEO and Rank Math both automatically canonicalise attribute/variation URLs back to the base product URL — confirm this is active.
- In Yoast SEO: go to SEO → Search Appearance → WooCommerce and ensure 'Product Variations' is set to 'noindex' or that canonicals are handled (Yoast handles this transparently).
- In Rank Math: go to Rank Math → Titles & Meta → WooCommerce and verify 'Canonical URL' is enabled for product pages.
- If you have a custom or headless WooCommerce setup, add the canonical programmatically in your theme's functions.php: add_action('wp_head', function(){ if(is_product()){ global $post; echo '<link rel="canonical" href="'.get_permalink($post->ID).'">'; } });
- Test with Google Search Console URL Inspection on a ?attribute_ variant URL.
How to fix seo variant urls not canonicalized on BigCommerce
- BigCommerce natively generates variant URLs like /products/my-shirt?color=Red. As of current platform versions, BigCommerce automatically outputs a canonical tag on product pages pointing to the base product URL — verify this is working.
- In your admin, go to Storefront → Script Manager and check no third-party script is overriding the canonical tag.
- To verify: view the page source of a variant URL (right-click → View Page Source, Ctrl+F for 'canonical') and confirm the href is the base product URL without query parameters.
- If using a Stencil theme, open templates/layout/base.html in the Theme Editor (Storefront → Themes → Advanced → Edit Theme Files) and confirm {{canonicalUrl}} resolves to the base product. If it does not, hardcode it for product templates: in templates/pages/product.html, add <link rel="canonical" href="{{product.url}}"> inside {{#partial "head"}}.
- Check your XML sitemap (yourstore.com/sitemap.xml) to ensure only base product URLs appear, not variant query strings.
How to fix seo variant urls not canonicalized on Wix
- Wix automatically handles canonical tags for standard Wix Stores product pages and does not expose variant URLs as separate indexable pages in the default setup — confirm by inspecting a variant URL's source for a canonical tag.
- If you use Wix's dynamic pages or custom URL structures that expose variant parameters, go to your Wix Editor → Page SEO settings for the product dynamic page.
- Click on the product dynamic page → SEO (Google) panel → Advanced SEO → 'Additional tags' and add: <link rel="canonical" href="{base product URL}"> — use the Wix dynamic value binding to insert the canonical product URL field, not the full variant URL.
- In Wix Studio, use the SEO Settings panel per dynamic page template and set the canonical to the product's main URL binding (not the full request URL).
- Test using Google Search Console's URL Inspection tool after publishing.
How to fix seo variant urls not canonicalized on Squarespace
- Squarespace Commerce product pages with variant selectors do not create separate indexable URLs by default (variants are handled client-side without changing the URL path), so this issue typically does not apply to standard Squarespace stores.
- If you have added custom URL parameters via third-party scripts or integrations that expose variant URLs, go to Pages → the product page → gear icon → SEO tab and ensure 'SEO Title' and canonical settings point to the base product.
- For advanced canonical injection, go to Website → Pages → select the page → gear icon → Advanced → 'Page Header Code Injection' and add: <link rel="canonical" href="https://www.yourstore.com/shop/product-slug">
- Note: Squarespace does not allow full head-level canonical overrides globally via admin; if you need site-wide canonical logic for many products, consider whether a different platform better fits your catalogue scale.
How to fix seo variant urls not canonicalized on Webflow
- In Webflow, CMS-powered product pages with variant query strings (added via custom code or integrations) require you to set the canonical in the Collection page template.
- Open the Webflow Designer → navigate to your Product Collection Template page.
- Click the page settings gear icon (top-left) → SEO Settings → 'Canonical Tag'. Set this to the base product URL using the CMS dynamic field (e.g. bind it to the Product Slug field to produce https://www.yourstore.com/products/[slug]).
- If your canonical field is not available in page SEO settings, go to Project Settings → Custom Code → add a canonical <link> tag in the 'Head Code' section using a Webflow CMS embed with the slug dynamic field on the Collection page.
- Publish the site and verify with View Page Source on a variant URL that the canonical href resolves to the clean product URL.
How to fix seo variant urls not canonicalized on Adobe Commerce (Magento)
- Adobe Commerce (Magento) generates configurable product URLs with parameters like ?color=45&size=12. By default, Magento may not canonicalise these back to the base product — this must be configured.
- In the Admin panel, go to Stores → Configuration → Catalog → Catalog → Search Engine Optimization.
- Set 'Use Canonical Link Meta Tag For Products' to 'Yes'. This tells Magento to output a canonical pointing to the base product URL on all product pages, including those loaded with option/attribute parameters.
- Also set 'Use Canonical Link Meta Tag For Categories' to 'Yes' to cover filtered category pages.
- Save the config, then flush the Magento cache: System → Cache Management → Flush Magento Cache.
- If you are on a PWA Studio or headless Adobe Commerce frontend, ensure your product page component reads the canonical_url field from the GraphQL product query and outputs it as <link rel="canonical" href={product.canonical_url}> in the document head.
- Verify with Google Search Console URL Inspection on a ?color= or ?size= variant URL.
How to fix seo variant urls not canonicalized on Magento Open Source
- Follow the identical steps as Adobe Commerce above — the 'Use Canonical Link Meta Tag For Products' setting exists in Magento Open Source at Stores → Configuration → Catalog → Catalog → Search Engine Optimization.
- Set it to 'Yes', save, and flush the cache via System → Cache Management → Flush Magento Cache.
How to fix seo variant urls not canonicalized on PrestaShop
- In your PrestaShop back office, go to Shop Parameters → Traffic & SEO.
- Scroll to 'SEO & URLs' settings and ensure 'Canonical URL' is set to generate canonical tags for product pages.
- For attribute/combination URLs (e.g. /product?id_product_attribute=12), install or configure an SEO module such as 'SEO Expert' or 'Yoast SEO for PrestaShop' to output a canonical pointing to the base product URL for all combination pages.
- If editing theme files directly, open your product.tpl template and add: <link rel="canonical" href="{$product.url}"> inside the <head> block, ensuring {$product.url} resolves to the clean base product URL, not the combination URL.
- Clear the PrestaShop cache (Advanced Parameters → Performance → Clear cache) and verify with page source inspection.
How to fix seo variant urls not canonicalized on OpenCart
- OpenCart does not add canonical tags to variant/option URLs by default.
- Install an SEO extension from the OpenCart Marketplace such as 'SEO Canonical URL' or a comprehensive SEO module that supports product canonicals.
- Alternatively, edit catalog/view/theme/[your-theme]/template/product/product.twig (OpenCart 3+) and add inside the <head> block: <link rel="canonical" href="{{ canonical }}"> then set the $canonical variable in the product controller (catalog/controller/product/product.php) to the base product URL without option parameters.
- After making changes, go to Admin → Dashboard and use the cache-clearing option, then verify with page source inspection.
Does your site have this issue?
Run a free SEOLZ audit to find seo variant urls not canonicalized — and every other issue — across your whole site in minutes.
Scan my site freeFrequently asked questions
What is Seo variant urls not canonicalized?
When a shopper picks a color, size, or other option on a product page, most ecommerce platforms create a new URL — for example, `/products/my-shirt?color=Red` or `/products/my-shirt?size=L`. These variant URLs contain almost identical content to the main product page. A canonical tag is a small HTML snippet you place in the `<head>` of each variant page that says to Google: "The definitive version of this content lives at [base product URL] — please treat that as the real one." It does not redirect shoppers; it only guides search engines.
Why does seo variant urls not canonicalized matter?
Without canonical tags on variant URLs, Google sees hundreds or thousands of near-duplicate product pages and must guess which one to rank. This splits your "link equity" (the ranking power earned from backlinks and user signals) across all variants instead of concentrating it on your main product page, pushing every version lower in search results. It also wastes your crawl budget — Googlebot spends time re-crawling colour and size variants instead of discovering new products or categories. Stores with large catalogues (hundreds of products × multiple variants) can lose significant organic traffic this way. Fixing canonicalisation is one of the highest-ROI SEO tasks for any product-rich store.
How do I fix seo variant urls not canonicalized?
Add a canonical tag to every product variant URL pointing back to the base product page, so Google consolidates ranking signals onto one authoritative URL instead of splitting them across hundreds of near-duplicate pages.
Authoritative references
- Consolidate duplicate URLs (canonical) — Google Search Central
- SEO Starter Guide — Google Search Central