Dans ce post
Qu'est-ce que la localisation WordPress, vraiment ? Le terme semble assez mystérieux. ? Il n'est donc pas étonnant que de nombreux propriétaires de sites Web WordPress aient du mal à comprendre ce qu'est la localisation WordPress, et comment la réaliser efficacement.
- La localisation WordPress consiste-t-elle à rendre votre site multilingue et à le traduire pour les marchés étrangers ?
- S'agit-il d'afficher une version locale de votre site dans la langue du lecteur en fonction de sa provenance ?
- Et, si vous êtes un développeur, s'agit-il de préparer votre thème ou votre plugin à la traduction ?
Nous allons répondre à toutes ces questions dans ce guide de localisation WordPress.
Tout d'abord :
La localisation WordPress
En bref :
La localisation est le processus d'adaptation d'un produit (ou d'un contenu) à un lieu, une langue ou un marché local spécifiques.
Ce processus d'adaptation implique généralement la traduction de l'élément en question dans une langue locale.
La localisation est également souvent appelée “ l10n ” car il y a dix lettres entre les lettres “ l ” et “ n ” dans “ localisation ”.
Localisation vs. Internationalisation
(Lisez si vous êtes développeur) ?
Maintenant, on passe aux choses sérieuses !
Dans le langage courant, localisation et internationalisation sont utilisés indifféremment l'un pour l'autre. Mais c'est une erreur, techniquement. (Bien que vous ne soyez pas poursuivi si vous êtes coupable.)
Internationalisation (ou “ i18n ” – encore une fois, 18 lettres entre le “ i ” et le “ n ” dans “ internationalisation ”) est le processus de construction de votre produit d'une manière qui permet à l'utilisateur de le localiser.
En d'autres termes, pour les développeurs WordPress, l'internationalisation consiste à suivre des conventions spécifiques qui sont en accord avec les directives de traduction de WordPress.
Dans l'ensemble, internationalisation arrive en premier, et peut ensuite être suivi par localisation.
Exemples de localisation
La localisation WordPress va bien au-delà de la simple traduction de contenu. Voici quelques exemples et idées de localisation WordPress :
Traduction du contenu du site Web pour les marchés cibles
C'est la chose la plus élémentaire et la plus intuitive à faire lorsque vous débutez dans la localisation de votre site WordPress.
L'idée est simple : vous prenez tout le contenu textuel de votre site et le traduisez dans une ou plusieurs versions localisées.
En fonction des outils dont vous disposez, ces traductions peuvent être réalisées manuellement ou de manière automatisée à l'aide de Google Translate ou d'outils modernes de traduction basés sur l'IA. (Plus d'informations à ce sujet plus tard dans ce guide.)
Adapter les graphismes aux marchés cibles
Les images et les photos que vous avez sur le site prolongent l'expérience que les visiteurs ont avec votre contenu. Ces éléments graphiques ont d'autant plus d'importance lorsqu'il s'agit de localisation.
En termes simples, vous voulez que vos graphiques soient aussi localisés que tout autre contenu sur votre site.
Laissez-moi vous donner un exemple ; voici une image de présentation que vous pourriez joindre à un article de blog :

Si vous traduisez ensuite le site en espagnol, vous devriez également obtenir une image localisée appropriée pour accompagner la version espagnole ; comme celle-ci :

