All things Shopify and commerce
Okay, off the bat, according to most SEOs, there is a general recommendation that you should be editing the collection-template.liquid and removing the collection reference from the {{ product.url | within: collection }} where hrefs are being generate.
The idea behind is that Shopify created multiple collection pages for single product and handles this through canonical tags. This can lead to crawl budget waste etc
My question is why has Shopify not fixed this.
Is there a deeper reason or mainly cos of the base code Shopify is built on and they don't want to mess with things. I have a feeling that a platform has big has shopify would have seen this and debated on the best practice.
I want to really implement this but something deep down inside me is saying "maybe there is some other reasons" not doing this will make sense.
Solved! Go to the solution
This is an accepted solution.
Yeh so if you don't care about having a proper breadcrumb trail, just remove the within: collection from the URLs but if you want to keep the breadcrumb trails, either need to use a third party app for breadcrumbs that handles this, build a custom solution or keep as is and hope/fight Google's index.
Yes, there is a reason for these, but it is stupid and poorly handled by Shopify.
These are known as collection-aware URLs. Basically, by having the collection path in the URL, it sets the collection level in the breadcrumbs. Without these, breadcrumbs would just be like Home > Name-Of-Product.
The canonical is set on these however to the single product URL but that doesn't stop Google indexing all of the incorrect (and duplicate) versions for products.
So basically, if you don't care about having the current collection path in breadcrumbs, you can get rid of them with the change you've highlighted.
Great.
Thank you for your feedback.
So basically, if you don't care about breadcrumb which i think is also a great best practice for SEO, one can get rid of it.
This is an accepted solution.
Yeh so if you don't care about having a proper breadcrumb trail, just remove the within: collection from the URLs but if you want to keep the breadcrumb trails, either need to use a third party app for breadcrumbs that handles this, build a custom solution or keep as is and hope/fight Google's index.
Starting a B2B store is a big undertaking that requires careful planning and execution. W...
By JasonH Sep 23, 2024By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024