Creating a multi‐language website

Summary

It’s good to know that having a multi‐language website involves a bit of effort, but there are also great perks that pay off. For example, you can increase your search traffic up to 47% by making your website available in more than one language. Not bad, right?

If your website can be a good source of information for users that don’t know the main language, it’s a loss not to make it accessible for them too. If you invest a lot of time and energy to write valuable content, then you should also try to make it available as it can be. In the end, you want to share.

You should know that changing the website language from the dashboard area is not enough. Your website’s structure is formed of different parts of posts, pages, menus or widgets. The content of those sections can be added directly to your language. However, there are strings attached, both from the theme and plugins, that you need to translate. Let’s take the following scenario: you have a blog website, and at the end of each article you can have a Read more part. Those specific words should be translated into your native language in order to facilitate access.

The .PO file includes the original texts and the translations in two columns. The .MO file incorporates the exact same contents as PO file. Keep in mind that the two files differ in their format. While a PO file is easy for humans to read, MO files are compiled and very easy for computers to read. Nonetheless, WordPress gets translations from the .MO files.

Here are the steps you have to take in order to translate your website:

Find the WP Locale for the language you want to translate your website into.

Rename both PO and MO files this way: themename-locale.po and themename-locale.mo. For example, if the theme is called Julia and you want to translate it in French, your files will be called julia-fr_FR.po and julia-fr_FR.mo;

Upload the translation files, through FTP:

The theme translation files need to be added to wp‐content/languages/themes folder;

The plugins translation files need be added to wp‐content/languages/plugins folder.

The plugins for creating the PO/MO files. You can find some more details here.

Anything that doesn’t fall inside posts, pages or taxonomy goes into String Translation. This includes the site’s tagline, general texts in Admin screens, widget titles and many other texts. You can find some further info about this right here.