Hreflangs and canonicals. Should I chose the canonical version of the page for hreflang tags?

by Eugene Krall   Last Updated February 22, 2017 17:04 PM

So, basically we have implemented canonical tag, which points to the url with the parameters stripped. For instance, if somebody visits the page

https://mywebsite.com/en/some-page.php?someparameter=value

The value of the canonical tag on this page would be:

<link href="https://mywebsite.com/en/some-page.php" rel="canonical" />

Now, how should we go about hreflang tag in this case?

Should it point to the canonical language versions of the page like that?

<link href="https://mywebsite.com/ru/some-page.php" rel="alternate" hreflang="ru" />
<link href="https://mywebsite.com/en/some-page.php" rel="alternate" hreflang="en" />

or should it use the exact url accessed by the user?

<link href="https://mywebsite.com/ru/some-page.php?someparameter=value" rel="alternate" hreflang="ru" />
<link href="https://mywebsite.com/en/some-page.php?someparameter=value" rel="alternate" hreflang="en" />

Which is the right scenario? Thank you.



Answers 1


If parameter is not affecting content than you need to specify passive typed parameter in URL Parameters tool and use your first solution:

<link href="https://mywebsite.com/ru/some-page.php" rel="alternate" hreflang="ru" />
<link href="https://mywebsite.com/en/some-page.php" rel="alternate" hreflang="en" />

In that case you don't need to specify canonical:

<link href="https://mywebsite.com/en/some-page.php" rel="canonical" />

Note: Consider of using active parameter type in case it actually affects page content

Александр Киричек
Александр Киричек
March 23, 2017 12:36 PM

Related Questions


Updated August 08, 2016 08:03 AM

Updated December 06, 2018 14:04 PM

Updated March 03, 2019 08:04 AM

Updated March 04, 2016 01:01 AM

Updated June 29, 2015 13:01 PM