Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I have a multilingual site and I think both, canonical URL and alternate hreflang URL should be defined. The URL structure is very simple: Language, tag and page title.

The page has multiple tags. While going through pages under one category, the category name should be maintained in the URL like following:

When some of these pages is also related to the tag "accidents" and many more tags, it means that the page has multiple URLs, which causes duplicate content:

This will be handled by defining a canonical URL. We have decided not to create "sub-tags", so we need to decide which tag is the most important one for this content. So under whatever tag the page is being viewed, canonical URL refers to:

<link rel="canonical" href="http://domain.com/en/FUNNY/man-walks-on-banana" />

Now the question occurs when the site is multilingual. According Google's instructions I should set an alternate link hreflang to the finnish version of the page.

<link rel="alternate" href="http://domain.com/en/funny/man-walks-on-banana" hreflang="en" /> (english versison of the page)
<link rel="alternate" href="http://domain.com/fi/hauskat/mies-kavelee-banaanin-paalta" hreflang="fi" /> (finnish version of the page)

Alternate hreflang-links are defined in both versions, but in both versions there should still be the canonical link, so that the page is under the main tag, in its own language.

If we assume we're on the english version of the page "/en/sometag/man-walks-on-banana", would it go like this:

<link rel="alternate" href="http://domain.com/en/funny/man-walks-on-banana" hreflang="en" />
<link rel="alternate" href="http://domain.com/fi/hauskat/mies-kavelee-banaanin-paalta" hreflang="fi" />

<link rel="canonical" href="http://domain.com/en/funny/man-walks-on-banana" />

Is this a proper way to do this or not? Does the defining of a canonical link effect to the alternate hreflang-links or not? Does Google understand what I'm trying to tell them here? I hope you do. If so, what would be the proper solution?

Thanks.

share|improve this question
    
I would think so, don't see a better way to do this. –  Remy Jul 30 '13 at 7:24
add comment

migrated from stackoverflow.com Jul 30 '13 at 14:10

This question came from our site for professional and enthusiast programmers.

1 Answer

What you are proposing sounds correct to me:

  • Each language should have one canonical page with this content on it.
    • Both of the following URL should have a canonical tag of <link rel="canonical" href="http://domain.com/en/funny/man-walks-on-banana" />
      • http://domain.com/en/funny/man-walks-on-banana
      • http://domain.com/en/accidents/man-walks-on-banana
    • http://domain.com/fi/hauskat/mies-kavelee-banaanin-paalta should have the canonical tag: <link rel="canonical" href="http://domain.com/fi/hauskat/mies-kavelee-banaanin-paalta" />
  • Each page can have alternate hreflang links to the canonical version of the page in other languages.
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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