I am trying to resolve an error I am getting from Ahrefs that says: More than one page for same language in hreflang , I attach the file with errors that ahrefs is providing here: hidden link
I am lost at how to fix that, can you maybe take a look please and point me in the right direction? AI is saying that this is the problem:
"Root cause
Your multilingual plugin (WPML or Polylang) has incorrectly linked unrelated tags together as "translations" of each other. When WordPress builds the hreflang block for a tag page, it follows those plugin relationships — so if tag A in language X is linked to both the correct tag B in language Y and an incorrect tag C also in language Y, you end up with two hreflang entries for that language.
This is not a code bug in your hreflang output logic — the plugin is outputting exactly what its tag-translation database says. The database itself is corrupted/misconfigured."
I’m Prosenjit from the WPML Development Team, and I’ll be happy to assist you with this matter.
I completely understand the issue you’re experiencing. Please note that we received similar reports quite some time ago, and the issue was already fixed in the WPML SEO plugin.
Based on the WPML Debug Information you shared, I noticed that the versions of WPML and its add-ons currently active on your site are quite outdated. Most likely, this is the reason why you are still encountering this problem.
Could you please update the WPML plugins to their latest available versions? You can do this by logging into your WordPress Dashboard and navigating to Plugins → Installed Plugins.
Please make sure the following plugins are updated to at least these versions:
- Clear all site/server caches
- Clear your browser cache
- Run the Ahrefs audit again
The issue should be resolved after the updates are applied. However, if the issue persists, please do these steps and run the audit again.
- Please go to WPML > Languages
- Scroll to SEO Options and uncheck " Display alternative languages in the HEAD section."
- Save the changes.
Please give it a try and let me know how it goes. I’ll be more than happy to continue assisting you if you need any further help. Looking forward to your update.
Thsnk you, I updated everything and it did not help.
The only thing yhat helped is turning it off in seo settings, but now hreflangs in head are gone of course. Any way to resolve it without removing hreflangs from head, since its better for seo?
I completely understand the situation. I reviewed several of the links from the Drive document you shared in your first message, and based on my investigation, all the links there point to taxonomies(tags, categories, etc.), and each page generates 21 hreflang entries, which correctly matches the number of active languages on your site. I also did not notice any language being output more than once in the hreflang tags.
At the moment, I can see that the hreflang tags in the `<head>` section are disabled. Could you please enable them again, clear all caches from both the site and browser, rerun the Ahrefs audit, and then share the updated report with me?
At this point, I suspect the issue may be related to Ahrefs crawler confusion or cached historical crawl data rather than an active hreflang generation problem from WPML itself.
Before rerunning the audit, please also try the following:
- Clear all website/server caches
- Clear your browser cache
- Temporarily disable and then re-enable the sitemap feature to regenerate the sitemap
- Submit the site for a fresh Ahrefs crawl/audit
If the same hreflang issue still appears after that, I may need to take a closer look directly on the site to further investigate and better understand the root cause.
For that reason, I’d like to request temporary access to the site for further investigation. I’ve already enabled the private reply box for you, so you can securely share the login details there.
Once I have access, I’ll continue the investigation and let you know the next steps.
Looking forward to your response, and I’ll be happy to continue assisting you.