Hreflang tags are one of the most popular methods for notifying search engines of alternate versions of pages of international SEO efforts.
Hreflang tags are html tags that are added to the <head> of webpages that provide signals to search engines that there are alternate versions of the page.
The alternate versions typically contain translated versions of the webpage in different languages. However, they can sometimes be in the same language but for different countries. For example, if you had a page in Spanish targeting Mexico, you might want a different version for your audience located in Spain. That’s where hreflang tags come in handy!
The anatomy of a hreflang tag is quite simple when it’s broken down. There are essentially three main parts of a hreflang tag.
For a full list of supported language and country codes, you can view Google’s accepted list.
Whenever you implement hreflang tags on your site, you must follow these very important rules.
In this example, you can see that for the United States English version of the page, I’ve included the current (primary) page as well as the French and German alternates.