Google Introduces x-default hreflang HTML Attribute

Wednesday, April 10, 2013

Google is the largest and most popular search engine website out there and they're always looking for better ways to serve their customers and web developers alike. Today, they've introduced a new way for developers to point the search engine to the right web page depending on the user's location around the world. The new rel-alternate-hreflang annotation is it.


Let's take a look see shall we!


  • example.com/en-gb: For English speakers that live in the UK
  • example.com/en-au: For English speakers that live in Australia
  • example.com/en-us: For English speakers that live in the US
  • example.com/: This homepage would show users a country selector and would be the default page for visitors worldwide
Webmasters would be able to specify  rel-alternate-hreflang annotation by using the following HTML tags:

<href="http://example.com/en-gb" hreflang="en-gb" rel="alternate">
<href="http://example.com/en-us" hreflang="en-us" rel="alternate">
<href="http://example.com/en-au" hreflang="en-au" rel="alternate">
<href="http://example.com/" hreflang="x-default" rel="alternate">


This cluster of tags will tell Google's search engine algorithms which website is for which location around the world.

Google says:
The new x-default hreflang attribute value signals to our algorithms that this page doesn’t target any specific language or locale and is the default page when no other page is better suited. For example, it would be the page our algorithms try to show French-speaking searchers worldwide or English-speaking searchers on google.ca.
This x-default hreflang attribute value would also apply to web pages that alter content dynamically based on their geolocation as well as their Accept-Language defaults. It would specify that such a page does not target a specific language or region.

Image Credit: Google

0 Blogger:

Post a Comment

 
Computer Software is Your Friend © 2012 | Designed by Bubble Shooter, in collaboration with Reseller Hosting , Forum Jual Beli and Business Solutions