I have been working on SEO for multi-store Magento but am facing the error of duplicate content, especially for product pages.
Case 1:
The client wants to keep the Category Url on the product page, but this is indeed giving us duplicate content issues.
Looking at the backend settings for SEO, we have the following key player settings for SEO:

Use Categories Path for Product URLs = Yes
Use Canonical Link Meta Tag For Categories = Yes
Use Canonical Link Meta Tag For Products = Yes

Case 2:
We are using multiple websites in the sub-directory as per country. For example:

http://mystore.com/uk/ -> for UK
http://mystore.com/us/ -> for US
http://mystore.com/fr/ -> for FR

And all the websites have the same catalog of products. So we will have the same product content on all the websites. For example:


Note that we are using the following rel="alternate" meta tags for the above product page:

<link href="http://mystore.com/us/men/shirt/polo-red.html" hreflang="en-us" rel="alternate"/>
<link href="http://mystore.com/uk/men/shirt/polo-red.html" hreflang="en" rel="alternate"/>
<link href="http://mystore.com/fr/men/shirt/polo-red.html" hreflang="en" rel="alternate"/>

What is the best SEO optimization technique to solve the issue of duplicate content issue for product pages for the above cases?

Any help/suggestion is appreciated.

  • 1
    Canonical is not reliable, there are 4 scenarios: 1) Subdirectors as you are using - visitor friendly Google unfriendly; 2) Subdomains - Google friendly visitor unfriendly; 3) multi top-level-domains (tlds) - one per country - Google & visitor friendly; 4) single-tld (.com) multi-country single language - Google & visitor friendly. Your scenario is 4), Magento cannot do that, we have access to technology that does but it is very specialist. You can minimise the effects of 1) but it will never be consistant or reliable, so you might be better off with 3) multiple tlds.
    – user2935
    Commented Mar 29, 2014 at 21:55
  • I am also facing the alternate page with proper canonical tag problem on my magento website. I tried to fixing by the above suggestion but failed on my product filtration urls. Commented Jun 4 at 11:37

3 Answers 3


I would usually canonical back to the /product URL, but leave all the other URLs available for use throughout the category/search customer journey. You could probably put something custom in, like the following if it's not giving you what you want:

if (Mage::registry('current_product')) {
    $_product = Mage::registry('current_product');
    $_url = $_product->getUrlKey();

    echo '<link rel="canonical" href="/' . Mage::app()->getStore($storeId)->getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK) . '/' . $_url . '" />';

I'd probably have a canonical for each language, and combine this with the hreflang as you are doing. I'm not entirely sure if your hreflang tags are correct though - take a look at http://www.branded3.com/blogs/implementing-hreflang-tag/ & http://www.branded3.com/blogs/overcome-common-errors-implementing-hreflang-tag/ - I think you should be using x-default and probably looking for something like en-gb for your UK version, and en-fr for your French version.

  • I am not sure if we still can use hreflang="en-gb" for UK store & hreflang="en-fr" for FR store even though store has only english content? Also if we use 'Use Categories Path for Product URLs' = No, then there is no need to tweak like you mentioned as Magento does this by default.
    – MagePsycho
    Commented Mar 29, 2014 at 18:37
  • I'm pretty sure that your French and UK hreflangs are telling Google the exact same thing, but at two different URLs, which can't be good. Commented Mar 29, 2014 at 19:00
  • So you mean we can still use hreflang="en-fr" for FR store & hreflang="en-gb" for UK store even we don't have the locale contents?
    – MagePsycho
    Commented Mar 30, 2014 at 5:35
  • I think you'd be best off reading the articles, but yes, I believe so. With en-fr you're targeting English speakers IN france. Take a look over support.google.com/webmasters/answer/189077?hl=en also. Commented Mar 30, 2014 at 9:45
  • Yeah thinking to use hreflang="en-gb" & hreflang="en-fr" for UK & FR stores respectively. Now what about including category path in product URLs, how to use canonical urls effectively in this case?
    – MagePsycho
    Commented Mar 30, 2014 at 19:58

Always no questioned asked if you have internal duplicate content problems the fix is change the robots meta tag so on the duplicate urls this reads "noindex" rather than the standard "index". There are a number of plugins that cover this depending on where you're duplicate content occurs within the site - Creare SEO (for a free option) and the internal magento settings work most of the time. If you have product only urls (without the cats) you'll need to tick something within creare. From my experience your biggest issues are your filtered navigation no your category pages.


The issue sometimes appears when the URL's aren't properly indexed in the Magento system. So please check them and make sure that your following settings are actually implemented on frontend by viewing the page source code.

Use Canonical Link Meta Tag For Categories = Yes
Use Canonical Link Meta Tag For Products = Yes

If it is missing or showing the wrong URL you must first set the canonical URL for your every store to mention your base URL for the store and the proper URL for the other pages.

Following two extensions can help you with this

https://www.ulmod.com/magento-2-canonical-url-extension.html (Recommended) https://amasty.com/seo-toolkit-for-magento-2.html

Good Luck!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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