The `hreflang` attribute system is built on a foundation of trust and reciprocity. For it to work, every page in a set of alternate language versions must link to every other page, including itself. This chain of confirmation signals is broken when one of the links points to a non-200 URL. Whether it’s a redirect (3xx), a broken page (4xx), or a server error (5xx), a non-200 status code makes it impossible for a search engine to verify the reciprocal link, often causing the entire hreflang implementation for that group of pages to be ignored.

Think of your hreflang tags as a group of people in a circle, each pointing to the person on their left. If one person points to an empty chair, the chain is broken, and the relationship between everyone in the circle becomes unclear. For a broader look at international SEO, see our guide on localization.

An illustration showing a broken link in a chain of hreflang tags, disrupting the connection between international pages.

A Status Code Breakdown for Hreflang Implementations

To maintain a healthy international SEO setup, it’s crucial to understand how different status codes affect your hreflang tags. As a best practice highlighted by international SEO experts like Aleyda Solis, only live, indexable URLs should be used.

Status Code Class Impact on Hreflang How to Fix
3xx Redirects These break the reciprocal link validation. While Google might follow the redirect, it adds an unnecessary step and a point of failure. Always update the hreflang `href` attribute to point directly to the final destination URL. Avoid using redirected URLs entirely. Learn more about 3xx status codes.
4xx Client Errors These are dead ends. A link to a 404 page is a broken signal that tells search engines your site is poorly maintained and wastes crawl budget. Remove the link from the hreflang annotations and either 301 redirect the broken URL or let it 404 if it has no replacement. See our guide on 4xx errors.
5xx Server Errors These signal that your server is unreliable. If Google repeatedly finds 5xx errors, it may crawl your site less frequently and lose trust in your hreflang signals. Fix the underlying server issue immediately. This is a critical error beyond just hreflang. Learn more about 5xx errors.

Auditing and Fixing Your Hreflang URLs

The only way to ensure a flawless implementation is through regular auditing. For a comprehensive guide on implementation, check out this resource from Google Search Central.

<!-- Before: Hreflang points to a redirected URL --> <link rel="alternate" hreflang="en-gb" href="https://example.com/uk/" /> <!-- This URL 301 redirects to /en-gb/ --> <!-- After: Hreflang points to the final 200 OK URL --> <link rel="alternate" hreflang="en-gb" href="https://example.com/en-gb/" />

By ensuring every link in your hreflang network is a live, healthy page, you provide clear, trustworthy signals that help Google serve the right content to your global audience. This is also critical for resolving hreflang and canonical tag conflicts.

Frequently Asked Questions

What if a redirect is temporary? Should I use a 302 redirect URL in my hreflang tag?

No. Hreflang tags should always point to the final, canonical URL. If a page is temporarily redirected, you should still use the final destination URL in your hreflang annotations. Relying on search engines to follow redirects for something as precise as hreflang is not a reliable strategy.

Does this rule apply to hreflang tags in an XML sitemap?

Yes, absolutely. Regardless of whether your hreflang tags are implemented in the HTML, in the HTTP header, or in an XML sitemap, every URL must be a live, 200 OK page.

Does this rule also apply to the x-default hreflang tag?

Yes, absolutely. The URL specified for the `x-default` tag, which indicates the default page for users without a specified language, must also be a live, indexable page that returns a 200 OK status code.

Are your hreflang tags leading to dead ends? Use Creeper to audit your hreflang URLs and ensure a smooth path for your international users.