---
title: "hreflang"
url: https://marketingsignals.com/glossary/hreflang
type: Page
---

# hreflang

hreflang explained: the three ways to add it, the language and region codes Google accepts, how x-default works and mistakes that make Google ignore it.

SEO glossary

## hreflang

hreflang is an attribute, used with rel="alternate", that tells search engines which language and regional versions of a page exist so each searcher can be shown the right one. For example, it can point UK searchers to an en-GB page and US searchers to an en-US page with the same content.

## How do you implement hreflang?

Google supports three methods and treats them as equivalent: link elements in the page's head, HTTP Link headers for files such as PDFs, and entries in an XML sitemap. Each value is an ISO 639-1 language code, optionally followed by an ISO 3166-1 alpha-2 region code, such as en, en-GB or de-AT. A region code can't be used on its own.

The x-default value, which Google introduced on 10 April 2013, marks a fallback page, such as a country selector, for users whose language matches none of the listed versions.

## Common hreflang mistakes

- Missing return links: if two pages don't both point to each other, Google ignores the annotations
- Leaving out the self-reference: each version must list itself as well as every other version
- Writing en-UK: UK has no effect in hreflang, so pages for the UK need en-GB
- Using a region code alone, such as GB, without a language code

## What hreflang does not do

Google says it doesn't use hreflang or the HTML lang attribute to detect the language of a page; it works that out itself. hreflang helps Google choose which version to show to whom. It doesn't make a weak translation rank, and each page still needs to be written in the language and for the market it claims.

## Example

A UK retailer that also sells to Ireland and the US has three English homepages with different prices and delivery terms. Each lists all three with the values en-GB, en-IE and en-US, plus an x-default pointing to the international homepage, so a searcher in Dublin sees euro prices rather than sterling.

## Related terms

- [Technical SEO](https://marketingsignals.com/glossary/technical-seo)
- [Canonical tag](https://marketingsignals.com/glossary/canonical-tag)
- [Crawl budget](https://marketingsignals.com/glossary/crawl-budget)

## Further reading

- [A Visibility Playbook for E-commerce](https://marketingsignals.com/playbooks/the-e-commerce-visibility-playbook)

Our [Organic Search](https://marketingsignals.com/service/organic-search) service puts this into practice for brands in the UK and US.

## Sources

- [Tell Google about localized versions of your page, Google Search Central](https://developers.google.com/search/docs/specialty/international/localized-versions)
- [Introducing x-default hreflang for international landing pages, Google Search Central (10 April 2013)](https://developers.google.com/search/blog/2013/04/x-default-hreflang-for-international-pages)

## Ready To Grow Non-Branded Organic Revenue?
