Technical SEO

What is hreflang.

In short

An attribute that tells Google a page has versions in other languages or for other countries, and which one to show to a given user. The foundation of multilingual SEO.

What it is for

If a site has Polish, English and German versions, hreflang tells Google they are the same content in different languages and helps it show the right one. A German user searching for your service should land on the German version, not the Polish one.

How to add it

Usually in the head of every version, for example <link rel="alternate" hreflang="pl" href="https://example.pl/uslugi/"> and <link rel="alternate" hreflang="en" href="https://example.pl/en/services/">. You can also specify a country, such as de-AT for Austria. Alternatively hreflang can go in the sitemap or HTTP headers.

x-default

The x-default value points to the page for users who match no specific version, such as a language selector or the main version.

Common mistakes

  • Missing return links: if the Polish page points to the English one, the English page must point back. Otherwise Google may ignore the annotations.
  • No self-reference in the set.
  • Wrong codes, such as "en-UK" instead of "en-GB".
  • Hreflang pointing to URLs that redirect, return errors or have a different canonical.
  • Automatic IP-based redirects that stop Google from seeing all versions.

Sources

Hreflang: questions.

Do I need hreflang with only one language?

No. Hreflang only makes sense when the same content exists in several languages or for several countries.

Does Bing support hreflang?

Bing mainly uses other signals to determine page language, such as the lang attribute and content-language meta tag, but correct hreflang does no harm.

Need help with this?.

Tell me briefly about your site. I will tell you whether this affects you and where to start.

[email protected] +48 739 260 401 Google Business Profile Leave a review Gdańsk, Poland · in person or online, worldwide
Loading calendar…
Open the calendar in a new tab

I reply to every message.