top of page
  • Writer's pictureBrent Payne

Has hreflang annotations without HTML lang

The page in question includes hreflang tags yet lacks the specification of the language and region via the HTML lang attribute.


Why is this important?

While hreflang tags assist Google and Yandex in correctly aligning URLs with regional searches, search engines like Bing rely on the HTML lang attribute to perform the same function.


Omitting the HTML lang attribute when using hreflang could lead to misinterpreted language or regional directives by certain search engines, potentially causing the wrong page to appear in localized search results.


What does the Optimization check?

This Optimization will be activated for any page that incorporates hreflang annotations but neglects to include the HTML lang attribute.


Examples that trigger this Optimization:

Take for instance the URL: https://example.com/en/page-a/

This URL would trigger the Optimization if it included hreflang tags:

<link rel="alternate" href="https://example.com/en/page-a/" hreflang="en-us" /><link rel="alternate" href="https://example.com/fr/page-a/" hreflang="fr-fr" /><link rel="alternate" href="https://example.com/de/page-a/" hreflang="de-de" />

but did not include a HTML lang attribute:

<html lang="en">


Why is this Optimization marked 'Opportunity'?

In our audit tool, we categorize this Optimization as an Opportunity since addressing it may help the website attract additional search traffic.


For the language of the pages to be correctly determined by all search engines, ensure that HTML lang is used in conjunction with hreflang, especially if your target market uses search engines that prioritize HTML lang.


Further Reading

5 views

Recent Posts

See All

ClubReq Gets A Link (Because They Asked)

I am a mentor for Techstars and have been for over 10 years. In those ten years I have mentioned to startups to ask ANYONE and everyone that they meet to link to their site. Yet, in all those times on

Kommentare


bottom of page