Back to Community

How to Find a Specific String Across Your WordPress Site for Translation

15 threads Sep 16, 2025 PluginLoco translate

Content

A common challenge for WordPress site builders and translators is tracking down the source of a specific string of text. You might see a word like "Brand" on your front end but have no idea which plugin, theme, or file is responsible for it. This makes it impossible to use a translation plugin like Loco Translate to modify it, as Loco Translate works on a per-file, per-text-domain basis.

This isn't a bug in Loco Translate; it's a fundamental aspect of how the plugin is designed. Loco Translate is a file editor, not a site-wide string search utility. Its interface is built for managing translation files (POT, PO, MO) for individual text domains one at a time. Therefore, the initial step of locating which file contains the string you need to translate must be done outside of the plugin.

Why You Can't Search All Strings in Loco Translate

Based on analysis of community discussions, the Loco Translate team has consistently noted that a global site search feature is not part of the plugin's functionality. It has been mentioned as a possible future addition but is not currently available or planned for imminent release. The plugin's focus is on the accurate editing and management of existing translation files, not on indexing every string across a WordPress installation.

Solution: Using System Tools to Find Strings

The most effective and recommended method for finding a string is to use command-line tools on your server. This approach is extremely fast and powerful, even on large sites with many plugins.

For users with SSH/command-line access:

The grep command is your best tool. You can search all PHP files within your plugins and themes directories for a specific text string. For example, to find the exact phrase "This exact text", you would run:

find wp-content/plugins -name "*.php" | xargs grep -l 'This exact text'

This command will list the files containing that text. The file path will immediately tell you which plugin or theme to target in Loco Translate.

For users without command-line access:

If you don't have server command access, you have a few alternatives:

  1. Use your hosting file manager: Many hosting control panels (like cPanel) have a file search function within their file manager.
  2. Download and search locally: You can download your entire wp-content folder to your local computer and use a desktop code editor like VS Code, Sublime Text, or PhpStorm to perform a global search across all files.
  3. Plugin solutions: While not directly related to translation, some WordPress admin plugins offer search functionality for site content. However, these typically search the database (posts, pages) and not plugin or theme source code.

What to Do Once You've Found the String

Once the grep command or your search method identifies the file, note the plugin or theme name. Then, open Loco Translate, select that specific plugin or theme, and choose the correct text domain to view and edit its strings. The string you found should now be present in the list, ready for translation.

By understanding the scope of Loco Translate and leveraging powerful system tools, you can efficiently track down any elusive string and get back to translating.

Related Support Threads Support