Hreflang Tags

30-60 minAdvanced

Hreflang tags are the industry standard for multilingual SEO. They tell Google "This is the Spanish version of the English page." Without them, you risk duplicate content penalties.

Prerequisites

  • WordPress admin access
  • Translations ready
Medium Recommended

Using WPML (Premium)

The standard for large multilingual sites. Handles all hreflang logic automatically.

1

Setup Languages

1

Install WPML Multilingual CMS

2

Go to WPML > Languages > Site Languages

3

Add your secondary languages

2

Connect Translations

1

When creating a translation, click "+" in the Languages sidebar

2

WPML automatically links them and inserts hreflang tags

3

Verify "x-default" is enabled in WPML > Languages > SEO Options

Best Practices

Do

  • Use correct ISO coding (en-US, en-GB, es)
  • Translate the URL slug as well (/about-us/ vs /sobre-nosotros/)
  • Include x-default for users who don't match any specific language
  • Check "International Targeting" in GSC

Don't

  • Use automated translation (Google Translate) flags without hreflang
  • Use IP redirection (automatic redirect) without user choice
  • Point to non-existent (404) translations
  • Mix regions (en-US) with generic languages (en) inconsistently

Verification Checklist

  • Source code contains <link rel="alternate" hreflang="xx" ...>
  • Tags are bidirectional (A links to B, B links to A)
  • Self-referencing hreflang tag is present
  • x-default tag is present
  • No "Return Tag" errors in GSC

Pro Tips

  • If using global CDN (Cloudflare), use Country Redirects cautiously (can block Googlebot from seeing all versions)
  • Separate languages by directory (/en/, /es/) is best for SEO structure

Common Issues & Fixes

Problem: Hreflang no return tag error
Solution: Page A links to Page B, but Page B does not link back to Page A. Ensure translations are connected in the plugin.
Problem: Conflicting Hreflang tags
Solution: The theme and the plugin might both be adding them. Inspect source code for duplicates.