As a store owner, when you are selling products in multiple countries (or regions), it becomes quite important to offer a multilingual website that allows online shoppers to change the default store language to their native language. The good news is that nopCommerce does support multi-language option that enables store owner (or administrators) to add / install multiple languages on the store site.
Along with multi-language feature, nopCommerce also offer a feature that allows store owner to have specific URL for each language with the language code in it. You might be familiar with URLs like:
– www.domain.com/en (English – Default)
– www.domain.come/fr (French)
– www.domain.com/br (Brazil)
– www.domain.com/mx (Mexico)
Today, we will go over the process of adding language code in the site URL in nopCommerce.
Question: Why do you need a language (or region) based URL?
Answer: This is a great feature for search engine optimization where your site urls can appear in the search results depending on the location. Another benefit is that you can share different urls for same site depending on the region (or country / language). This eliminates one step for customer to go on your site, see the default language and then change the language manually. Language based URL, gives your customers direct access to the site in their native language.
Let’s go over the process…
Go to: Administration > Configuration > Languages
Now, you can either:
– Add a new language
– Add the language code for the existing language in URL (Let’s go with this option in this article)
Click on the “exit” option for the existing language like this:
On the “Edit Language Details” page, make sure that you have the language code (if not enter a unique code for the language) like this:
The unique two letter SEO code. It’s used to generate URLs like ‘http://www.yourStore.com/en/’ when you have more than one published language. ‘SEO friendly URLs with multiple languages’ option should also be enabled.
After this, go to: Administration > Configuration > Settings > General and Miscellaneous Settings
Choose: Tab “Localization Settings” and enable this option-
When enabled, your URLs will be http://www.yourStore.com/en/ or http://www.yourStore.com/fr/ (SEO friendly)SEO friendly URLs with multiple.
Note: Make sure to restart your application once you make these changes.
Here is the result: