How to Create a Local Copy of a Live WordPress Site in 10 Steps

March 7, 2016

Cloning and synchronizing WordPress sites between environements (dev, staging, production) is something I would love to be able too. Wordmove sure is a great tool, but unfortunately it's nearly impossible to get it working on Windows. And believe me, I have spent hours trying.

A client recently got in touch with me, asking for some changes on his existing website. Therefore I wanted to have a local working copy of the live production site. As I'm unable to use Wordmove because I'm still stuck with Windows 10, I had to figure out a reliable solution for cloning a live WordPress site into my local dev environment.

10 Steps to clone a live WordPress site locally

  1. Create an archive of wp-content. You can do that easily using your host File Manager, or via SSH.
  2. Export your WordPress site database (either using phpMyAdmin or mysqldump directly)
  3. Install WordPress locally.
  4. Empty your local database & Import your live database (SQL file).
  5. Remove you local wp-content folder, and replace it with the one you just downloaded.
  6. Check that the database connection is still work. If not, open your local wp-config.php and make sure that the $table_prefix variable matches with the database prefix you just uploaded.
  7. Download this tool, and unzip into a folder /sr/ that is located at the same level as /wp-admin /wp-content /wp-includes
  8. Open that newly created URL in your browser:
  9. In the field replace, type your local site URL (in this example without trailing slash. In the field with, type your live site URL (in this example without trailing slash.
  10. Hit "Live Run", remove the /sr/ folder and reload your local WordPress site. Enjoy.


Please leave some feedback in the comments.