The glossary

Published:

Last updated:

Hreflang – what it is, how to implement it and common mistakes

Definition

Hreflang is an HTML attribute that tells search engines which language and geographic area a page targets – crucial for showing the right language version to the right user in international SEO.

What is hreflang and why is it needed?

Hreflang is an attribute, added in the HTML head or in an XML sitemap, that tells Google and Bing which language and regional version of a page is meant for which audience. Without a correct hreflang implementation, search engines may show the wrong language version in the wrong market – for example the English version to Swedish users – which lowers conversion rates and weakens your ranking potential in each market.

How hreflang is implemented technically

There are three ways to implement hreflang: in the HTML head with link rel="alternate" tags, in the HTTP header (for non-HTML documents), or in the XML sitemap. The most common method is the HTML head. Every page should point to all language versions – including itself – and the references must match exactly in both directions. If page A points to page B but page B does not point back to page A, Google ignores the relationship.

Common technical mistakes with hreflang:

  • No return links – All referenced pages must link back. Google ignores one-way hreflang tags
  • Wrong language codes – Use ISO 639-1 codes (sv, en, de) and region codes where needed (en-GB, en-US). Home-made abbreviations do not work
  • Missing x-default – x-default specifies the fallback version for users whose language does not match any specific version. Without it, Google may choose the wrong version
  • Inconsistent URL format – Do not mix www and non-www, or http and https, in the hreflang references

Hreflang in Webflow – automated via the Localization add-on

One of Webflow's handy features for multilingual websites is that hreflang tags are generated and maintained automatically when you activate Webflow's Localization add-on. You do not need to write or update the hreflang attributes manually for each page and language version – Webflow handles it in the background and makes sure the references are correct in both directions.

Multilingual websites built in Webflow therefore get correct technical SEO for international search from day one – without the manual work that is otherwise one of the most common sources of error. Webflow supports localisation for more than 70 languages and lets you use a market-specific URL structure with either subdomains or subfolders.

Hreflang and AEO

In an AI-driven search environment, hreflang plays an indirect but important role: a correct hreflang implementation ensures that AI systems such as AI Overviews and Bing Copilot serve the right language version of your content to the right market. If the wrong version is indexed for a market, you may be deprioritised in AI-generated answers there – however good the content itself is.

Ready for the next step?

Now that you know more about hreflang, you may be wondering what your next step should be.

We are always happy to help and to answer any questions you have.

Book an intro call