If your hreflang uses an underscore instead of dash, you can update the attribute to solve this issue.
Otherwise, the hreflang attribute is invalid. Here’s how to do it.
Google’s specifications for hreflang say the use of underscores (i.e. _) should not be used to separate the language and country. Instead a dash should be used (i.e. -)
For example, we would want to use “en-us” as opposed to “en_us”.
A simple change of your hreflang code can change an underscore to a dash. This can be done if you have access to your site’s CMS and direct edit access.
You can also put in a dev ticket.
While a manual approach can get the job done, the project may land at the end of the dev team’s queue. Luckily, you can update your hreflang tags at scale with ClarityAutomate, an SEO execution platform.
This allows you to update your hreflang with a few clicks and solve the issue in a matter of minutes. Plus, you can get the job done without involving the dev team.
Here’s how to do it in a few steps.
Notice how “en_us” has been updated to “en-us” after just a few steps with ClarityAutomate.