hreflang for Bilingual Sites — The Parts That Actually Matter

A practical guide to `hreflang` for English/Chinese (or any two-language) sites — what to put in `<head>`, what most generators get wrong, and how to verify it works.

If you run a bilingual site, hreflang is the difference between Google ranking your Chinese pages in Chinese results and Google treating your two languages as duplicate content. It is 12 lines of HTML and yet roughly every other bilingual indie site gets it subtly wrong.

Background

hreflang tells search engines “this page exists in language X at URL A, language Y at URL B, etc.” Google uses it for two things: showing the right language version to the right user, and not penalizing you for duplicate content across languages. It does NOT affect ranking directly — but a missing or broken hreflang typically halves the traffic to the non-default language.

How to tell

  • You have English and Chinese versions of the same articles at parallel URLs (/en/articles/x/ and /zh/articles/x/).
  • Google’s Chinese results show your English page (or vice versa) — wrong language for the user.
  • You see “Alternate page with proper canonical tag” in Search Console for one language version.
  • Your bilingual site has way fewer indexed Chinese pages than English pages, even though both are equally complete.

Quick verdict

Add reciprocal <link rel="alternate" hreflang="..."> tags in the <head> of every page. Each tag set must include all language versions AND a self-reference AND x-default. Both pages must reference each other — one-way hreflang is ignored.

Step by step

  1. For every page, generate the full hreflang block in <head>. For an article available in English and Chinese, that is three tags: hreflang="en" pointing at the English URL, hreflang="zh" pointing at the Chinese URL, and hreflang="x-default" pointing at whichever you treat as the default (usually English).
  2. Make the references reciprocal. On the English page, the hreflang="zh" tag points to the Chinese URL. On the Chinese page, the hreflang="en" tag points to the English URL. AND both pages also include their own self-reference. If either side is missing, Google ignores the entire set.
  3. Use absolute URLs (https://yoursite.com/zh/articles/slug/), not relative paths. Make sure protocol (https://) and host match exactly across canonical, sitemap, and hreflang — case-sensitive, no trailing-slash drift.
  4. Each language version gets its own self-referencing canonical. Do NOT canonical zh to en or en to zh. canonical and hreflang work together: canonical says “this URL is the canonical of this content in this language”, hreflang says “here are the other languages”.
  5. Verify after deploy. View source on one English page and confirm 3 hreflang tags. View source on the matching Chinese page and confirm the same 3 tags. Then use Search Console URL Inspection on each — under “International Targeting” (or the equivalent panel) Google should report the hreflang set with no errors.
  6. For top-level country/region targeting, use hreflang="zh-CN" and hreflang="zh-TW" only if you actually serve different content for each — otherwise stick with hreflang="zh" (language only) to avoid maintenance pain.

Common pitfalls

  • One-way hreflang. English page references Chinese, but the Chinese page does not reference back. Google drops the entire set silently.
  • Forgetting the self-referencing tag. Each page must include its own URL with its own hreflang value, or Google considers the set incomplete.
  • Canonical-ing the Chinese version to the English version “to consolidate authority”. This deindexes your Chinese pages from Chinese search. Do not do it.
  • Using lang="en-US" and lang="zh-CN" when you actually serve generic English and Chinese. The country code commits you to country-specific content; if zh-CN is identical to zh-TW, drop both and use zh.
  • Inconsistent URLs between hreflang, canonical, and sitemap. Even a missing trailing slash on one side breaks the match.

Who this is for

Indie content sites running parallel English and Chinese versions (or any two-language combo) under the same domain, with matching article slugs.

When to skip this

Single-language sites — hreflang does nothing for you. Or sites where the two language versions are wildly different in content (different articles, different structure); use separate sites with separate Search Console properties instead.

FAQ

  • Do I need x-default?: Strongly recommended. x-default tells Google “if no language matches the user, show this version”. Without it, Google guesses, and the guess is often wrong for users in third countries.
  • Can I put hreflang in the sitemap instead of <head>?: Yes, both work and you can use one or the other (not both). Sitemap-based hreflang is great for sites with hundreds of pages because it keeps the HTML clean. <head> tags are easier to debug.
  • Why does Search Console still say “Alternate page with proper canonical tag”?: That is normal and expected for the non-default language version. It means Google sees the page and treats it as an alternate of the canonical. It is not an error — it is the correct state.
  • Will hreflang help my Chinese pages rank in Baidu?: No. Baidu does not use hreflang. For Baidu you need Baidu Webmaster Tools and ICP filing, which is a separate effort. hreflang only helps Google and Bing.

Tags: #Indie dev #SEO #Technical SEO #hreflang #Bilingual