Display WP Ghost in a specific language regardless of your WordPress dashboard language using either the built-in Plugin Translations toggle or a custom plugin_locale filter in wp-config.php. By default, WP Ghost displays in your WordPress dashboard language if a translation is available. Two scenarios are common: you want to use the plugin’s bundled translations instead of WordPress’s general language pack (use the built-in toggle), or you want to force a specific language different from your dashboard (use the wp-config.php method). Both methods only affect WP Ghost – your dashboard and other plugins remain in their configured language.
Method 1: Built-in Plugin Translations Option
WP Ghost ships with bundled translation files for several languages. By default, WordPress checks the global wp-content/languages directory first. The Built-in Plugin Translations option reverses this priority so WP Ghost loads its own translations before falling back to the global directory.
- Go to WP Ghost > Advanced.
- Find the Built-in Plugin Translations option.
- Toggle it ON.
- Click Save.
WP Ghost will now load translations from its own languages folder first, ensuring you always get the most up-to-date translations included with the plugin version you’re running.
When to use this option: Enable it if your dashboard language doesn’t match WP Ghost’s translation, if WP Ghost shows partially translated text, or if you want to use the latest translation strings shipped with the plugin update. The current version includes translations for English, French, German, Spanish, Italian, Portuguese, Dutch, Romanian, Russian, Turkish, and Indonesian.
Method 2: Force a Specific Language via wp-config.php
If you want to force WP Ghost to display in a specific language different from your WordPress dashboard language (for example, your site is in French but you prefer the WP Ghost interface in English), use the plugin_locale filter in wp-config.php.
- Open
wp-config.phpvia your hosting File Manager, FTP client (like FileZilla), or cPanel File Manager. The file is located in your WordPress root directory. - Add the following code at the end of the file, before the line that says
/* That's all, stop editing! */:
add_filter( 'plugin_locale', function ( $locale, $plugin ) {
if ( $plugin === 'hide-my-wp' ) {
return 'en_US'; // Forces WP Ghost to use the en_US locale
}
return $locale;
}, 11, 2 );- Save the file. If you used FTP, upload it back to the WordPress root directory.
- Refresh your WordPress dashboard. WP Ghost now displays in the language you specified.
Important: Always back up wp-config.php before editing. A typo or misplaced character can break your entire site. If something goes wrong, restore the backup and try again.
To use a different language, replace en_US in the code with your preferred locale. For example, fr_FR for French, de_DE for German, or es_ES for Spanish.
Common Locale Codes
WordPress locale codes follow the format language_COUNTRY. Use these for the WP Ghost languages currently supported:
| Language | Locale Code |
|---|---|
| English (US) | en_US |
| French | fr_FR |
| German | de_DE |
| Spanish | es_ES |
| Italian | it_IT |
| Portuguese (Brazil) | pt_BR |
| Dutch | nl_NL |
| Romanian | ro_RO |
| Russian | ru_RU |
| Turkish | tr_TR |
| Indonesian | id_ID |
For the complete list of WordPress locale codes, see the WordPress Polyglots Teams page.
Frequently Asked Questions
Which method should I use?
Use the built-in Plugin Translations option if you want WP Ghost to use its own bundled translations in your dashboard’s language. Use the wp-config.php method if you want to force WP Ghost into a specific language different from your dashboard. The built-in option doesn’t change the language – it just changes which translation files are loaded.
Will this affect my dashboard or other plugins?
No. Both methods only affect WP Ghost. Your WordPress dashboard, other plugins, and your site frontend remain in their configured language. The plugin_locale filter checks specifically for the hide-my-wp plugin slug and only modifies that plugin’s locale.
My language isn’t in the table. Can I still use it?
You can use any WordPress locale code in the wp-config.php method, but if WP Ghost doesn’t have a translation for that language, the interface will fall back to English. To contribute a translation for your language, visit the WP Ghost translation project on WordPress.org.
How do I undo this change?
For the built-in option, toggle it off in WP Ghost > Advanced and save. For the wp-config.php method, remove the add_filter code block from wp-config.php and save. WP Ghost will return to using your dashboard’s language.
Does WP Ghost modify WordPress core files?
No. WP Ghost itself never modifies core files. The wp-config.php method requires you to manually edit one file – wp-config.php – which contains your site configuration but is not technically a core file. WordPress doesn’t overwrite wp-config.php during updates.
Related Tutorials
Customize WP Ghost behavior:
- WP Ghost Constants in wp-config.php – All wp-config.php constants for customizing WP Ghost behavior.
- Advanced Options – Other advanced settings in WP Ghost.
- Customize Paths with WP Ghost – Main path security configuration.