Hreflang set without an x-default
What it is
The page has two or more hreflang links but none with the value x-default. The x-default entry names the page to show people whose language or country matches none of the versions you list, typically a language selector or your main international version.
Why it matters
Google recommends x-default as the fallback for users whose language settings match none of your versions, and says it works best for language selector pages. It is not required. Without it, the version those users see is likely left to Google, and may not be the one you would pick. The cost is small when your versions cover your whole audience, and larger when you serve a few markets but get visitors from many.
How Asky checks it
Asky reads every <link rel="alternate" hreflang> in the page’s raw HTML and reports the page when there are two or more and none has the value x-default, in any letter case. A page with a single hreflang link is not reported. Each page is checked on its own: Asky does not test that the x-default URL works or that the other versions list the same one. Hreflang in an HTTP Link header or an XML sitemap is not read, and links added by JavaScript are not seen. An x-default listed twice is reported as a duplicate entry instead.
Reported as a warning with medium severity.
How to fix it
- Choose the fallback page: a language or country selector if you have one, otherwise the version meant for the widest audience, often the English one.
- Add one link with
hreflang="x-default"and the fullhttps://URL of that page to the hreflang set in the<head>. - Add the same entry to every page in the group, so each version lists the same set, itself included.
- Before adding code by hand, check your CMS’s localization feature or multilingual plugin for a default or fallback language setting that outputs x-default for you.
- Add it once only: a second x-default link is reported as a duplicate entry.
- To leave it as it is: if your versions already cover everyone you serve and you are content for Google to choose the fallback, mark the issue resolved.
Example
https://example.com/pricing lists English and German versions, then gains an x-default pointing at the English page:
<!-- Before -->
<link rel="alternate" hreflang="en" href="https://example.com/pricing">
<link rel="alternate" hreflang="de" href="https://example.com/de/preise">
<!-- After -->
<link rel="alternate" hreflang="en" href="https://example.com/pricing">
<link rel="alternate" hreflang="de" href="https://example.com/de/preise">
<link rel="alternate" hreflang="x-default" href="https://example.com/pricing">