Adapter le contenu aux goûts et aux habitudes de consommation des marchés cibles
Par exemple, les sites d'actualités sportives en Europe ne s'intéressent pas beaucoup à ce qui se passe dans la NFL. De même, le public américain ne se préoccupe pas autant de ce qu'il appelle football.
Avec une bonne localisation de site Web, vous pouvez filtrer des catégories entières de contenu et ajuster ce que chaque région voit.
Adapter la conception et la mise en page pour afficher correctement le texte traduit
En général, vous n'avez rien à faire avec la mise en page ou la conception de votre site lorsque changer d'une version linguistique à une autre. Mais il y a des exceptions :
C'est là qu'interviennent les scripts RTL (de droite à gauche).
Quand translated to French les langues, être capable d'ajuster la structure du site rendra la lecture beaucoup plus facile pour les publics étrangers.
Conversion en devises et unités de mesure locales
En Europe, nous aimons afficher les valeurs monétaires ainsi : 20$. Aux États-Unis, la norme est $20 – avec le symbole de la devise avant le montant.
Une bonne localisation garantit que ceux-ci restent corrects.
En utilisant les formats locaux appropriés pour les dates, les adresses et les numéros de téléphone
Quel format de date est-ce pour vous ?
03/12/2020
Si vous êtes aux États-Unis, nous sommes le 12 mars. Partout ailleurs, nous serions le 3 décembre.
En tant que propriétaire d'un site Web, sites web dans la finance marché.
Respecter la réglementation locale et les exigences légales
Politiques de confidentialité, règles RGPD, déclarations FTC, plus des dizaines d'autres lois et réglementations locales.
Un site web doit être en conformité avec la réglementation de chaque pays où il a une présence officielle.
Fournir un support client dans la langue locale
Enfin, et ce n'est pas le moindre, nous avons ce qui est probablement la plus grande victoire pour les entreprises opérant à l'échelle internationale.
Offrant support client dans la langue maternelle du client est une victoire énorme, et rien d'autre ne leur prouvera que vous vous souciez vraiment de leur expérience.
Avantages de la localisation
La question que vous pourriez vous poser est pourquoi vous devriez vous donner toute cette peine pour localiser votre site.
Il y a d'excellents avantages à la localisation WordPress :
- Augmenter la part de marché et les revenus. Que vous vendiez des produits ou que vous partagiez simplement du contenu sur divers sujets, l'exposition à davantage de marchés entraînera des revenus plus importants (sinon directement des ventes, du moins de la publicité). En fait, les données disent que chaque $1 investi dans la localisation génère $25 de nouveaux revenus.
- Atténuer la sensibilité culturelle. Certaines expressions ou certains sujets qui sont acceptables dans un pays peuvent être entièrement pas d'accord dans un autre. En proposant du contenu localisé, vous évitez ces problèmes.
- Instaurer la confiance des clients. Rien ne renforce la confiance comme de voir que le site web que vous consultez a fait l'effort supplémentaire de traduire son contenu pour faciliter les choses au lecteur.
- Prenez un avantage concurrentiel. Être plus présent que votre concurrence est toujours une bonne chose.
- Renforcer la présence mondiale. En devenant mondial, vous rendez votre marque beaucoup plus reconnaissable.
Comment faire la localisation WordPress
Maintenant que toute la théorie est derrière nous, mettons-nous au travail et passons aux étapes nécessaires pour localiser votre site WordPress :
Nous allons vous montrer comment gérer la localisation dans quatre domaines spécifiques :
- localiser le contenu textuel ← cliquez pour ignorer
- localisation des fichiers multimédias et des images
- paramètres de référencement localisés
- la mise en place de traductions automatiques
Je vais utiliser notre plugin TranslatePress pour mener à bien cette tâche – la plupart de ces opérations peuvent être effectuées à l'aide du version gratuite du plugin.
Si vous souhaitez obtenir une version résumée de cet article de blog, voici un court tutoriel vidéo qui couvre les points principaux du processus de localisation :
Mais pour jeter un regard plus approfondi sur la localisation WordPress, continuez à lire.
Alors, pour commencer, voici comment installer et configurer le plugin :
Installation et mise en service de TranslatePress
TranslatePress s'installe comme n'importe quel autre plugin WordPress gratuit. Accédez à votre tableau de bord WordPress, puis rendez-vous dans Extensions → Ajouter et entrer TranslatePress dans la barre de recherche. Ensuite, cliquez sur Installer maintenant et puis sur Activer.

Aller à Paramètres → TranslatePress et ajoutez de nouvelles langues à votre site.

Une fois vos langues enregistrées, rendez-vous à la Sélecteur de langue tab in the top navigation of your TranslatePress settings to configure how visitors will switch between languages on your site. By default, TranslatePress adds a floating language switcher to the bottom-right corner of every page — so you don’t have to configure anything if that works for you.
If you’d like to customise its appearance or placement, the Language Switcher tab gives you three options, each with its own sub-tab:
- Flottant — adjust the position, colours, flag shape, and Desktop/Mobile layout of the corner switcher
- Code court — use
to embed the switcher anywhere on your site, including widget areas and Gutenberg blocks - Article de menu — add language options to any navigation menu via Apparence → Menus

