Back to Community

How to Manage Multiple Translation Files and Transfer Them Between Sites

5 threads Sep 16, 2025 PluginLoco translate

Content

If you manage multiple WordPress sites or plugins, you've likely encountered a common challenge: handling translation files with the same name or needing to move translations from one site to another. This guide explains why this happens and provides practical solutions based on community knowledge.

Why Do Translation File Conflicts Occur?

The core of the issue lies in WordPress convention. Each plugin should use a unique text domain for its translations. However, some plugin developers use identical text domains or file names, leading to conflicts. When multiple plugins try to load a translation file named, for example, 'my-plugin.po', only one will load correctly, causing translation issues in the others.

Solution 1: Configure Custom Paths for Conflicting Plugins

For plugins with conflicting file names, you can define a custom path. This is done in the 'Advanced' tab within the Loco Translate plugin's configuration for each specific bundle (plugin or theme).

  1. Navigate to Loco Translate → Themes or Loco Translate → Plugins.
  2. Click on the item you need to configure.
  3. Click the Advanced tab.
  4. Here, you can define a custom path for the translation files.

Important Note: This configuration helps Loco Translate manage the files, but the plugin itself must be coded to load translations from this custom path. If the plugin's code does not support this, the custom path may not work. The primary purpose of this setting is to match a plugin's existing behavior, not to redefine it.

Solution 2: Manually Transferring Translation Files Between Sites

There is no built-in bulk export/import function in Loco Translate for moving multiple translation sets at once. The process must be done manually for each text domain.

  1. Identify the files: For each plugin or theme, you need to find its translation files. These are typically found in two locations:
    • Within the plugin's own directory (e.g., /wp-content/plugins/some-plugin/languages/).
    • In the global WordPress languages directory (e.g., /wp-content/languages/ or a subfolder like /plugins/).
  2. Download the files: Using your hosting file manager (e.g., cPanel), FTP, or SFTP, download all relevant files. A complete set for a single text domain often includes:
    • .po (Portable Object file, contains the source text and translations)
    • .mo (Machine Object file, a compiled binary version of the PO file)
    • .json (Sometimes used for JavaScript translations)
    • .l10n.php (An alternative PHP-based translation format)
  3. Upload the files: Place the downloaded files into the exact same directory structure on the target website. Loco Translate will automatically detect them.
  4. Alternative Upload Method: You can also use Loco Translate's interface. Download the .po file from the File info tab (using the cog icon) on the source site. Then, on the target site, go to the same translator screen and use the Upload PO tool to add the file. You will still need to ensure the .mo file is compiled afterward.

Solution 3: Using Automation and Filters

For developers comfortable with code, the Loco Translate plugin offers filters for greater control. For instance, the loco_po_headers and loco_pot_headers filters allow you to modify header information programmatically.

While there is no official integration with bulk management tools like MainWP or automation platforms like n8n, the manual file-based process means any tool that can sync files (like SFTP clients or rsync) can be used to transfer translations in bulk.

Conclusion

Managing translation files across multiple plugins and sites requires a manual approach. The key is understanding the file structure of your WordPress installation and using standard file transfer methods. While not automated, this process provides a reliable way to ensure your translations are consistent across all your websites.