A website manager sought help with canonical tag implementation for paginated collection pages. The issue: paginated URLs (e.g., page=2, page=3) were self-canonicalizing instead of pointing to the main collection URL without parameters.
Solution Provided:
Modify the theme.liquid file by replacing the canonical link code:
This strips query parameters from all canonical URLs, resolving pagination issues across collections and blogs.
Complications Identified:
The solution successfully fixed pagination canonicalization
However, it inadvertently affected vendor collection pages, causing them to lose proper canonicalization (vendor query parameters were stripped)
Refined Solution:
A conditional approach was suggested to apply the fix only to collection template pages, preserving correct canonicalization for other page types while solving the original pagination issue.
Status: The original poster confirmed the initial solution worked, though the vendor page complication suggests further refinement may be needed for some implementations.
Summarized with AI on October 31.
AI used: claude-sonnet-4-5-20250929.
I have tried some solutions but have not found an effective way to solve this issue. I sincerely hope to receive support from you in the Shopify community to help me overcome this problem.