Localization means translating WordPress into your local, regional or country language. By default, WordPress installs in English, but if you want it in your language, e.g. in Spanish, you can do so. And, its not a hard or time consuming process. In this tutorial, we’ll show you how to translate WordPress to the language you want. We’ll be installing a plugin known as “Code Styling Localization.” Using this plugin saves time because we don’t have to manually translate each and every element.
Introduction to PO and MO files:
PO files (Portable Object files) :
PO is the file where translation of both languages are stored. One is English and the other is the one you’re translating to.
MO files (Machine Object files) :
PO files are then converted to machine readable binary files (MO files). The plugin which we’ll be using will do this step for us.
Installing “CodeStyling Localization”
- Download CodeStyling Localization.
- After downloading, unzip it
- Now upload this folder to wp-content/plugins
- You can use a FTP client, like FireFTP, to upload this plugin or use File Manager from cPanel
- Now login to WordPress admin and from the plugins section, activate CodeStyling Localization.
Using Localization Plugin
From the Tools, click on “Localization”. Now select the path where you want to place the saved PO file. That PO file will be automatically saved in that path.

E.g. to save the .PO file to wp-content/themes/WPStore, then simply click on wp-content/themes/WPStore. After that, click on “Add New Language“.

One window will pop up, select the language you want to translate to. Also, in the last translator field, you can write your name. E.g. in the example below, we have selected Italiano/Italia as the language we will be translating to is Italian.

After selecting the language, click on “create po-file“.
Scanning for possible language translation words:
In the next step click on “Rescan“.

Now click on “Scan now” and then on “finished“.

Getting the .PO file from Pepipopum
:
Your PO file is created. Now, head over to pepipopum.dixo.net, click on “Browse,” and select the PO file from the path you’ve selected earlier. If the file is on your server, download that PO file first then select that file for upload to pepipopum.dixo.net. In “Target Language“, select your target language. In this example, let’s select Italian.

After selecting your PO file and output language, click on “Translate File“. In the next screen you will be able to see the translation. Copy the whole text in that page and paste it in the PO file. You can open the PO file through Notepad. Don’t forget to delete the old data in that file and then paste this new data. Save the file and now your new Italian file is ready.
Upload this new PO file to wp-content/themes/WPStore. This is the path selected earlier. You can overwrite the old file. The file name should remain the same though.
Generating MO file:
From the WordPress admin, go to Tools > Localization. Click on “Edit“.

In the next screen, notice the “generate mo-file” button. Click on this button.

Now your MO file is also generated.
Editing the Code:
From WordPress admin Appearance tab, click on “Editor“. Now click on “Functions.php” Locate this line
24
/*load_textdomain( ‘default’, TEMPLATEPATH.’/en_US.mo’ );*/
and simply edit it by removing this /* and */ (remove the first two and last two characters). Rename the file name as per your new MO file name. In this case, the name of file is “it_IT.mo”. So it will look like:
load_textdomain( ‘default’, TEMPLATEPATH.’/it_IT.mo’ );
After editing, click on “Update file“. So this was the last step. Go ahead and translate the theme in your own language.
Note: If you don’t have permission to edit the functions.php file, you need to chmod the file through FTP to 666. Edit then save. When finished, chmod it back to 644. Or, download the functions.php file from your Templatic themes folder on the server, edit the file, then upload it back to the server to overwrite the file on the server with the new changes.