Register Advertise with usHelp Desk Today's Posts Search

Rating: 2 votes, 5.00 average.

Cloning WordPress for multiple installs

Submit "Cloning WordPress for multiple installs" to Facebook
Posted 3rd May 2010 at 03:46 PM by Austin Delaney

update: I now use the excellent 'Duplicator' plugin that is completely gratis courtesy of Life In The Grid - find it in the WordPress plugin directory:


If you are creating a lot of blogs that are identical in their configuration (plugins, theme, settings) you can save a lot of time by creating a master blog that can be replicated with ease if you have cpanel hosting.

To prepare your master blog you will need to set up your blog exactly as needed (including plugins and theme) and then zip up all of the contents in your web folder (/public_html/)

This will be your master blog file.

The next step is to backup your master blog MySQL database as this has all of your settings for the plugin, theme and any pages/posts you have created. You can do this with phpMyAdmin by selecting the WordPress database and exporting it to your computer. i.e. download the .sql file.

The first thing to do to replicate your blog on another domain is to upload the zip file to the public_html folder of the new domain and then unzip the contents.

Secondly, create a new MySQL database using the cpanel MySQL wizard and copy the db name, username and password details to a text file.

Now open wp-config.php (in your public_html folder) for editing.

Replace the details of your master blog db name, username and password with the new db details and save the file.

The next step is to goto your new MySQL database with phpMyAdmin.

The database should be blank (no tables etc).

Click on import and select your master blog .sql file that you saved to your computer earlier.

After the database has been imported you will need to update some details before you can begin using your WordPress install on the new domain.

Make sure you have the new database selected (click on the db name on the left) and then click on 'SQL'. You are going to run a few SQL queries to update the database with details of your new domain.

Enter the following into the text box:

UPDATE wp_options SET option_value = replace(option_value, '', '') WHERE option_name = 'home' OR option_name = 'siteurl';

UPDATE wp_posts SET guid = replace(guid, '','');

UPDATE wp_posts SET post_content = replace(post_content, '', '');

Make sure to replace and with your details.

If you have made use of the wp-content/uploads directory you will also need to update the path to this directory.

Again, make sure you ahve the right database selected by clicking on the db name in the left hand side column and then click on search.

Search for 'upload' with all of the tables selected (select all).

In the results table click on 'browse' for 'inside table for wp-options'

Then click on the little pencil icon next to 'upload_url_path'

You will need to replace the path with the full path to your wp-content directory

Eg; /home/your_user_name/public_html/wp-content/uploads

Once you've done that just click on 'Go' and then login to your new WordPress install at using your username and password from your master blog.

Enjoy :]
Views 6267 Comments 5
Total Comments 5


  1. New Comment
    proserve's Avatar
    Great information here. Thanks for the insight...
    Posted 3rd May 2010 at 04:37 PM by proserve proserve is offline
  2. New Comment
    Istvan Horvath's Avatar
    Great guide!

    Too bad people don't like to mess with the database
    Posted 3rd May 2010 at 04:59 PM by Istvan Horvath Istvan Horvath is offline
  3. New Comment
    Thanks for the education.
    Posted 1st June 2010 at 08:35 PM by multistreams multistreams is offline
  4. New Comment
    josher's Avatar
    With Wordpress 3.0, it's now SO MUCH easier. After you set the master site, of course.
    Posted 6th July 2010 at 10:40 PM by josher josher is offline
  5. New Comment
    kd777's Avatar
    Hi Austin,

    Thank you for your excellent guide!

    This is almost exactly the same procedure that you use to follow. It's quite easy once you've tried it a couple of times, and you spare a lot of money by not buying one of these software applications that promise to do the same job but often disappoint.

    Thanks again!

    Posted 11th August 2010 at 03:28 AM by kd777 kd777 is offline

All times are GMT -6. The time now is 12:47 AM.