Guide · Multilingual

How do you write hreflang on a multilingual site? How does AI search treat it?

Updated 2026-11-05 · kagentx

Short answer

For hreflang, do three things: every language version points back to the others, each list includes itself, and add an x-default for visitors whose language matches none; list only versions that really exist. MochiStamp has seven languages, with Arabic and Persian right to left, and its live hreflang is written exactly so: seven languages on the home page, x-default pointing to English. In the last 28 days the Arabic WhatsApp sticker guide had 141 impressions and the English one 138. We have not verified that AI search reads hreflang, but one URL per language with server-rendered body helps AI crawlers all the same.

How do you write hreflang and x-default correctly?

Google's documentation on multilingual sites (checked 2026-11-05) has five rules, and missing one can get the annotations ignored:

RuleHow to write it
Point back to each otherEvery language version must list all versions and link back; one-way annotations are ignored
Include itselfEach version's list also contains itself, and the list is identical on every version of the page
x-defaultFor visitors whose language matches none: point to a language selector or the default-language version; no language code needed
Where to write itA link in the page head, an HTTP header, or xhtml:link in the sitemap: the three are equivalent, pick one, no need for all three
Language codeLanguage in ISO 639-1 (such as ja, ar), optionally a script (zh-Hant) or region (en-GB); a region alone is invalid; write full URLs including https

A real example: MochiStamp's seven languages

MochiStamp is a LINE sticker site with seven language versions, each under its own URL prefix. Arabic and Persian are written right to left.

LanguageURL prefixhreflangWriting direction
Japanese/jaLeft to right
English/en/enLeft to right
Traditional Chinese/zh-hant/zh-HantLeft to right
Simplified Chinese/zh-hans/zh-HansLeft to right
Arabic/ar/arRight to left
Persian/fa/faRight to left
Russian/ru/ruLeft to right

On 2026-11-05 we opened the live pages and checked hreflang. The home page lists all seven languages, with x-default pointing to English; the LINE sticker size guide exists in only four versions (Japanese, English, Traditional and Simplified Chinese), so its list has just those four; the Arabic WhatsApp sticker guide lists English, Arabic, Persian and Russian. In other words, hreflang lists only versions that exist, not pages that do not exist just to fill all seven languages. Each URL entry in sitemap.xml also carries the same xhtml:link entries and x-default.

What should you watch for with Arabic and Persian (right to left)?

Google's hreflang documentation says nothing about writing direction; this part is MochiStamp's practice, not a Google rule:

  1. 1. The page declares language and direction

    The Arabic pages' html tag has lang set to ar and dir set to rtl (checked on the live page 2026-11-05). Persian is the same.

  2. 2. Styles use only logical directions

    Styles use logical directions such as inline-start and inline-end, never hard-coded left and right, so one stylesheet works in both directions (MochiStamp's house rule).

  3. 3. Copy written in that language itself

    Each language's page has its title, description and body written in that language, not a Chinese or English page wrapped in another layer. People search in their own language; the real queries in these two languages are in the next section.

How many impressions do the language versions really get?

These are MochiStamp's most-impressed pages in Search Console over the last 28 days (scoreboard generated 2026-11-05). The whole site had 2,596 impressions and 67 clicks in 28 days.

PageImpressions, last 28 days
/en/guide/size (English)158
/ar/guide/whatsapp-stickers (Arabic)141
/en/guide/whatsapp-stickers (English)138
/ar/phrases/kimochi (Arabic)86
/zh-hant/ideas/new-year (Traditional Chinese)81
/zh-hant/phrases/koibito (Traditional Chinese)71
/fa/phrases/kihon (Persian)53

On the same topic, the WhatsApp sticker guide has 141 impressions in Arabic and 138 in English, about the same; 3 of the 10 most-impressed pages are Arabic or Persian. For how the Arabic page is written, see MochiStamp's Arabic WhatsApp sticker guide; an English example is MochiStamp's LINE sticker size guide.

But impressions are not clicks. Several Arabic and Persian queries sit at positions 5 to 10 with 0 clicks in 28 days: ملصق زعلان had 12 impressions at average position 6.1; استیکر در جواب مرسی had 13 impressions at 8.7. The sample is tiny (a single query has at most a dozen or so impressions), so draw no conclusion; it only shows that multilingual pages do earn impressions in other languages.

Does hreflang help AI search?

We did not check, page by page, whether OpenAI's or Perplexity's crawler documentation mentions hreflang, so we cannot say AI search reads it. hreflang is an annotation from Google's documentation; what is certain is that it helps Google show each language's users the matching version in results. For AI search, these practices do not depend on hreflang and still help:

  1. 1. One URL per language

    Do not switch language with scripts or cookies. Crawlers fetch by URL, and a URL maps correctly only if it has one language.

  2. 2. Body output by the server

    Most AI crawlers do not run JavaScript; see Do AI crawlers render JavaScript. If a multilingual page fills in the translation with scripts, the crawler reads an empty page.

  3. 3. Write title and description per language

    Aim the title and description at questions people really search in that language, rather than translating the English one word for word.

  4. 4. Keep sitemap lastmod trustworthy

    Give each language version a date that follows its own content changes; see how to write a trustworthy sitemap lastmod for how to write it.

  5. 5. Check yourself with the audit checklist

    Whether crawlers can get in and read the body: go through AI visibility audit checklist item by item.

FAQ

Do you have to write x-default for hreflang?

Google's documentation treats x-default as the fallback page when no language matches. It is advisable when the site has a language selector or a clear default language. MochiStamp's x-default points to the English version.

Does hreflang go in the page or in the sitemap?

Google says a link in the page head, an HTTP header and xhtml:link in the sitemap are equivalent; pick one. MochiStamp writes the same content in both the page head and the sitemap.

Some pages exist in only some languages. How should hreflang be written?

List only the versions that really exist. MochiStamp's LINE sticker size guide has just four versions (Japanese, English, Traditional and Simplified Chinese), so its list has only those four.

Do Arabic and Persian pages need special handling?

Google's hreflang documentation says nothing about writing direction. MochiStamp's practice is to declare dir as rtl on the page, use only logical directions like inline-start and inline-end in styles, and write the copy in that language itself.

Will hreflang make ChatGPT or Perplexity cite me?

We have not verified it. We did not check their crawler documentation page by page for hreflang, so we draw no conclusion. The steadier approach is one URL per language with the body rendered by the server.

Sources

kagentx

Do your pages in each language show up in AI answers?
Let the evaluation tell you

The evaluation asks ChatGPT, Perplexity and Claude (with web search on) your buyers' questions and lists who they recommend and which pages they cite, filling in the half that Search Console cannot show. The Basic plan is $1, and results usually take 2–3 minutes.