When I set up a site in multiple languages, how should I set up my urls for search engines and usability?

Let's say my site is www.example.com, and I'm translating into French and Spanish. What is best for usability and SEO?

Directory option:

http://www.example.com/sample.html
http://www.example.com/fr/sample.html
http://www.example.com/es/sample.html

Subdomain option:

http://www.example.com/sample.html
http://fr.example.com/sample.html
http://es.example.com/sample.html

Filename option:

http://www.example.com/sample.html
http://www.example.com/sample.fr.html
http://www.example.com/sample.es.html

Accept-Language header:

Or should I simply parse the Accept-Language header and generate content server-side to suit that header?

Is there another way to do this? If the different language versions don't have different urls, what do I do about the search engines?


UPDATE 2011-12-06

Google has new recommendations for meta tags for explicitly pointing to other language content: New markup for multilingual content.

link|improve this question

This question has some good related information: webmasters.stackexchange.com/questions/961/… – JasonBirch Jul 19 '10 at 8:11
You should also think about using codes like "en-us", "de-de" when you want to localize and not just translate. – webjunkie Aug 3 '10 at 9:47
feedback

6 Answers

up vote 7 down vote accepted

In my opinion, you should use either the folder or subdomain approach, because they are more intuitive to the user. Which one is a matter of personal taste, I personally find the folder approach clearer. The filename option is far less intuitive.

Parsing the Accept-Language header for directing the user to the correct content on his first visit is a good idea, but you should only do it to redirect on the folder or subdomain url. Otherwise, it would be impossible to link to content in a specific language, and the indexing of your website will be a mess.

link|improve this answer
2  
Also, always give the user the choice, no matter what their headers say -- I often switch back to English when being offered the German version, either because the translation is so awful, or because it's easier to read in English (MSDN, for example -- all the code is in English, so having the text in German means more context switching) – balpha Jul 19 '10 at 14:00
feedback

Answering a question similar to yours on his blog, Matt Cutts suggests:

If you have sites with say French and German versions for a business, my preferences would be:

  1. ccTLDS such as example.fr or example.de
  2. After than, subdomains such as fr.example.com or de.example.com.
  3. If that’s not possible, I’d use subdirectories such as example.com/fr/ or example.com/de/
link|improve this answer
feedback

This is the same question I asked on StackOverflow. And I got a recource for it, ill post the answer.

I have found a nice resource from Google on the choices you can make. There is a section with pros and cons of each method you can use.

I have been struggling with the multi-lingual websites for a while now.

There are definitely some points in the article that are not mentioned in the answers mentioned. That why I felt the need to post this as an answer. I hope this helps someone out.

link|improve this answer
feedback

As a German user I hate it when a website won't let me on the English page because it's think it knows better what I want. It might be hard for Americans to understand but there are actually people who speak more than one language.

Sometimes I might want to view the German websites and sometimes I might want to view the English one.

Simply parsing the Accept-Language header might drive me mad.

That especially true if your German page is a cheap translation of your English page.

To make it easy for your user the English version should also have localisation such as domain.com/en/ or en.domain.com.

When I type domain.com you get one guess to give me the English or the German page based on my Accept Language header. If I however don't like your choice than I should be able to simply exchange the language in the domain name.

Extra hint: If you have the language in front of the domain name both typing ger.domain.com and de.domain.com should bring me to the German website.

link|improve this answer
feedback

Use subdomain option if you use localized versions (i.e. France != French). Use subdomains, but I think it's better use directories if this country uses diferent languages. For example:

us.domain.com (USA)
us.domain.com/en/sample.html (USA - english)
us.domain.com/es/ejemplo.html (USA - spanish)
es.domain.com (Spain)
es.domain.com/es/ejemplo.html (Spain - spanish)
es.domain.com/ca/exemple.html (Spain - catalan)

Bing relies on geo-meta tags, but for Google you have to use google webmaster tools.

If you want to target global markets use www.domain.com with a prefered user language (browser give laguage priorities on Accept-Language header) when you have it or with your key market language when you don't have it.

link|improve this answer
feedback

I would not use sub-domains. In terms of SEO it's less helpful: http://www.hobo-web.co.uk/seo-blog/index.php/blog-subdomain-or-subfolder-which-is-best/

Similar talk here: webmasters.stackexchange.com/questions/1198/subdomain-versus-subdirectory

If you look at big sites, the most often use sub-domains.

It also depends if your business is more of a global or local nature. We are a copyrighting agency, so for use its more local business. Therefore Top Level Domains are better than running everything on .com

Filename is a concept I have not seen yet.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.