N'oubliez pas de cliquer sur Enregistrer les modifications quand c'est fait.
With these simple actions, you’ve just let WordPress know about the languages you want to use on your site multilingue. In the next step, we’re going to localize different areas of your website.
Localizing Text Content
One of the great things about TranslatePress is that you can translate all your content in a very user-friendly way, using a visual translation interface. To begin, just go to the page that you want to translate – can be any page – and click on the Traduire la page link that’s in the top bar:

A good idea is to start with your homepage and then progress through all the other pages that need translations. You can use the visual translation editor, to navigate your website and translate everything you see.
To translate any text that you see on the page, just click on the icône de crayon next to it. A new panel will appear in the sidebar on the left. This is where you can enter your translation.

You can go through each block of text on the page until you eventually translate them all.
The important detail here is that this method works on all types of texts that your theme displays on the page. No matter if the text comes from a blog post, the theme’s own strings, a dynamic string, etc., TranslatePress can handle them all.
N’oubliez pas de cliquer sur Sauvegarder la traduction (top left corner).
Remarque: To speed things up, you can also choose that your translations be done automatically. We’ll cover this in one of the sections below.
Localizing Media Files and Images
Localizing your images works just the same as localizing text content. All you have to do is click on the icône de crayon next to the image you want to localize, and then replace it either by selecting another image from the media library or uploading one from your computer.

It’s important to point out that this functionality extends to all media types. You can localize not only your images, but videos, audio files, and curseurs aussi.
To learn more about localizing website images, read this guide.
Localizing SEO Settings
In principle, multilingual SEO is no different from regular SEO. You simply want to make sure that it’s not only the primary language version of your site that can be discovered via Google, but all the localized versions as well.
Remarque: To translate all the important SEO elements on a page, we’ll be using the Module complémentaire SEO Pack for TranslatePress – available with all premium licenses.
To make sure your content ranks in multiple languages, you want to:
- edit the URL slug (web address) of each localized page,
- translate the page title and meta description,
- activer Plans de site multilingues,
- set the correct
hreflangattributes for your localized pages.
All of this is really straight-forward in TranslatePress.
The latter two TranslatePress will do for you automatically. The first two – editing the URL slug, title and description of the page – is done via the same translation interface we used in the previous step.
To see all the SEO strings that can be translated, expand the menu under your primary language; this one:

The arrows point to the slug of the page, the title and meta description. Click on either of these strings to edit them via the TranslatePress interface.
To learn more about localizing SEO settings, read this guide.
Setting up Automatic Translations
Last but not least, if you prefer to not have to do all translations by hand, TranslatePress also supports automatic translation — and it’s easy to enable.
The simplest option is TranslatePress AI, the plugin’s own built-in translation engine. It requires no external account and no API key. You can get a free TranslatePress AI license by signing up here, and paid plans include AI words to use with the engine as part of the plan. If you need more words, on a paid plan you can top up word credits from your TranslatePress account.
Pour activer la traduction automatique, allez dans Paramètres → TranslatePress and open the Traduction automatique onglet. Activer automatic translation and select your preferred engine.

If you’d prefer to use an external API, TranslatePress also supports:
- Traduction Google — available on all plans including the free version, using your own Google Cloud API key. Here’s how to generate one.
- DeepL — available on Business and Developer plans, using your own DeepL API key. Here’s how to generate a DeepL API.

