SEO

What Is Hreflang, and Does Your Site Actually Need It?

A tag that only matters once your site has more than one language or country version β€” here's how to know, and how to set it up.

What it is

Hreflang is a small piece of code you can add to a page that says, in effect, "this is the English version of this page, and here's where to find the Spanish version, the French version," and so on. It's added as a set of tags in a page's code β€” one for every language or country version of that same page that exists.

It's specifically for sites that publish the same content in more than one language or for more than one country (like a US version and a UK version of the same product page). A site that only exists in one language doesn't need it at all.

Why it matters

Without hreflang, a search engine has to guess which version of a page to show a given searcher, and it can guess wrong β€” showing a French speaker the English version, or treating two language versions of the same page as confusing duplicates of each other instead of intentional alternatives. Hreflang removes the guesswork by stating the relationship directly.

If your site only has one language version of every page, this isn't a gap in your site at all β€” it's simply not applicable, and there's nothing to fix.

How to fix it

  1. First confirm whether this even applies to you: if every page on your site exists in only one language, you can stop here β€” there's nothing to add.
  2. If you do have multiple language or country versions of the same page, add one <link rel="alternate" hreflang="..."> tag per version inside the <head> of every version of that page β€” including one pointing back to itself.
  3. Use a standard language code for each (like en, es, or a more specific one like en-GB for British English), and optionally add one tag with hreflang="x-default" pointing to the version you want shown when none of the specific languages match.
  4. If you're using a website builder or CMS with built-in multilingual support (many have this), check its settings for an "international SEO" or "hreflang" option rather than editing code by hand β€” it's often generated for you automatically.
  5. Re-run your Launch Readiness check to confirm the tags are detected and use valid language codes.

Check whether your own site has this problem

Launch Readiness scans your site for this and ~50 other pre-launch issues in seconds β€” free, no signup.

Run a free check