Hreflang and international · Hreflang annotations
Hreflang uses relative URLs
This page's hreflang link elements use relative URLs such as /tests/ instead of full URLs with the domain, which search engines require.
How this page is built
The head of this page has the right three annotations, but each address starts with a slash and has no protocol or domain:
en-GB: this pageen-US: the US English versionx-default: the region picker
The US English version and the region picker use full URLs.
Why it matters
Google’s guidelines say hreflang URLs must be fully qualified, with the protocol and domain. Relative URLs may be resolved wrongly or ignored, and then the set has no return links from this page.
Relative links are common in templates because they work for ordinary links. Hreflang is a special case.
How to check it
View the source and look at the href of each hreflang link element. Each should start with https:// and the domain. Crawl tools report hreflang with relative URLs.
How to fix it
Output absolute URLs in hreflang annotations. In a template, prefix the path with the site’s full address.