Shopify SEO: Removing ?page=1 from URLs
Moz put out a good guide of things you can do to improve SEO on a Shopify store this week. One we will concentrate on today is about pagination links, we all know them, the run of numbers at the foot of a collection page.
The problem highlighted by the article is that these inadvertently create duplicate page problems for example on the first page the initial URL is something like:-
/collections/amazing-products
Then once you click through to page two, the link back is like this:-
/collections/amazing-products?page=1
However the markup for these two URLs will be identical. So the Moz article recommends:
…having a developer adjust the internal linking structure so that the first paginated result points to the canonical page
So thought I’d offer up some code to help you or your developer solve this.
NOTE: If this is too technical please of course hire a developer to help you
Time for some code
So the first thing to fix this in your theme template is to move away from using Shopify’s default {{ paginate }} Liquid tag. Which saves time but has it’s limitations. Typically switching to some code within a snippet and including the snippet in…