Fix the within:collection Liquid filter
The most widespread canonical issue on Shopify stems from a single Liquid filter: {{ product.url | within: collection }}. This filter outputs the collection-aware URL instead of the clean product URL, so every product card in your collection grid links to the non-canonical version. When Google follows those links, it crawls thousands of duplicate URLs and sometimes decides they are more authoritative than your declared canonical.
To fix it, open your Shopify theme code editor (Online Store > Themes > Edit code) and locate your product grid snippet. Depending on your theme this might be called product-card-grid.liquid, product-grid-item.liquid, or card-product.liquid in the Dawn theme. Search for within: collection and replace every instance with plain {{ product.url }}. Save, clear your cache, and re-crawl to confirm the internal links now point to canonical URLs.
This single change eliminates the source of the problem for most stores. After making it, Google will re-crawl the collection pages, discover the corrected links, and begin consolidating authority to the canonical product URLs. Allow 2–4 weeks for Search Console to reflect the improvement. For a broader technical SEO framework, see our guide on running a full Shopify SEO audit.


























