Multilingual WordPress Search (How To Easily Search in Any Language)

Multilingual WordPress Search tutorial

The ability to offer multilingual WordPress search is critical to any website that has been translated into multiple languages. Users that browse your content in a certain language, need a simple way to find relevant topics in that exact language.

That’s when multilingual search comes into play.

In this tutorial, we’ll go through how to enable multilingual search for your translated website or multilingual E-commerce store. All without writing a single line of code or messing with the default WordPress search functionality.

The process is really straightforward and all that’s needed to translate your site in multiple languages as well as enable multilingual search is TranslatePress, a powerful WordPress translation plugin.

TranslatePress Multilingual

TranslatePress is the easiest way to translate your WordPress site. It's fast, won't slow down your website, works with ANY theme or plugin and it's SEO friendly.

Get the plugin

Or download FREE version

Ready to learn how to set it up? Let’s dive in.

Multilingual Search in WordPress

Depending on the translation tool you’re using, the ability to support multilingual WordPress search can be quite challenging.
That’s because in dealing with different types of content: posts, products, pages, custom post types or custom fields, displaying the relevant search results (in the selected language) is tricky.

Due to the way it’s built, TranslatePress doesn’t care how your content was created. It could be a page built with a page builder like Elementor or a WooCommerce product, you’ll be able to translate it visually, directly from the front-end.

And once installed, TranslatePress will automatically make the default WordPress search multilingual.

Let’s see how this works.

Making WordPress Search Multilingual with TranslatePress

TranslatePress makes sure all your translated content is searchable by enhancing the default WordPress search functionality.

Installing TranslatePress and choosing translation languages

To get started, simply install and activate the free TranslatePress plugin from WordPress.org.

Once you’ve activated the plugin, go to SettingsTranslatePress to choose the language(s) that you want to use.

First, choose the Default Language, which is the language that your website content currently exists in. Then, add the new translation languages that you want to offer. We’ll add “Spanish” for this tutorial.

Add New Language in TranslatePress Settings

With the free version of TranslatePress, you can translate your content into one new language, while the premium version of TranslatePress lets you use unlimited languages.

Under TranslatePress Settings you can also configure a few other important things like adding and customizing a front-end language switcher. By default, the plugin will add a floating language switcher button in the bottom-right corner of your site which follows you as you navigate the site.

Click “Save Changes” and you’re ready to start translating.

Translate Your Website Content

All that’s left now is to start translating your website content. For this simply click the “Translate Site” tab, or navigate to the front-end of your website and click the “Translate Page” icon from the WordPress toolbar.

Translate Page button in admin bar

This will open up a visual translation editor (similar to the Customizer), where you see a live preview of your website content on the right and a translation sidebar on the left.

To translate a certain text, simply hover over it, click the pencil icon and enter its translation. Hit Save and you’re done.

Translate text visually using TranslatePress

The translation is updated instantly. You simply repeat the same process for all the remaining strings on a page, until all your site content is translated. As simple as that!

Besides just text, TranslatePress lets you translate a wide variety of elements: from images with text, sliders to forms and popups. You can use the same visual translation approach for all of them.

For a more step-by-step approach check out this guide on How to Create a Multilingual WordPress Site.

To speed things up, you can start by enabling Automatic Translation under TranslatePress settings, using either Google Translate or DeepL. Once enabled, each page of your site will be automatically translated the first time it’s visited.

TranslatePress' automatic translation settings.

It’s important to know that the automatic translation of any content using TranslatePress is done just one time, which helps keep your costs down and reduces page load time.

The plugin then stores the automatic translations in your database and loads them when needed. No other API calls to the automatic translation services.

After all your website content has been automatically translated, it’s highly recommended that you manually refine the translations that sound off or are out of context.

To find out more about setting up automatic translations, check out How to Automatically Translate Your WordPress Site (fast and with minimal costs).

Add a WordPress Search Form to your Multilingual Website

Now that you have your site fully translated all that’s left is to see the multilingual WordPress search in action.

For this, we’ll start by adding a standard WordPress search form to it. The simplest way to add a search form to your site is by using the Search widget that WordPress offers.

You can add this to any sidebar defined by your theme.

Multilingual WordPress search form widget

We’ll go ahead and add a search form to our blog, to make it really easy for people to find articles on topics they’re interested in.

Here’s what it looks like:

Adding a WordPress search form

Now, let’s browse the blog in Spanish and try searching for a Spanish keyword to see the results. We’ll search for “marca” which is the corresponding Spanish translation for the English “brand”.

Multilingual WordPress Search results using TranslatePress

As you noticed only Spanish content is displayed, that either contains the “marca” keyword in the title or content of a post, page, product etc.

That’s it. With the help of TranslatePress, the default WordPress search form will display only content in the selected language, relevant to the searched keyword.

Multilingual WooCommerce Search

The same thing applies if you’re building a multilingual WooCommerce store and are looking for an easy way to let visitors search for products in their language.

Making products and product descriptions available to your customers in their native language is a great way to boost conversions and increase revenue.

Multilingual WooCommerce Product Search

If you’d like to narrow down the multilingual search results to products only, you can easily achieve this by using the Product Search widget which WooCommerce offers.

Multilingual WooCommerce product search widget

Again, TranslatePress will make sure the product search results shown are in the selected language and relevant to the search term used.

Multilingual WooCommerce search in Spanish using TranslatePress

By using the product search to look for products related to “marca” (“brand” in Spanish), we’ll get only the relevant products – in Spanish.

Does Multilingual Search work with any WordPress Search Plugin?

As you’ve seen by now, TranslatePress will enhance the default WordPress search or WooCommerce product search making them multilingual ready. But what happens when you use other WordPress search plugins?

As long as the WordPress search plugins you’re using are based on and filter the default WordPress search results (using proper hooks), multilingual search will work and TranslatePress will make sure you get language-specific search results.

We’re looking to support all popular search plugins, so if you’re using one where multilingual search using TranslatePress isn’t working, please reach out here.

Setup Multilingual WordPress Search Today

As you’ve seen by now TransaltePress makes it really simple to translate your WordPress site and add a multilingual search form to it.

TranslatePress Multilingual

TranslatePress is the easiest way to translate your WordPress site. It's fast, won't slow down your website, works with ANY theme or plugin and it's SEO friendly.

Get the plugin

Or download FREE version

You can either translate the content manually, using the visual translation editor, or use automatic translation to speed things up and simply refine what’s needed.

Once your site is fully translated, using multilingual search your visitors or customers can easily find and browse the relevant content or products in their native language.

Do you still have questions about multilingual search in WordPress? Let us know in the comments!

If you found this post helpful, please check out our YouTube channel, where we constantly upload short & easy-to-follow video tutorials. You can also follow us on Facebook and Twitter to be the first to know each time we post.

3 thoughts on “Multilingual WordPress Search (How To Easily Search in Any Language)

  1. Hello,

    Thanks for this article which I read with interest. Does this means the search only searches the subdirectory? So, in this case, http://www.website.com/es.

    So, if we take the case of an English website (www.website.com) that contains the word “investigation” and the French version (www.website.com/fr) which also includes the French term “investigation”, I will only get French results if I search while I am on http://www.website.com/fr. Is this correct?

    1. Yes Grant, that is correct. The search will only display results in the selected language.

      It makes sense to be this way, as it would be really confusing for your readers to show results in multiple languages.

Leave a Reply

Your email address will not be published. Required fields are marked *