how-to-translate-woocommerce-into-your-native-language

6 minutes

How to translate WooCommerce into your native language?

WooCommerce – an eCommerce platform giant (33.14% market share), has quite a few official language translations available at the get-go. Nevertheless, there will be times when you will have to create new translations from scratch or just translate some miscellaneous strings. When an online marketplace expands, it is only natural to add more languages to increase website conversion rates. So it is imperative to understand the intricacies behind translation files. In this article, we will take a look at various methods of how it is possible to translate and add languages to WooCommerce.

Why do some WooCommerce strings not translate?

When the WooCommerce functionality is first enabled in WordPress, then the plugin selects the default site language. By default, WooCommerce detects the site language and then installs the necessary language files.  You can find the translation configurations in your WordPress dashboard under Settings > General.

WooCommerce settings

Locate the Site Language tab and set up any language you want.

WordPress site language

If you will change the language after having set up WooCommerce, then there are sure to be some strings left untranslated. It is due to the fact, that WooCommerce cannot recognize a translatable string because some of them are database entries. In all likelihood, they are located in some WooCommerce > Settings fields. It commonly happens with Shipping parameters and Payment strings. To remedy this, you will just need to change the strings to the corresponding language and update the settings.

Even if you have done everything according to the book, there is always the possibility that the language you are targeting has not been fully translated. A common occurrence for a substantial amount of languages. Let us see how we can translate any language manually.

Creating custom WooCommerce language translations

WooCommerce currently supports 67 languages and their variations and is used in more than 100 countries. Even you can join in on the translation effort(register at WordPress.org and start translating on GlotPress). Anyhow, we will examine 4 typical methods of how you translate WooCommerce and see how to efficiently create translation files for multiple languages.

Downloading a WooCommerce language translation manually

First off you have to check whether the language file is available on translate.wordpress.org.

Translate WooCommerce language

Then, in the first column, locate the language you are searching for and click on it.

language column

Look for the Stable (latest release) under Set/Sub Project and click on it.

stable release WooCommerce

Now scroll down to the bottom of the page and look for the Export option. It has to be a .mo file!

export .mo WooCommerce language file

After you have successfully acquired the translation file, you need to rename the file itself as woocommerce-LANGUAGE.mo where LANGUAGE  is the corresponding language abbreviation. For instance, the Finnish language is fi, Italian is it, and so on.

Just upload the file to your website under wp-content/languages/woocommerce/ and then you will be able to use it to translate WooCommerce.

Loco Translate

Loco Translate is one of the most powerful translation tools on the market. A handy tool, when you have to quickly translate a few sentences. Additionally, it is a free plugin with a considerable amount of features for you to work with.

You can download Loco Translate from your WordPress dashboard under Plugins > Add New.

add new plugin WordPress

Locate the Loco Translate file, then install and activate it.

Loco Translate plugin

As you can see, Loco Translate has added a new menu item to your dashboard.

Translate WooCommerce strings

Now, go to the Plugins tab and find WooCommerce, click on it to open the language files.

WooCommerce new language add

If it is a clean installation, then, most likely, the list of files will be empty. Nevertheless, you will have to add new languages manually so WooCommerce can extract the strings needed for translation. Look for the New Language hyperlink and click on it.

new language

You will be redirected to a new window. Start with choosing the language that you want to add in the Choose a Language tab. Then Choose a Location where the files will be kept. You have 3 options – Author, Custom, and System. We highly suggest using the Custom option as it prevents the language translations to be undone by updates to WooCommerce and its extensions. Click on the Start Translating button to create a new language file.

Adding new translation language for WooCommerce

As you can see, every WooCommerce string can be located in the Source Text column. Click on the string that you want to translate or locate it via the search console and add the translation in the corresponding window. When you are done, then click the Save button, to confirm changes.

Source text translation

Keep in mind that whenever a new version of WooCommerce is released and updated on your website, you will have to refresh the .po file to look for new strings to be translated. Just press the Sync button to discover new strings. Do not forget to save the changes!

PoEdit

In essence, PoEdit is an alternative for Loco Translate, but one with advanced functionality. We strongly suggest using this tool only if you are familiar with database file management. Even though the Pro version offers a multitude of upgrades and supplementary functionality, the free version is still enough to get the job done.

WooCommerce includes a .pot file that can be used in PoEdit. You can find the file in your plugin folder in woocommerce/i18n/languages/. Download it, so it could be used in PoEdit.

woocommerce.pot

Open PoEdit and you will be presented with several options. You need to pick the Browse Files option and choose the woocommerce.pot file.

Poedit

Similarly to Loco Translate, you will be presented with the source text. PoEdit requires you to save the new file before you can proceed with translations. Click the Save button.

save language file

Now you are able to edit translations however you deem necessary. Note that it is a good practice to save your file multiple times during the translation process to minimize the possibility of a faulty file.

Poedit translate Woocommerce language

You might have noticed, that the file that the PoEdit saves is a .po file. You will need to convert it to a .pot file and substitute it with the original WooCommerce one that you located in the WooCommerce plugins folder. WooCommerce will update the translations automatically on your website.

SayWhat

A very convenient plugin for situations where you only have to translate a small number of strings. If only one or two strings have not been translated, then this will be the right tool for you. Keep in mind that this plugin requires the ability to read WooCommerce source code to extract the necessary string information.

You can download SayWhat from your WordPress dashboard under Plugins > Add New.

add new plugin

Install and activate it.

Say What plugin

You can find the SayWhat settings in your dashboard under Tools > Text Changes.

text changes

Click the Add New button to start translating.

start translating language

As you can see, there are 4 fields that need to be filled. The tricky ones are Text Domain and Text Context. Thankfully, the documentation of the plugin has a handy guide on how to extract the necessary info.

WooCommerce language translation strings

The plugin will take care of the rest un substitute the corresponding core and plugin files.

Final Words

Translating WooCommerce into another language is not as difficult as it seems at the first glance. But there are cases when some strings have not been translated. Thankfully, there are third-party tools custom-tailored for this specific task. It is up to you to decide which one of these tools is better suited for the job. We wish you a bug-free journey through the world of eCommerce and stay tuned for more articles!

 






0/5


(0 Reviews)

Alexey Seryapin

Alexey is a WordPress wizard with 10+ years of experience as a lead developer, He has launched 500+ WordPress websites and 100+ WooCommerce shops.

KEEP YOUR ONLINE SHOP SAFE WooCommerce Maintenance Service

Save 17% with our Annual pricing plan.

Has your website been hacked?

WordPress Malware Removal Service

We will fix any WordPress hack and make your website hackproof.

Related Posts

how-to-pick-a-strong-domain

How to Pick a Strong Domain Name That’d Give Your New Business a Powerful Identity

woocommerce-to-facebook-shop

WooCommerce to Facebook Shop

how-to-refund-in-woocommerce

How to Refund in WooCommerce

5-reasons-why-you-need-security-testing-for-your-software

5 Reasons why you need Security Testing for your Software