2026年11月12日
2026年11月12日
How to Set Up WPML: Install, Wizard, Translation, Language Switcher
This article is a localized edition of the Japanese original. Read the Japanese original
WPML (WordPress Multilingual) is a paid plugin that lets you manage posts, pages, custom post types, menus, and theme and plugin strings in multiple languages. It is not in the WordPress.org plugin directory; you download it from the account you purchase on wpml.org. The screen names, plans and functions in this article were checked against the official wpml.org documentation and purchase page as of November 2026. WPML's screens change from time to time, so if what you see differs, check the official documentation.
Compare the plans first
As of November 2026, the purchase page shows the following. Every plan includes one year of updates and support from the date of purchase.
| Plan | Price | Sites | String Translation | Translation Management | WooCommerce multilingual |
|---|---|---|---|---|---|
| Multilingual Blog | €39 | 1 production, 3 development | No | No | No |
| Multilingual CMS | €99 | 3 production, 9 development | Yes | Yes | Yes |
| Multilingual Agency | €199 | Unlimited | Yes | Yes | Yes |
- If you want to translate theme or plugin strings (header and footer text, widget titles, and so on) or make a WooCommerce store multilingual, you need Multilingual CMS or higher.
- With Multilingual Blog, you translate by creating a page for each language from the "+" icon in the posts list (covered below).
- When your update period ends, your site keeps working, but you no longer receive WPML updates.
If you want to go multilingual without paying, the free Polylang plugin is another option. The steps are covered in "How to set up Polylang".
Install WPML and register the site key
With WPML, you first install a small plugin called OTGS Installer, then use it to install WPML itself and its add-ons.
- Log in to your wpml.org account and download the OTGS Installer ZIP file from "Downloads".
- In the WordPress admin, open the add-plugin screen under "Plugins", click "Upload Plugin", choose the ZIP, then click "Install Now" and "Activate".
- A "WPML → Activate & Update" menu appears in the admin. Open it and register your site key. You generate a site key for each site in your wpml.org account.
- From the same screen, install and activate WPML itself and the add-ons you need (String Translation, WooCommerce Multilingual & Multicurrency, and so on).
You can add more add-ons from the same screen later. To start, installing WPML itself plus the add-ons you actually plan to use is enough.
Choose languages and the URL format in the setup wizard
When you activate WPML, the setup wizard starts. According to the official documentation, you configure things in this order.
- Choose the source language
- Add the languages to translate into
- Choose the URL format for translated pages
- Choose a translation engine
- Choose how to translate
Source language and translation languages
The source language is the language your content is currently written in. For a Japanese site, choose "Japanese". Changing it later takes extra work, so get it right here. You can add or remove translation languages (English, for example) later under "WPML → Settings → Languages".
URL format
Choose one of these three formats for the URLs of translated pages.
| Format | Example URL | Best for |
|---|---|---|
| Directories | example.com/en/sample-page/ |
Most sites. The official documentation also calls it the most common choice |
| A different domain per language | example.com and example.co.uk, etc. |
Sites that already have a domain per country. You need DNS and SSL set up for each domain |
| Parameter | example.com/sample-page/?lang=en |
The official documentation calls it the least recommended format |
Translation engine and translation mode
As of November 2026, the official documentation recommends WPML's own AI translation (PTC) as the translation engine, and labels DeepL, Google and Microsoft as legacy options not recommended for new sites.
Choose one of these two translation modes. You can switch later.
- Translate Everything Automatically: WPML translates the whole site automatically and keeps translating new and edited posts. A cost estimate screen appears, and nothing is translated or billed until you click "Start Your Site's Translation".
- Translate Some: You choose what to translate. You send posts to translation one by one from "WPML → Translations".
Each plan includes a set amount of AI translation (as of November 2026, the purchase page lists 22,500 words for Multilingual CMS, 45,000 words for Agency, and none for Blog). Try a few pages with "Translate Some" first, check the quality and cost, and then expand to the whole site to avoid unexpected charges.
Translate posts
Translate by hand from the “+” icon
The posts list gets a column for each language: a "+" icon for languages with no translation yet, and a pencil icon for languages already translated. The same icons appear in the "Language" box in the right sidebar of the Block editor.
- In the row of the post you want to translate, click the "+" for the target language.
- A page for the translation opens. Write from scratch, or use "Copy content from (source language)" to copy the original and then rewrite it.
- Click "Publish" and the translated page becomes reachable from the language switcher.
- To edit it later, open it from the pencil icon in the same places.
Send content to translation in bulk (Multilingual CMS or higher)
On plans with Translation Management, you select posts in "WPML → Translations" and decide whether to send them to automatic translation, to yourself, or to a translator you have registered. Use this when several translators share the work or when you want to see translation progress in one list.
Translate theme and plugin strings
Strings other than posts (button text in your theme, text you entered in a plugin's settings screen, and so on) are translated with the String Translation add-on, which is included in Multilingual CMS and higher.
- Open "WPML → Translations → Strings".
- Find the string with the search box or the domain filter (which theme or plugin the string comes from).
- Click the "+" for the target language and enter the translation.
If the string you want is not in the list, open Admin Texts Translation from the "Not seeing strings you are looking for?" link in the "Utilities" section of the same screen, scan the theme or plugin, and add the strings.
Register your own theme’s strings with WPML
To make values entered in the admin (text saved in the Customizer or in options, for example) translatable, register the string with the wpml_register_single_string action and pass it through the wpml_translate_single_string filter when you display it. Both work only when the String Translation add-on is active. Without the add-on, the filter returns the original value unchanged, so nothing breaks on the page.
<?php
// functions.php
// Register the text saved in an option with WPML when the admin is opened
add_action( 'admin_init', function () {
$hero_title = get_option( 'mytheme_hero_title', '' );
if ( '' !== $hero_title ) {
// Arguments: context (group name), name, original string
do_action( 'wpml_register_single_string', 'mytheme', 'hero_title', $hero_title );
}
} );
// In templates, output the translation for the current language (the original string if there is none)
function mytheme_hero_title() {
$hero_title = get_option( 'mytheme_hero_title', '' );
return apply_filters( 'wpml_translate_single_string', $hero_title, 'mytheme', 'hero_title' );
}
In a template, use it like echo esc_html( mytheme_hero_title() );. For fixed text written directly in your code, wrap it in a translation function such as __( '文言', 'mytheme' ) instead of using this method; then it can be handled both by WPML String Translation and by translation files.
Show a language switcher
Configure it in the admin
In "WPML → Settings → Language Switchers" you can choose where the language switcher appears (in a menu, a widget, or the footer), whether to show flags, whether to use a dropdown or a list, and whether to show language names in their own language. In the Block editor you can also use the "Language Switcher" block.
Build your own language switcher in PHP
If you want full control over the design, get the list of languages with the wpml_active_languages filter. This filter must be called after the wp action (inside a template, for example).
<?php
// functions.php
function mytheme_language_switcher() {
$languages = apply_filters(
'wpml_active_languages',
null,
array(
'skip_missing' => 0, // Languages without a translation link to that language's home page
'orderby' => 'code',
)
);
if ( empty( $languages ) ) {
return; // For example, when WPML is inactive
}
echo '<ul class="lang-switcher">';
foreach ( $languages as $lang ) {
if ( $lang['active'] ) {
echo '<li class="active"><span>' . esc_html( $lang['native_name'] ) . '</span></li>';
} else {
printf(
'<li><a href="%s" hreflang="%s">%s</a></li>',
esc_url( $lang['url'] ),
esc_attr( $lang['language_code'] ),
esc_html( $lang['native_name'] )
);
}
}
echo '</ul>';
}
Call it with <?php mytheme_language_switcher(); ?> in header.php or a similar template. For link targets, use the returned url rather than building URLs from the language code yourself (the language code used in URLs can differ depending on your settings). This filter, which the official documentation describes, is a safer choice than icl_get_languages(), which you often see in older tutorials.
What to check after setup
- Open a URL in a translation language (for example
/en/) and confirm that the home page, posts, pages and menus display. - If you use a caching plugin or a CDN, confirm that each language is cached as a separate page (that the English page is not served from the Japanese cache).
- If parts of a translation do not display correctly, see "How to fix WPML translations not showing and errors" for how to investigate.
- For how to tell search engines about each language version, see "Designing a multilingual WordPress site for international SEO and hreflang".
Questions about WordPress? The publisher of this site is based in Japan and replies in Japanese. Contact (Japanese)