Copy a WordPress Site to a Local Computer


For many of our WordPress projects we are making changes and edits to the client’s theme. Performing these changes on their live site is not a good idea. So, we have a process in place to copy a WordPress site to a local computer. Once the changes have been made and tested, we change out the files on the live site with the updated ones. Our method for obtaining the site files and database had been to copy the files via FTP and then use a plugin to create a copy of the database files. We would then create the database locally and import the database tables.

Recently, we decided to try to speed up our process of copying a WordPress site to a local computer. During our research we came across the article 3 Plugins For Easily Migrating A WordPress Site, Tried & Tested. After further review, we decided to try the Duplicator plugin by Life In The Grid.

The plugin is very simple and easy to use. Do be aware that the plugin is on WP Engine’s list of disallowed plugins (they create their own backups). The plugin is in the WordPress plugin repository and can be installed through your site’s dashboard.

Copy the WordPress Site

Once it has been installed and activated, you’re ready to start using it. Just go to Duplicator > Packages and click on the Create New button.

Duplicator - Create New Packages

The first step is the package setup. In most cases, the default settings will be sufficient. All you need to do at this step is click on the Next button.

Duplicator - Package Setup

The second step will scan your installation of WordPress and run some tests. The server section should return “Good” for all three tests (Web Server, PHP Setup, and WordPress). If not, you’ll need to troubleshoot those areas. The archive section may return some warnings. You should be okay to create the package with warnings as long as you don’t get any errors. If you do get warnings, you’ll need to click on the checkbox next to the message “A warning status was detected, are you sure you want to continue?” To finish this step, click on the Build button.

Duplicator - System Scan

The final step will create the Installer and Archive php files. Once these are ready, you’ll need to download them. We use MAMP for our local sites. (If you’re using another program, adjust the directory names and locations accordingly.) When you click on the button for either file, it will open the save dialog box. Save both files in your site folder in the “htdocs” directory.

Duplicator - Build Package

Install The Site Locally

Once the files have been saved, navigate in your browser to “localhost/SITENAME/installer.php”. The Installer will beginning running and start with the Deploy step.

If this is a new install, leave “Create New Database” selected in the Action field. If you’re going to be replacing an old database, select the “Connect and Remove All Data” option. The Host field will automatically populate for you. The Name field will be the name that you want to use for your local database (or name of existing database that you want to replace). The User and Password fields are the username and password that are setup for phpMyAdmin (most local system default to ‘root’ and ‘root’). You’re able to click on the Test Connection button to make sure your settings are accurate. You’ll need to select the checkbox next to the “I have read all warnings & notices” message. Then, click on the Run Deployment button.

Duplicator - Run Deployment

Next up is the Update step. The Duplicator installer will automatically populate these fields for you. This will replace references to the live URL in the database with the localhost URL. Verify that the information is correct and then click on the Run Update button.

Duplicator - Run Update

The final installation step is to test the new site. Simply follow the steps in order, and you’re local site should be ready to go. Note that the Save Permalinks and Security Cleanup steps require you to login to the site (using the same credentials that you use to login to the live site).

Duplicator - Test Site


I’m sure you’re wondering how much time this plugin could possibly save you. We decided to test the plugin and time how long it took to recreate the Endo Creative website. We used our old method to copy a WordPress site to a local computer first and then copied the site locally again using Duplicator. The site was entirely recreated using Duplicator in less time than it took to finish downloading just the site files using FTP.

In short, the plugin speeds up the process while simplifying it at the same time. We now spend less time in setup and more time working with the actual code.

For even more productivity tips, learn about how to Build Systems Into Your Business to Improve Your Bottom Line.

One thought on “Copy a WordPress Site to a Local Computer

  1. Thanks for this! We are preparing a major revision of our website so your post was timely. We followed the instructions and it worked perfectly.

    We used XAMPP on a Windows 10 machine. To install XAMPP, the following video was helpful (it’s also embedded in the FAQ page of the plugin):

Leave a Reply

Your email address will not be published. Required fields are marked *