Find us at BrightonSEO 25/26 April - STAND 18! Fill your swag bag!

Dealing with International issues?

Crawl your website with Sitebulb for 300+ tech SEO checks

Try for Free
Critical This Hint requires immediate attention, as the issue may have a serious impact upon crawling, indexing or ranking. Issue This Hint represents an error or problem that needs to be fixed.

Invalid incoming hreflang annotations

This means that the URL in question has one or more incoming hreflang annotation that is invalid (e.g. invalid language or region code).

Why is this important?

Hreflang annotations include an attribute value that identifies the language, and optionally the region of an alternate URL.

For example, the value "en-gb" identifies English (en) as the language and Great Britain (gb) as the region.

In order to be considered valid, and recognised by search engines, the attribute value must conform to certain guidelines:

  • The language code in your hreflang attribute must be in ISO 639-1 format.
  • The region code in your hreflang attribute must be in ISO 3166-1 Alpha 2 format.
  • Hypens must separate the language and region codes.
  • The region code must not be used on its own (the language code can be).
  • When used together, the language code must always proceed the region code.

If hreflang does not conform to any of the above, it will not be recognised by search engines.

What does the Hint check?

This Hint will trigger for any URL which has at least one incoming hreflang annotation that is invalid.

Note: This Hint is very similar to another Hint: Has invalid outgoing hreflang annotations. The difference being that this Hint is analysing the target page of a hreflang annotation (i.e. incoming hreflang) whereas the other Hint is analysing the page with hreflang on (i.e. outgoing hreflang).

Examples that trigger this Hint:

Consider the URL: https://example.com/en/page-a/

The Hint would trigger for this URL if it had invalid incoming hreflang from another page;

<link rel="alternate" href="https://example.com/en/page-a/" hreflang="en-uk" />

(where "en-uk" is invalid - it should be "en-gb")

How do you resolve this issue?

This Hint is marked 'Critical' as it represents a fundamentally breaking issue, which may have a serious adverse impact upon organic search traffic. It is strongly recommended that Critical issues are dealt with as a matter of high priority.

Invalid hreflang cannot be ignored if you want search engines to serve the correct localised content in different regions.

If you have invalid hreflang, the first task is to understand why it is invalid - which of the 5 guidelines above was broken? Once you understand this, you can roll out a fix on the website, across all affected URLs.

How do you get more data from Sitebulb?

Although this issue triggered a Hint, the best place to check for invalid hreflang in Sitebulb is in the 'Hreflang Geotargeting' tab in the International section.

The column marked 'Valid' will show you which hreglang is invalid, and the other columns will show you other datapoints, such as the number of URLs affected.

Invalid hreflang

In this case there seems to be an error with 2 of the hreflang values, across basically all translated pages. The error, in this case, is:

  • The region code must not be used on its own (the language code can be).

Both cn (China) and cz (Czech Republic) are region codes, and are not valid language codes. China has a range of languages (none of which use the symbol 'cn'), and Czech language is denoted by 'cs'. You can use this list of country and language codes to check.

Further Reading

Sitebulb Desktop

Find, fix and communicate technical issues with easy visuals, in-depth insights, & prioritized recommendations across 300+ SEO issues.

  • Ideal for SEO professionals, consultants & marketing agencies.

Sitebulb Cloud

Get all the capability of Sitebulb Desktop, accessible via your web browser. Crawl at scale without project, crawl credit, or machine limits.

  • Perfect for collaboration, remote teams & extreme scale.