How to translate a WordPress site for free?

How to translate a WordPress site for free?

Kornel M. Novak

One of the best strategies to increase traffic on your website is to show the content in your user's native or in a commonly accepted language like English. On the internet, the process of translation is called localization and in this post we give you the basics and a widely accepted solution for localization on WordPress sites.

What is localization

Localization (l10n) is the process of translating and adapting a site’s content to a specific location. This process consists of two steps: internationalization and localization.

Internationalization (i18n) is when developers provide the means to translate your site for any language by preparing the interface and the underlying structure. WordPress is ready for Internationalization so you’re good to go.

The second step is the localization process. This is actually the translation and adaptation of the text for other languages and cultures.

Source: https://developer.wordpress.org/apis/handbook/internationalization/localization/

How localization works in WordPress

The easiest way to create localized content in WordPress it’s via their plugin system. Basically, you check the zillions of available translation plugins, choose what fits your needs, install it in WordPress, configure the basic settings and you are good to go.

Our past experience with such translation plugins however shows that choosing the wrong plugin can push your project sideways very fast.

These kinds of problems are more relevant if you don’t plan for SEO and internationalization from the beginning and decide to change the overall structure of the site, while you already have a lot of indexed content in Google.

When clients trust us with the freedom of choosing the right plugins for their sites, we opt for the Polylang translation plugin because in its basic form is very easy to use and gives the user a lot of flexibility to configure the important modules of the WordPress CMS.

How to install the Polylang plugin

The Polylang plugin can be installed from the WP plugin library or you can upload a specific version and activate it from the available plugins library.

To install the plugin from the plugin library follow these steps:

  1. Go to the Add new plugin section on the sidebar
  2. Search for the Polylang plugin in the searchbox
  3. When the plugin appears click on Install now.
  4. After installation is done click on enable the plugin and the setup wizard will get you through the basic installation steps.

The plugin is installed into your WordPress CMS and you can start translating your content.

The last version of the plugin is compatible with the recent versions of WordPress, but if you have to use a specific version you have to go to the advanced section on the WordPress Plugin site and download the compressed plugin files: https://wordpress.org/plugins/polylang/advanced/

Then you can either copy the .zip file via an FTP connection or go to the upload section of your WP installation’s Add new plugin section (the button is on the side of the title).

When the upload is finished you can install the plugin the same way as an external one.

After the installation, the index pages of your WordPress admin dashboard will have additional columns for every language defined in the plugin. Clicking on the pen, you can start translating the contents.

How to configure the Polylang plugin

The first and most important thing with the plugin configuration is to decide which languages you will support and which language will be the default language of the site. The settings page of the plugin (this is on the sidebar, under the Languages menu item, Settings subitem) lets you decide on a couple of configuration values that influence the URL structures and redirections. If SEO is important for you this should be configured with your goals in mind, as the settings can drastically alter how your site appears for Google.

The settings menu’s first item is the configuration for the URL structures. If this becomes too technical, just leave everything as it is. You have the possibility to configure the URL for a subdomain routing based on your languages or go with the folder structure configuration. The plugin can make translations work either way, but for the subdomain routing, you will have to tackle your DNS configurations a bit.

With the second item of the settings, you can delegate the task of language verification for the plugin and redirect the user to the right version based on their preferred browser language.

The third item is related to your Media library. Basically, the plugin can handle media file translations like the title, the alternative text, the caption, and the description, but it doesn’t duplicate the file itself. Take care with this, because if you have, let’s say a German language page, you only can include media files that were translated to this language version, otherwise, they will not appear.

Then you can have a custom translation for taxonomies and post types and synchronization for metadata on particular pages.

The other options are payable and only available with the PRO version of the plugin.

The last item is to include your license key to enable the PRO features.

How to translate your Media

Media translations are available for each item in your media library. Clicking on the flag, the system takes you to the specific translation version page and you can include your title, description, and alt text for the medium.

To facilitate editing, all detail pages will have a Language section so you can easily traverse between languages.

As we mentioned in the previous section, you must have a translation in place for every media library item you want to appear on the right language version page. If the Polylang plugin cannot find a translation for the medium, it simply decides not to show it!

Of course, that behavior can be turned off under settings, but again, if your strategy includes SEO then you will have to have the correct translations under the proper URLs.

How to translate your Pages and Posts

Page and post translations are a bit easier than Media Library items. The complication with these is that the URL structure has to obey the chosen settings item for Polylang and you cannot have duplicates for Pages titles and slugs.

The same Language swapper can be accessed on the editor page.

When you access a page, you will write content for the particular language version of that page.

Polylang currently supports the basic Guttenberg editor and it has integration for the Elementor editor too.

What’s in the pro version?

Finally, let’s check what’s included in the Pro version of the plugin.

Remember I mentioned the problem with duplicates for pages and posts in URLs? With the Pro version, you can share the same slug in the URL.

Other points worth considering:

  • Duplicate posts across languages
  • A customizable language switcher is provided as a widget or in the navigation menu.
  • REST API Support
  • Additional integration with ACF Pro (Advanced Custom Fields plugin)
  • Premium Support

The price for one license currently is 99 EUR. The switch can be valuable if you have a heavy-loaded website or e-commerce shop based on WooCommerce. In that case, you can opt for the Polylang integration with the Woocommerce plugin.

Overall the Polylang plugin is one of the best translation plugins out there with more than 700.000 installations at the moment of this post. It’s easy to use and actively developed so you can find a lot of information about specific use cases.

The Polylang documentation is quite extensive too, you can access it here: https://polylang.pro/doc

Let us know if you need assistance setting up the plugin!

PS.: This is not a paid post. We truly like the plugin and we use it in our projects.