Using canonical link tag on Zencart
|Just a few days ago I posted an article about canonical link tag and how it helps your zencart stores, in that article I also warned about certain misunderstandings regarding how canonical link tag works and how should it be used. I later took a step further and brought up this question on seomoz.org, a rather well known and trusted source for seo info, below is the quoted question and answer for those who are interested.
Question
Say I have a link like this:
http://mysite.com/index.php?main_page=products_all&sort=2d&page=2
page is used for pagination
sort is used to sort the product listing
So both query params affect product listing:http://mysite.com/index.php?main_page=products_all&page=2&sort=2d
-> same content
http://mysite.com/index.php?main_page=products_all&page=3&sort=2d
-> different content (different list of products)
http://mysite.com/index.php?main_page=products_all&page=2&sort=2a
-> different content (different list of products)
Some people said that my canonical url should be:
http://mysite.com/index.php?main_page=products_all
or even just
http://mysite.com/index.php
But if I understand it correctly, shouldnt the canonical url be:
http://mysite.com/index.php?main_page=products_all&sort=2d&page=2
(I think there is a misunderstanding here, some people believe they should remove all query params from the url to generate the canonical url)
Answer
It’s a good questions, and the answer is a bit tricky. On the one hand, you’re right – simply saying that canonical URLs shouldn’t have query parameters is a gross oversimplification. People think that because query parameters are often a culprit in creating duplicate content, but that doesn’t mean that all query parameters are superfluous.
Technically, I think you’re right – page X of the search results sorted by Y is unique. In terms of the canonical tag, though, Google’s guidelines actually call for using it ONLY on the non-canonical pages. So, for instance, if you had a page that looked something like:
http://mysite.com/index.php?main_page=products_all&sort=2d&page=2&print=1&session_id=12345
…then you might want to canonicalize it back to the version with just the sort type and page number. Otherwise, I’d leave the canonical tag off of it. Practically speaking, the jury is still out on just how much engines are putting the tag to use, so we’re all guessing a little bit.
So what are the conclusions if any? Here are mine:
- Don’t use canonical link tag if you are not sure
- Don’t blindly assume that link with dynamic query parameters removed -> canonical link
[...] you own a Zencart site, you may want to check our Canonical Link for Zencart [...]