skip to Main Content

Do I need hreflang tags?
My site is structured somewhat like this:
mysite.com/en-us/producta
mysite.com/en-gb/producta
mysite.com/en-in/producta

I’ve been working on creating sitemaps with the hreflang tag. However, a provider of automated site map software told me that the hreflang tag is unnecessary because the language-country code (i.e. en-gb) is embedded in the URL and Google will recognize the intent for SEO. Is that true?

What about the hreflang tag’s protection against duplicate content?

edit: Here’s what part of an XML site map would look like:

<url>
    <loc>http://www.example.com/en-us</loc>
    <changefreq>weekly</changefreq>
    <priority>0.5</priority>
    <xhtml:link href="http://www.example.com/en-us" hreflang="x-default" rel="alternate" />
    <xhtml:link href="http://www.example.com/en-in" hreflang="en-in" rel="alternate" />
    <xhtml:link href="http://www.example.com/en-au" hreflang="en-au" rel="alternate" />
</url>

2

Answers


  1. No, it is false. Google does not try to detect language from URLs. In your case, it is recommended to set hreflang.

    hreflang helps Google with indexing. It is not a protection against duplicate content.

    If your content is automatically translated with Google translate (for example), it might be considered spammy.

    Login or Signup to reply.
  2. Hreflang is a signal, not a directive. That means that other SEO factors may override the hreflang tag and cause a different version of your page to rank higher.


    The hreflang tag on each page should include a reference to itself as well as to all the pages that serve as alternates for it. If your Spanish website sells Iberian ham to customers in Spain, France, and Portugal only, the hreflang tags for your homepage might look like this.

    <link rel="alternate" href="example.com" hreflang="es-es" />
    <link rel="alternate" href="example.com/fr/" hreflang="fr-fr" />
    <link rel="alternate" href="example.com/pt/" hreflang="pt-pt" /> 
    

    If your page serves up content in a variety of languages or just asks a user to select a preferred page, you can use x-default to show that the page is not specifically targeted.

    <link rel="alternate" hreflang="x-default" href="http://www.example.com/" />

    **. That looks like this:

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search