Whichever engine you choose, automatic translations are a starting point — you can review and refine anything that sounds off directly in the visual editor.
To learn more about translating your WordPress site automatically, read this guide.
Localisation de WordPress pour les thèmes et plugins
This part of our WordPress localization guide is meant for developers working on their own WordPress products, themes, and plugins.
If you’re a user then localizing all the plugins and themes that you have installed on your site is done via the methods described above.
Keep reading if you’re a developer:
When working on a WordPress theme or plugin, your task is not as much to prepare original language versions of the product, but rather make it possible for other people to translate your creation on their own.
More or less, this is what internationalisation is all about.
Luckily, although it might sound intimidating, the actual tasks that you need to perform in order to internationalize your theme or plugin are quite straightforward:
Set the Text Domain Header
This first step is about letting WordPress know that your product is ready for translations.
For themes, this is done by including the following function call in the functions.php file of the theme:
load_theme_textdomain('YOUR_THEME', THEME_PATH.'/languages');
Use “gettext” Functions
There are two PHP functions available in WordPress that make internationalizing your theme / plugin really easy.
They are:
_e()__()
These are what we call “gettext” functions.
You should use them each time you want to display any string of text on the screen.
So, instead of doing this:
<?php echo 'Welcome to Great Theme!'; ?>
You would do this:
<?php _e('Welcome to Great Theme!', 'YOUR_THEME'); ?>
This function looks up the translation file (more on this in a sec), matches the string you’ve provided as the parameter, and then prints its translated version (for the language that’s currently set).
- The difference between the
_e()et__()functions is that the first one prints/echoes its result and the second one returns it. - The other parameter,
'YOUR_THEME', is your theme’s template path.
⚠️ I want to emphasize this again; you should use these “gettext” functions every time you want to display any string of text to the user.
The “gettext” functions are not only about translating website content, but their output can also be intercepted by plugins like TranslatePress in other circumstances. For example, WooCommerce users will be happy to know that changing the standard texts like “Add to cart” ou “Sale” is easy to do exactly because WooCommerce uses “gettext” functions when displaying them.
To see how this works, activate TranslatePress (free version), and click on Traduire la page when viewing any of your product pages. As you hover your mouse cursor over the “Add to cart” button, you’ll see a green pencil icon. This icon indicates that the text can be translated and that it comes from a “gettext” function. (Alternatively, blue pencil icons indicate texts created by the user – as part of a post, page or a product description.)

When you click on the pencil icon, you’ll be able to add not only a new language version of the text, but also change the primary language version – in case you want to go with “Buy now” instead of “Add to cart”.

A simple change like this wouldn’t be possible without “gettext” functions.
Create a Translation File
The last step to making your theme or plugin ready for translations is to create what’s called a POT file. A POT file is basically a table. It links original strings of text with translated versions of them.
POT files can be created and edited using a tool like Poedit, for example. It’s open-source and has versions for all major operating systems.
The idea behind a POT file is that all the strings that your theme or plugin outputs to the user through the “gettext” functions should be listed in the file.
Name your POT file after your theme, save it with the .pot extension and put it in the languages sub-directory in your theme’s / plugin’s main directory.
With that done, your theme is ready for translations!
Should You Worry About Dynamic Text Strings?
Dynamic strings are everything that your theme stores in other places than WordPress’ main content tables (wp_posts ou wp_postmeta) or the POT files.
Depending on how sophisticated your theme is, and the degree of customization it offers, you may be forced to store some of the theme’s text data either in the wp_options table or even in the theme’s own tables.
Again, this is about text strings that you want to make customizable to the user. A typical scenario where strings like this are used is on custom homepages. Many themes offer original blocks of content and custom designs on their homepages. The raw content that’s on those pages is often difficult to store in the database in a standard way.
The problem with dynamic strings is that they are often problematic from the perspective of WordPress localization.
Depending on which localization plugin the user has, they may or may not be able to translate those strings.
TranslatePress, for example, comes with required tools already built in. It allows users to work with their current theme’s dynamic strings like with any other texts they see on the page.
Overall, whenever you can avoid using dynamic strings in your theme or plugin, try doing so.
Learn more about localizing dynamic strings in WordPress.
Localisation WordPress : Conclusion
Navigating your way through WordPress localization may sound like an intimidating task at first, but it’s actually not that hard once you get to work. That is, if you have quality tools at your disposal.
As you’ve seen, TranslatePress can help quite a bit in getting your website localized quickly and your international audiences happy.
Nearly everything that’s been described above can be done with the 100% free version of the plugin.
If you also want to increase your chances of ranking your multilingual content in Google, consider upgrading to one of the TranslatePress pro plans. The SEO add-on that’s part of the offer will handle all your multilingual SEO needs. You’ll also get access to a lot of powerful add-ons, like unlimited translation languages, détection automatique de la langue de l'utilisateur, translator accounts and more.
TranslatePress Multilingue
And, of course, if you have any questions about WordPress localization, don’t hesitate to ask in the comments.
Si vous avez trouvé ce message utile, consultez notre Chaîne YouTube, où nous téléchargeons constamment des tutoriels vidéo courts et faciles à suivre. Vous pouvez également nous suivre sur Facebook et Twitter pour être le premier à savoir chaque fois que nous publions.
Karol, this is a fantastic piece that really drives home the importance of adapting a business’s online presence to their target market, taking into account cultural sensitivities and language. The way you broke it down makes it not only easy to follow but also can definitely help those just starting out in localizing WordPress while keeping SEO in mind. Thank you for sharing!