Forum Moderators: Robert Charlton & goodroi

Message Too Old, No Replies

hreflang - for regions

Are region codes accepted by Google in the hreflang attribute

         

sanjuu

5:52 pm on Mar 17, 2025 (gmt 0)

10+ Year Member



Does anyone know of a site that is using en-150, and it's working?

For example:
<link rel="alternate" href="https://example.com/eu" hreflang="en-150" />

Google doesn't provide any documentation to state that this would work, although it would make life much easier if it did.

Searching on Google brings back very few results, including this one from 2016:
[stackoverflow.com...]

It's valid on w3.org, but that doesn't mean it's valid for Google in hreflang (which is their thing).

sanjuu

5:57 pm on Mar 17, 2025 (gmt 0)

10+ Year Member



Google does state this:

Incorrect region codes: Make sure you're using officially assigned code elements for the regions you're trying to identify (in ISO 3166-1 Alpha 2 format). If you use codes that are listed as reserved for something else, Google Search ignores that part of the annotation (for example, using EU, UN, or UK in hreflang annotations doesn't have an effect on Google Search).


on: [developers.google.com...]

So that would suggest en-150 is NOT valid for hreflang?

not2easy

6:56 pm on Mar 17, 2025 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



At the same link you've posted (the link to Google's developer pages) they add some more details about using
 rel="alternate" hreflang="x" 
that remind us of some things that may seem unrelated:
Make sure that your server supports UTF-8 character encoding.
Markup guidelines
    Put the markup on the homepage of your site. It is not necessary for the markup to be repeated on other pages of your site.
    We recommend JSON-LD. Alternatively, you can use microdata.
    Specify only one URL search pattern for the target. We are experimenting with multiple pattern support, so if you have feedback or use cases for multiple target support, let us know in our Webmaster Central Help Forum.
. Webmaster Central Help Forum: [support.google.com...]

They want separate country codes when your content has small regional variations with similar content in a single language. For example, you might have English-language content targeted to the US, GB, and Ireland.