# Hreflang on Shopify explained simply

> What hreflang tags do, what Shopify generates for you, when no tag appears, and how to check yours. Based on Google’s and Shopify’s documentation.

Published 2026-11-04, updated 2026-11-04. Source: https://forgefont.com/blog/shopify-hreflang

Hreflang tags tell search engines which language or country each version of a page is for, so a French shopper finds your French URL. On Shopify, you rarely write them yourself: the tags are generated automatically once a market or language has its own domain, subdomain or subfolder.

## What does an hreflang tag look like?

It is a line in the `<head>` of a page that points to one version of that page. A store in English and French carries a set like this on both versions:

- `<link rel="alternate" hreflang="en" href="https://example.com/products/mug">`
- `<link rel="alternate" hreflang="fr" href="https://example.com/fr/products/mug">`
- `<link rel="alternate" hreflang="x-default" href="https://example.com/products/mug">`

The value `x-default` is the fallback for people whose language matches none of your versions. On Shopify, it points to the URL of your backup-region market.

## What does Shopify do for you?

According to [Shopify’s international SEO guide](https://help.shopify.com/en/manual/markets/seo):

- Tags are generated from your market and language settings, and they are on by default.
- They update when you add, remove or change a market’s domain and language.
- Your sitemap includes market-specific URLs with hreflang annotations.
- Canonical URLs are set too: each version points to itself, and hreflang links the versions together.

You can turn the automatic tags off, but Shopify warns that this can hurt your SEO, and you would then have to [add your own to the theme](https://help.shopify.com/en/manual/international/managing-international-domains).

## When will you not get hreflang tags?

Shopify generates them only for markets that have a distinct domain, subdomain or subfolder. If several markets share one URL, there is nothing for a tag to point to. Shopify’s [redirection documentation](https://help.shopify.com/en/manual/international/automatic-redirection) also notes that content adapted on a shared domain is not indexed by search engines, while content on a dedicated domain is.

So the choice that matters is your URL structure. Shopify recommends subfolders for most stores. Note one rule: language-only subfolders such as `/fr` can exist only on your primary market. Secondary markets combine language and country, as in `/fr-ca`.

## Which codes are valid?

[Google’s hreflang documentation](https://developers.google.com/search/docs/specialty/international/localized-versions) requires an ISO 639-1 language code, optionally followed by an ISO 3166-1 Alpha-2 region code. Shopify picks these for you, but they are worth knowing if you audit your pages or write tags yourself.

| Value | Valid? | Why |
| --- | --- | --- |
| `de` | Yes | German, for any country |
| `fr-CA` | Yes | French, for Canada |
| `en-GB` | Yes | English, for the United Kingdom |
| `CA` | No | A country alone is not accepted; a language must come first |
| `en-UK` | No effect | Google says `UK` has no effect; use `GB` |
| `en-EU` | No effect | Google says `EU` has no effect |

## Three rules behind most hreflang errors

- **Every version lists itself and all the others.** A page that forgets itself is incomplete.
- **Links go both ways.** Google says that if two pages do not both point to each other, the tags are ignored.
- **URLs are complete.** They must include `https://`.

Shopify takes care of these while its automatic tags are on. If you have also added a hand-written tag to your theme, or a tool that writes its own, check that the two do not conflict.

## How do you check your tags?

1. Open a translated product page in your browser and view the page source.
2. Search for `hreflang`. You should see one line per version, including the page itself.
3. Open each URL listed and confirm that it loads in the right language.
4. Repeat from another version to confirm the links go both ways.
5. Check that your sitemap has been submitted in Google Search Console. Our [Shopify SEO guide](https://forgefont.com/blog/shopify-seo-guide) explains how this fits in.

## What hreflang will not fix

Tags point to pages that must already exist. A language with only half its content translated stays half translated, so finish the job with our guide to [translating a Shopify store](https://forgefont.com/blog/translate-a-shopify-store). [Google also advises](https://developers.google.com/search/docs/specialty/international/managing-multi-regional-sites) against automatically redirecting people from one language version to another: give them visible links to switch instead. For the wider setup, read [how to sell internationally on Shopify](https://forgefont.com/blog/sell-internationally-on-shopify).

Forgefont builds your store in the language you choose, and you can add extra languages from $17, paid once. Hreflang then depends on the markets and languages you set up in Shopify. [Configure your store](https://forgefont.com/configurer) to choose your languages.

## Frequently asked questions

### Do I need an app for hreflang on Shopify?

Usually not. Shopify generates the tags from your market and language settings, and updates them when those settings change. Keep the automatic tags on unless you have another implementation.

### Does Google use hreflang to detect a page’s language?

No. Google says it uses neither hreflang nor the HTML lang attribute to detect a page’s language. Each page should simply be written in one language, content and navigation included.

### Is it better to use tags, HTTP headers or a sitemap?

Google treats the three methods as equivalent, and using more than one adds no benefit in Search. On Shopify, the tags and sitemap annotations are generated for you.
