What is the Hreflang Tag?

The hreflang or rel= “alternate” hreflang= “x” relation attribute is an HTML meta feature that defines the website language and region. You will use the hreflang tag in one of the following places.

. On-page markup
. HTTP header
. The sitemap

This tag is essential to separate a website from its edition of another language or place.

For example, If you have a website in Paris in the two languages spoken in the city, your hreflang will look like this:

<link rel=”alternate” href=”http://albuquerque.com/es/” hreflang=”es-US” />

<link rel=”alternate” href=”http://albuquerque.com” hreflang=”fr” />

If your website offers content in several languages, you can use x-default to display that the page is not directly targeted:

<link rel=”alternate” href=”http://example.com/” hreflang=”x-default” />

Why Is Hreflang So Important?

As many websites reach audiences of different languages and countries, there can be a lot of overlapping content as well as problems with search engine users.

Thus, search engines use hreflang to understand the URL is the right one to view in the search results, based on the user language and area preferences.

In brief, hreflang helps you to:

Prevent the website from being deemed of poor quality by search engines due to redundant content. 

Tell Google the language to view on the basis of the language spoken (written) by the user and its geographical area. This provides a better user interface, which also contributes to user involvement.

When Do You Want To Use Hreflang?

If you’re unsure whether or not you can adopt the hreflang, this could help you make a decision. Three specific situations can be covered by the following:

Multiple nations, different languages (Spanish website written in Spanish, which has a French edition in Belgium, es-ES/fr-BE). 

Different countries, the same language (Website in German, but with different variants for Germany, Austria and Switzerland) de-DE/de-AT/de-CH. 

Same world, different languages (Malaysian website which uses both Bahasa Melayu and English) en-MY/my-MY

When we use the same domain to deliver different languages (multilingual websites), the hreflang tag is built with the language of the target subdomains or directories. Sites with a single domain are typically gTLDs (generic top-level domain names), such as.com,.info, or.org.

On the other hand, if we have a web page with separate domains for each language, the hreflang tag would include domains. This is the case with ccTLD (country code top-level) domain websites. Example.co.uk,.es,.de,.jp.

What If None Of The Languages Available On My Site Fit a User’s Preference?

We cannot deliver all the languages spoken on the world. So, what does Google view when your website does not have a language that suits your browser settings? 

In such instances, it is advised to use hreflang=”xdefault.” This technique would inform browsers and search engines whether there is a global edition of the site or which website language should be presented by default.

hreflang=” xdefault” It can also be used to inform browsers and search engines to show users a page where they can pick the language they want to use.

Three common hreflang mistakes you need to avoid

Missing Return Links:

If you have a page that has a hreflang pointing to an alternative language, but the linked page does not point back to it, you have a “return tag mistake.” According to Google, “Annotations must be checked from the pages to which they point. If page A links to page B, page B must refer back to page A, or the annotations can not be properly interpreted.”

Using the Google Search Console to verify whether you have a “return tag error” that can be found in the International Targeting page. You’ll be able to see when and when the mistake has been found by Google, and where the return link should point.

If you find an error of this sort, edit the Alternative URL page code and add the hreflang tag that connects back to the original default URL. 

Bear in mind that if your hreflang tags connect to non-index sites, it will be identified as an error by Google. The explanation is that Google cannot follow the link back from the blocked page to the original page.

Using Incorrect Country or Language Codes:

One problem that seems straightforward but also creates bugs is the incorrect use of hreflang values. You ought to make confident that the country codes or the language codes you use are right. To do this, use the language code in the ISO 639-1 format, such as “en,” “es,” “jp,” or use a combination of the language code and the country code in the ISO 3166-1 Alpha 2 format. Some examples of these are “es-VE,” “nl-BE” or “pt-BR.” The use of only the country code is not allowed. 

One of the most frequent errors is the use of hreflang=”en-UK” instead of hreflang=”en-GB.” This tag is used by English speakers in the United Kingdom. It’s still a smart idea to double-check before applying the hreflang tags.

Mixing Hreflang Sitemaps and Page Tagging methods:

You don’t need to use hreflang on the XML sitemap and on the pages. It is advised that you stick with one of them. This will eliminate any misunderstanding with Google when considering the hreflang marks. Choose from one of the three potential places to enforce the hreflang: a web markup, an HTTP header or a sitemap.
Seoberries logo
We provide data-driven digital marketing services for a smarter, faster and more cost-effective.
Seoberries
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram