[Rx] Using WordPress Duplicator to Restore Local Database

wp_02Duplicator is a plugin to backup, migrate, copy or clone a site from one location to another.

I wrote a recipe up some time ago to do a localhost database restore using Duplicator, but never prettied it up. Since it might be of use to someone in the future (like me), I’m going to go head and publish it.

There are a couple of variations to this theme. In one case, it just may be a restoration of a WP install gone bad on the same local development environment (WAMP, LAMP, etc). The other case might be an update of the local development environment. This walk-through assumes that you’re in the same environment.

1. Download both the archive and the installer files from your website using the Duplicator Plugin.

2. Move the archive file and installer.php to the local WP directory www/wordpress

If you install in www/ you will get weird 403 or 500 errors. How do I know this? Hmmm.

If you’re experimenting and worried that you might over-write something important, a little trick is to take all the WP files (assuming WP is installed locally) in www/wordpress and zip them up before you move the duplicator files over. Remember to move the zip file out of the directory before you run installer.php. Installer will check to see that there is only one zip file in the directory and will fail if you don’t move the file. How do I know this? Hmmm. If something goes wrong, just delete everything in the folder and then restore your files from the zip.

3. Launch the local server software (UniServer) with Apache and MySQL. The assumption is that you are using the handy-dandy UniServer setup with WordPress already rolled in. The name of the database is wordpress, the user is root, and the password is root.

4. In your browser, enter:

If you used a different listen port than 4001, change the address to use that port.


In this case, the install writes over a local wordpress that was already set up. The database already has a  name, user, and password. Since it’s a local install, there is no don’t need for a super-secret password.

5. Press Test Connection.

6. If you have success messages, press Run Deployment.

ERROR MESSAGE. If you get an error message, like below, delete all the wordpress directories and files in the www > .

Do Not Delete Install.php or the Duplicator Backup File. 


If you’re here, delete the files and press Try Again.


7. Press Run Update.

If everything works, the testing page will pop up.


8. Your local install of your WordPress site should now be good!

Also, the admin login will use the user and password that was set up for the site.