WebmasterID logoWebmasterID
Geo traffic

hreflang and country targeting

hreflang tells search engines which language and regional version of a page to show, based on the user's language and region preferences — it is not a geolocation mechanism. This page explains what hreflang does, how it differs from edge country, and the common mistakes operators make.

Verified against primary sources

What hreflang does

hreflang annotations tell search engines that several URLs are language or regional variants of the same content. Google uses them to help serve the most appropriate version for a user's language and region preferences. The optional region in an hreflang value (for example en-GB) refines targeting, but the annotation describes page variants, not a visitor's location.

It is a hint to search engines, applied when results are assembled — not something that measures or detects where a person is.

Common mistakes

Operators often treat hreflang as if it geolocated users or controlled who can reach a page. It does neither. Mismatched or non-reciprocal hreflang annotations, missing return links between variants, and using region codes without a language are frequent errors.

Keep hreflang (a search-targeting signal) separate from edge country (a coarse audience estimate). They answer different questions and should not be wired together.

How it appears in analytics and logs

hreflang influences which localized URL a search engine surfaces for a query, based on language and region. It is a search-targeting signal, not a measurement of where a visitor is, and it does not geolocate anyone.

Diagnostic use case

Use hreflang to signal language and regional page variants to search engines, while keeping it distinct from edge-derived country geolocation.

What WebmasterID can help detect

WebmasterID keeps audience country (a coarse edge estimate) distinct from hreflang (a search-targeting annotation), so you do not confuse a search-config signal with where your audience is.

Common mistakes

Privacy and accuracy notes

hreflang involves no visitor location data — it annotates page variants for search engines. Edge country, by contrast, stays a coarse, privacy-safe estimate. The two should not be conflated.

Related pages

Sources and verification notes

Last reviewed 2026-06-24. Facts are checked against primary/official sources where available; uncertain specifics are marked “Data not yet verified” rather than guessed.