You might have visited a page on the site that had a foreign language on it. And there a window pop out at the top corner of your web browser, so as to change the current language into the language you are familiar with. Did this happen with you?

So how you can tell Search Engines to identify the language that your website content is in? In such a case “Language Tagging” is the best way to achieve it.

For a moment, assume you gave  such a wonderful user experience to visitors on your Web pages. It would make the pages breeze to the wide variety of International Visitors. You won’t be certainly  gaining the traffic, if you don’t tag or redirect your website optimized content in various regional languages.

Hreflang tags and HTML tags are the two main kinds of language tagging.

Both of these language tags have similar purpose of optimization, but there are a few differences  between them.

Just by putting lang tag in an HTML document of the webpage, tells the search engines what language your webpage is in presently. Whereas the hreflang attribute mentions, the language of the webpage that is linked, to your web browser. For example, the lang tag on Hostdens.com tells your browser the language used in hostdens.com, whereas, hreflang language tag attribute explains the language of the webpage i.e. hostdens.com, while a person searches for Hostdens on the internet’s Search Engine!

In a case where a person searching from Italy searches for Hostdens, an hreflang tag is an attribute that is liable for altering the URL in search engines. Nevertheless, when any user visiting Hostdens.com in Italy, the lang tag attribute alters the language over the webpage.

This can be also written as:

Lang attribute tag: <html lang = “en”>

Whereas, this is how hreflang tag attribute is utilized:

< link rel=”alternate” href=”http://example.com/” hreflang=”en” / >

If the website supports webpages in different languages, google encourages to use hreflang tag attribute which helps them in indexing a website.

Now, let’s see how to use herflang tag in your own website and what are its use cases!

Hreflang tags: it is tag responsible for informing search engine about the language that is the webpage using currently which is linked to the Search Engine Page Result. This makes it easy for the search engine to give out language-specific results.

The tag are: rel=”alternate” hreflang=”x”

Hreflang tag enables you to show search engines like Google, etc, the connection between pages of the site that are in various different languages. For example, if your tag wants to connect to an English-language blog, you’d utilize the tag: hreflang=” en”.

This is an example of how a site looks when hreflang tag attribute is used:

<link rel=”alternate” href=”http://hostdens.com” hreflang=”en-us”/>

The meaning of ‘en’ used in the earlier part of hreflang is the language i.e. English, and, us in the latter part describes the name of country as in United States.

Also read,

How to improve the SEO of your WordPress site

Visitors with an IP address belonging to a region gives the knowledge as to which language is being used in that region and automatically get to a optimally tagged page of your website.

Let me demonstrate how hreflang tag works: Consider in an instance where you made two same web pages for the Homepage of your website, however one is in Hindi (hreflang=”hi”) and another one is in English (hreflang=”en”).

Thus when a person searches your Homepage in Hindi or in a browser sporting Hindi language, then that person will get the Hindi version of the Homepage; provided the page is tagged properly.

Each country and language has its own hreflang tag. Given below is a list of some common ones:

  • German/Germany: de-de
  • English/USA: en-us
  • Irish/Ireland: ga-ie
  • Hindi/India: hi-in
  • Italian/Italy: it-it
  • Japanese/Japan: ja-jp
  • Korean/Korea: ko-kp
  • Portuguese/Brazil: pt-br
  • Russian/Russain Federation: ru-ru
  • Chinese (simplified)/China: zh-hans-cn
  • Thai/Thailand: th-th

In a case where you are displaying one page in various locations, then it’s permissible to have more than one hreflang tags on that one page. Consider an example where a website in French thus it can have a business in Canada and Spain too. Similarly, you can easily tag that page respectively in HTML.

If we think about it, your other SEO techniques may override your hreflang tags, but definitely that page would rank for other language. To prevent this from happening, make a note of whether the search engines are armed with the right attributes, thus they (search engines) will know, in what language to display your page.

Finally, the aim of hreflang tags is to provide visitors from other locations, speaking other languages of the world, the content made for them. Thus the search engines will give different versions of the webpage in their respective languages to the global visitors on the SERP.

Quickly, we will now discuss about HTML language tags as you learned quite enough about hreflang tags.

HTML Language Tag:

To define the language of your website page, HTML language attributes are used. For instance, a tag in HTML for a page in English will be written as:

<html lang=”en”>

As Google does not look at it (HTML lang tag), but looks at hreflang tag. It is good to have HTML language tags for other search engines who do not look at hreflang.

With hreflang tags, you should probably utilize HTML language tags in Sync- to notify search engines about Webpages contents, both of these tags can work synchronously. Thus by giving both of these tags on your webpage, it informs the search engines about the language of content and also can redirect global visitors to a relevant page of your Website.

It is crucial to do all that you can to rank on the SERPs, while you’re optimizing your content for web search engines.  This enables International consumers to discover your business.


Vishwajit Kale

Vishwajit Kale blazed onto the digital marketing scene back in 2015 and is the digital marketing strategist of Hostdens, a company that aims to provide reliable web hosting solutions. Vishwajit is experienced in digital and content marketing along with SEO. He's fond of writing technology blogs, traveling and reading.