I have 3 URLS that serve the same data:

  • www.example.com/product/foo
  • www.example.com/product/foo?id=1
  • www.example.com?product=foo

For Google's sake I want the URL www.example.com/product/foo to be the canonical one.

However, I have my code setup so all 3 of those pages are served from the same code so if I add in <link rel='canonical' href='http://www.example.com/product/foo' /> to my code it will be applied to all 3 pages, including the one http://www.example.com/product/foo.

Is there any issue with doing this or does having a circular canonical not cause any issues?

link|improve this question

feedback

1 Answer

up vote 24 down vote accepted

There's no circularity implied by having <link rel='canonical' href='http://www.example.com/product/foo' /> appear on http://www.example.com/product/foo.

That's the intent. You're saying "the best URL" for this page is http://www.example.com/product/foo, so when the search engines hit http://www.example.com/product/foo?id=1, or http://www.example.com?product=foo, it will get that code and say "Aha! This is really that canonical page, I'll make that one official." On the page itself, it just means "Yes, this is a page, and this is the best URL for this page."

link|improve this answer
Thanks, I was a bit concerned as to what would happen. – RandomBen Jul 14 '10 at 15:50
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.