Hreflang tags and canonical tags - might be causing indexing and duplicate content issues
-
Hi,
Let's say I have a site located at https://www.example.com, and also have subdirectories setup for different languages. For example:
https://www.example.com/es_ES/
https://www.example.com/fr_FR/
https://www.example.com/it_IT/
My Spanish version currently has the following hreflang tags and canonical tag implemented:
My robots.txt file is blocking all of my language subdirectories. For example:
User-agent:*
Disallow: /es_ES/
Disallow: /fr_FR/
Disallow: /it_IT/
This setup doesn't seem right. I don't think I should be blocking the language-specific subdirectories via robots.txt
What are your thoughts?
Does my hreflang tag and canonical tag implementation look correct to you? Should I be doing this differently?
I would greatly appreciate your feedback and/or suggestions.
-
Hi... I'm sorry to tell you that the answer offered by Gaston is not totally correct.
So, in your Spanish page you have these hreflang and canonical annotations:
This is not correct because you are not adding also the self-referential hreflang annotation
Google is very precise about this, and it states its need in the help pages as well in many Googlers tweets and webmaster office hangouts.
The rel="canonical" is correct. Remember that the self-referential and the alternative href URLs must always be canonicals.
Finally, regarding the subfolders blocked via robots.txt, yes! that's totally incorrect:
if you're blocking Googlebot from accessing the Spanish, French and Italian subfolders, then Googlebot won't be able to parse the code of their pages, hence it won't be able to see also the hreflang annotations... with obvious erroneous consequences.
-
that's corect.
-
Yes. example.com/en-US/ redirects 301 to example.com
So, when referencing that version in hreflang will it look like this?
Is this correct?
-
So, every page of example.com/en-US/ redirects 301 to example.com/ ?
If that's the case, then there is no reason in having that folder (/en-US/), just when configuring Hreflang for en-US use the URL without that folder
-
What do you mean by "exactly the same then there should not be 2 sites"?
My https://www.example.com/en-US/ 301 redirects to https://www.example.com
Thoughts?
-
Yeap, those implementations are correct.
in order to avoid duplicate content between different language/countries websites, in each page that is present on each site, there should be their corresponding hreflang tag.
In your case:
And for a sample page: https://www.smarttechMKT.com/es-ES/gastonriera-espanolNOTE, in the case that site.com and site.com/en-us/ are exactly the same then there should not be 2 sites. Just the one without the folder and hreflang tag with en-US should point to that
Hope it helps.
Best luck.
GR -
Thank you for the response, Gaston! I really appreciate it.
So you are certain that my hreflang and canonical tags are implemented correctly? For example, my Spanish version (https://www.example.com/es_ES/
Is this implementation correct?
Also, will I have any duplicate content issues with these different language versions?
-
Hello there,
Watch out your question, there is a site there. If its your clients, edit it.
Canonical and hreflang seems OK.
Blocking other languages/countries is wrong. There you are allowing google to see ONLY the us version.For further reading, take a look at these articles:
Hreflang:
Multi-regional and multilingual sites - Google Search Console
International checklist - Moz Blog
Using the correct hreglang tag - Moz Blog
Guide to international website expansion - Moz Blog
Tool for checking hreflang anotations - Moz Blog Canonicals:
SEO Best Practices for Canonical URLs + the Rel=Canonical Tag - Whiteboard Friday Consolidate duplicate URLs - Google Search Console HelpHope it helps.
Best Luck.
GR.Hope it helps.
Best luck.
GR.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Why are some regions/countries not indexing correctly?
Hi All, Recently I've added different regions (website.com/se/ etc) to Google search console and pointed them to their relevant countries, but only half are working when I search from a regions IP with a VPN and use the correct Google search ( Google.se etc ). Will this correct over time? or is something else causing them not to be indexed up correctly? Thanks in advance <colgroup><col width="81"><col width="104"></colgroup>
International SEO | | WattbikeSEO
| Country | Appear in SERP 17/12/2018 |
| AU | TRUE |
| CZ | TRUE |
| DK | TRUE |
| HK | TRUE |
| IE | TRUE |
| IT | TRUE |
| KR | TRUE |
| NL | TRUE |
| NZ | TRUE |
| SE | TRUE |
| SG | TRUE |
| US | TRUE |
| ZA | TRUE |
| AE | FALSE |
| AT | FALSE |
| CH | FALSE |
| CN | N/A |
| DE | FALSE |
| EE | FALSE |
| ES | FALSE |
| FI | FALSE |
| FR | FALSE |
| GB | FALSE |
| GR | FALSE |
| JP | FALSE |
| NO | FALSE |
| PL | FALSE |
| RU | FALSE |
| SI | FALSE |
| TR | FALSE |0 -
Website relaunched: Both old pages and new pages indexed
Hi all, We have recently made major changes to our website and relaunched it. We have changed URLs of some pages. We have redirected old URLs to new before taking website live. When I check even after one week, still the same old and new pages also indexed at Google. I wonder why still old pages cache is there with Google. Please share your ideas on this. Thanks
International SEO | | vtmoz0 -
Which pages to put hreflang on?
Hi, we are running a site which is a directory consisting of numbers of phone spammers. It contains descriptions, comments and so on. We are currently present in 9 countries. The websites all have the same structure, but, of course, the spam numbers in each country are different ones. If I want to tell Google that our website is available is several locations/languages, do I only put my hreflang tag on the start page then? Thanks
International SEO | | Roverandom
Thomas0 -
Providing a default hreflang for translations
I've been doing a lot of research on hreflang and had a question regarding the implementation with location targeting. I have a translation for Brazilian Portuguese, I'd like to target Brazil with this translation on my site but also provide it as the default for other users that speak Portuguese outside of Brazil. Can I use the same translation for two different sites? So my hreflang would look like this: So in this example the pt-br and pt sites would be duplicates but with one being specifically targeted to Brazil and the other for all other people speaking Portuguese anywhere else in the world. The default language of the site is English so the full implementation would look like this:
International SEO | | Brando160 -
Duplicate content - news archive
Most of them are due to news items having more than 1 category – which is pretty normal.Also /us/blog, /uk/blog and /ca/blog are effectively the same page.None of them are actually duplicate content – just alternate URLs for the same pagehttp://www.fdmgroup.com/category/news/
International SEO | | fdmgroup0 -
Proper use of HREF-LANG tag and Geotargeting.
I am working with a global company that has different country sites (these are distinguished via country subdomains - country.site.com). Upon looking at the Google Analytics data, I noticed that even though the different country geotargeting settings aren't set up correctly, we are reaching the right target market for each site. My hunch is because even though there is no geotargeting, the language for each country site is making the content relavant (this in combination with the subdomain). I have read through various resources here on MOZ, and noticed that the primary purpose of the href-lang tag is important if you have similar/identical pages that are targeted towards different countries/languages. If the pages are translations however, how important or impactful is it to set the geotargeting and href-lang tags for the other sites altogether?
International SEO | | marshseo0 -
"Hreflang=x" tag and multinational websites
Hello, We have multiple websites targeted at multiple countries and languages, each with the correct country extension. We have a corporate blog for each of these websites, where the blogs are subdomains of the main website. Currently we have a process of rewriting our blog posts completely – while keeping the same subjects – in order to have original content on each of our blogs, although we have up to 3 blogs in the same language. These are the languages we target: French – FRANCE French – SWITZERLAND French – BELGIUM Italian – ITALY Italian – SWITZERLAND German – GERMANY German – SWITZERLAND German – AUSTRIA Spanish – SPAIN Spanish – COLOMBIA Spanish – PANAMA Czech – CZECH REPUBLIC Swedish – SWEDEN Dutch – BELGIUM / NETHERLANDS English – UK English – INTERNATIONAL The process is obviously very tedious, and not always applied rigorously – i.e. some of the texts are posted on 2-3 different blogs, creating duplicate content.
International SEO | | ESL_Education
The questions : Would there be any reason for us to privilege the use the rel="canonical" tag over the "hreflang=x" tag, thus giving privilege to a "master" version for each language? Are there any risks in using the "hreflang="x" tag for our blogs considering that the posts would be very similar, except for references to additional content? Could there be any risk that Google would consider our sites as duplicate content after all? Should we specify on each blog that we have all the above versions, or should we only specify the other markets versions in each language? For example, should we specify on our French, Swiss and Belgium blog that we have 3 different French versions, on our UK blog that we also have an international version, and so on, or should we list all versions on each of the blogs? Does the "hreflang="x" tag facilitate the indexation of each of the versions in the SERPs of their targeted market? Lastly, are there any precautions we should take in order to put this in place? Looking forward to your feedback. Best wishes, Maëlle0 -
Fresh content has had a negative affect on SERPs
Hi there, I was ranking pretty well for highly competitive keywords without actually doing any link building please see graph attached, so I thought I have an opportunity here in getting to page 1 for these keywords, the plan was to write fresh & original content for these pages, because hey Google loves fresh content, right? Well it seems NOT, after one week of these pages been re-written (21st Feb 2012), all of these pages dropped all together, please note: all the pages were under the same directory: /health/flu/keyword-1 /health/flu/keyword-2 and so on... I have compared both pages as I have back ups of the old content On Average there are more words on each of the new pages compared to previous pages Lower bounce rate by at least 30% (Via Adwords) More time on site by at least 2 minutes (Via Adwords) More page visits (Via Adwords) Lower keyword density, on average 4% (new pages) compared to 9% (old content) across all pages So since the end of February, these pages are still not ranked for these keywords, the funny thing is, these keyword are on page 1 of Bing. Another NOTE: We launched an irish version of the website, using the exact same content, I have done all the checks via webmaster tools making sure it's pointing to Ireland, I have also got hreflang tags on both website (just in case) If anyone can help with this that would be very much appreciated. Thanks usD8G.gif
International SEO | | Paul780