1

I'm facing problems of spammy parameters in Google Search Console.

I have a multilingual page (for illustration purposes, let's say that the URL is https://www.example.com/page1.html). The page is translated into multiple languages (https://fr.example.com/page1.html, https://de.example.com/page1.html, etc).

I've added the hreflang tags to each version of the page like this:

<link rel="alternate" href="https://fr.example.com/page1.html" hreflang="fr"/>
<link rel="alternate" href="https://de.example.com/page1.html" hreflang="de"/>
<link rel="alternate" href="https://www.example.com/page1.html" hreflang="x-default"/>

The problem I'm facing is that Google is crawling urls named like this:

https://fr.example.com/page1.html?some_spammy_param=more_spam

and it's complaining that the alternate pages don't link back to it (because obviously, I don't want to include auto generated spammy parameters in my hreflang parameters!).

In a single language site, this would be solved by adding a canonical tag, but Google recommends against using the canonical tag in multilingual sites.

1 Answer 1

1

Google says:

Q: Can I use rel=canonical together with rel-alternate-hreflang?

A: We recommend not using rel=canonical across different language or country versions. Using it within the same language/country version is fine and one of the recommended ways of handling canonicalization.

In other words:

Don't mark one language as canonical as the other. /fr/page.html is NOT the same as /de/page.html there should not be a canonical tag that marks one as canonical as the other. If you mark the fr and de page as canonical, one of those two will NOT appear in search results, even for users that speak that language.

It is fine to use a canonical tag as long as it points to the same language. In fact, we recommend that you do so.

It is completely compatible with hreflang. Hreflang is meant to point between different languages. rel=canonical can only point with the same language.

Each page in each language can have a canonical tag. With both canonical and hreflang it would look like this:

  • https://fr.example.com/page1.html:

    <link rel="canonical" href="https://fr.example.com/page1.html">
    <link rel="alternate" href="https://de.example.com/page1.html" hreflang="de"/>
    <link rel="alternate" href="https://www.example.com/page1.html" hreflang="x-default"/>
    
  • https://fr.example.com/page1.html?some_spammy_param=more_spam:

    <link rel="canonical" href="https://fr.example.com/page1.html">
    <link rel="alternate" href="https://de.example.com/page1.html" hreflang="de"/>
    <link rel="alternate" href="https://www.example.com/page1.html" hreflang="x-default"/>
    
  • https://www.example.com/page1.html:

    <link rel="canonical" href="https://www.example.com/page1.html">
    <link rel="alternate" href="https://fr.example.com/page1.html" hreflang="fr"/>
    <link rel="alternate" href="https://de.example.com/page1.html" hreflang="de"/>
    
  • ...
3
  • Are you sure about this? Their wording is very vague....
    – sudokai
    Jun 8, 2017 at 22:20
  • I support many languages on coinmill.com, de.coinmill.com, es.coinmill.com, etc. I use canonical tags and it works great. I don't use hreflang though. Jun 8, 2017 at 22:53
  • I've also added Google's actual advice to the answer and paraphrased it for clarity. Jun 8, 2017 at 23:34

Your Answer

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

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