hreflang="ar-sa" — Correct Usage
Copy-paste correct usage for Arabic (Saudi Arabia) — HTML, sitemap syntax and the mistakes to avoid.
hreflang="ar-sa" labels a URL as the Arabic (Saudi Arabia) version of a page. Add it as a link tag (or sitemap entry) on every alternate version, always reciprocally and always alongside an x-default entry.
HTML head implementation
<link rel="alternate" hreflang="ar-sa" href="https://example.com/ar-sa/" /> <link rel="alternate" hreflang="x-default" href="https://example.com/" />
XML sitemap implementation
<url> <loc>https://example.com/ar-sa/</loc> <xhtml:link rel="alternate" hreflang="ar-sa" href="https://example.com/ar-sa/" /> <xhtml:link rel="alternate" hreflang="x-default" href="https://example.com/" /> </url>
Rules that trip people up
- Reciprocity: every alternate must link back to every other one, including itself.
- Valid syntax: ISO 639-1 language, optionally “-” + ISO 3166-1 country (or UN M49 region like 419).
- Point only at canonical, indexable, 200-status URLs — never at redirects.
- hreflang suggests, canonical decides: conflicting canonicals silently break clusters.
Frequently asked questions
What does hreflang="ar-sa" mean?
It tells search engines the linked URL is the Arabic (Saudi Arabia) version of the page for that specific region. Users searching in that locale get this URL in results instead of another language version.
Where do I put hreflang="ar-sa"?
In one of three places (pick one, consistently): link tags in the HTML head, HTTP headers, or your XML sitemap. Every language version must list all alternates including itself — missing return links invalidate the cluster.
What are the most common hreflang mistakes?
Non-reciprocal links (A lists B, B forgets A), invalid codes (using country codes alone, or “en-EU”), pointing alternates at redirected/noindexed URLs, and forgetting the self-reference. Audit clusters with a crawler after any URL change.
Keep exploring
Never hand-write hreflang again
Transxlate generates correct clusters for every language version automatically.