Copying a WordPress site is useful for several reasons, especially if you’re considering a website redesign or testing purposes (like trying a new theme). Having a copy of a WordPress site also comes in handy if you deploy new websites for clients with similar settings, plugins, and themes installed. You may also want a copy of a WordPress website to learn how it was built.
In this post, we’ll cover how to copy a WordPress site in just a few steps. We’ll cover the manual method of copying a WordPress site and how to shortcut the process with a plugin like Solid Backups.
Getting Started: The Components of a WordPress Website
A WordPress website is made up of two basic components. Both components will need to be included to have a copy of your website:
- 1. The WordPress database. The WordPress database contains the content of your WordPress posts, pages, comments, users, and more.
- 2. The WordPress files. A WordPress website contains hundreds of files and folders that work together to make your website operate. These files include the WordPress core files, all the files you’ve uploaded to your media library (
.jpg
,.png
, etc.), PHP scripts, other code files, and all your theme or plugin files. Additionally, you must copy all files in your WordPress installation directory (including subdirectories) and your.htaccess
file.
Making a Copy of Your WordPress Website is Just Like Making a Backup
In reality, copying your WordPress website is similar to backing up your website. A WordPress backup essentially makes a copy of your entire WordPress installation (including your WordPress database and all files in your WordPress installation). Just like making a backup, you’ll also need an easy way to access your backup files in a downloadable format.
How to Copy a WordPress Site: The Manual Method
In this section, we’ll cover the manual method for how to copy a WordPress site. If you aren’t uncomfortable editing code or browsing files on your server, you can skip ahead.
How to Copy Your Site’s Database
- You’ll need access to phpMyAdmin on your site’s server to copy your site’s database. As a quick reference, you’ll find the phpMyAdmin icon located after logging in to cPanel.
- Click on the phpMyAdmin icon and log in. (If you’re already logged into cPanel, phpMyadmin should launch automatically.)
- From the left side of the page, select your WordPress database. In this example, the name of the database is “
wp_
“.
- You should now see all the tables in your WordPress database (for example:
wp_commentmeta
,wp_comments
,wp_options
,wp_posts
, etc.) - Click the ‘Export’ tab on the top tabs. Select the “Quick” option and click the “Go” button.
Your database file should download automatically in an .sql
format. Depending on the database size, this may take a few seconds.
How to Copy Your Website’s Files
You can use an FTP client to manually copy the files on your server to a folder on your computer. Once you’ve downloaded the files, you can zip or compress them into a zip file. Note: depending on the size of your site, this download could take a while.
How to Copy a WordPress Site with a Plugin (The Easy Way)
Our WordPress backup plugin, Solid Backups, makes copying WordPress sites much easier than the manual method. With Solid Backups, there’s no need to export or download any files manually.
Here are a few ways Solid Backups makes copying a WordPress site easier:
- You can copy your WordPress site directly from the WordPress admin dashboard (no need to log in to cPanel or an FTP client).
- You can download an entire WordPress website in a zip file (including your database and files) in minutes — and sometimes seconds.
- You can quickly move the website copy to a new location, such as a different domain, host, or testing server, with Solid Backups’s Importer script.
Use the Solid Back Plugin to Make a Complete Backup
- Install and activate the Backups plugin on your WordPress website to get started. You can buy Solid Backups and download the plugin .zip file from your SolidWP Member Panel.
- Once you’ve activated the Solid Backups plugin, expand the Solid Backups menu on the left side of your WordPress dashboard and click the ‘Backup’ link.
- Click the Complete Backup button on the Backup page to start taking a backup of your site’s files and database.
- Once the backup has been completed, you can download your backup file as a zip file to your computer. This backup file is essentially a complete copy of your WordPress site.
- Once you’ve downloaded the backup zip file, you can expand it to see the contents. This is a copy of your website.
How to Move the WordPress Site Copy to A Different Domain, Host, or Server
Once you have a copy of a WordPress site, you’ll likely want to use it in a testing environment or development site. To do this, you must move your WordPress site copy to a different location, such as a separate directory on your server, a new domain, or a local host.
The Manual Method of Moving a WordPress Site
If you want to move your website copy manually, use these two posts as a reference. These posts include more in-depth instructions if you want to tackle doing it manually.
- From the WordPress Codex: Moving WordPress
- From the WordPress Codex: Restoring Your Database From Backup
How to Use Solid Backups To Move Your WordPress Site
Solid Backups makes moving a WordPress website easy by automating the process.
For example, Solid Backups removes these complicated steps from the process:
- Editing the
wp-config.php
file with the new server’s MySQL database name, user, and password. - Searching and replacing your entire database to change URLs
- Changing uploaded media to refer to the new location
- Migrating serialized data
We have two more in-depth tutorials, but the process works like this. You can read both scenarios here.
Moving a WordPress Website to a New Server or Web Host
How to Move a WordPress Site to a New Server
In this post, we cover a step-by-step guide for how to move a WordPress site or blog to a different server or hosting company. Read more …
You’ll want to use this tutorial to move your website copy to a different server or directory on your current hosting plan. You’ll also want to use this tutorial to transfer the website copy to a new hosting company.
Moving a WordPress Website to a New URL or Domain Name
How to Move a WordPress Website to a New Domain
In this post, we cover a step-by-step guide for how to move a WordPress site to a new URL or domain. Read more …
Use this tutorial if you only need to change the domain name or URL of the website copy. (You can also tweak the server or hosting location using this method.)
Instructions for How to Move a WordPress Website with Solid Backups in 10 Steps
- Download your complete backup file and leave it in the .zip format. (See steps 1 – 4 above in the “Getting Started with Solid Backups” section.) Note: Don’t unzip the backup file.
- Navigate to the Backups screen in the Solid Backups menu. Click the Standalone Importer button to download the importer script,
importbuddy.php
. (Its name dates back to Solid Backups’ predecessor, BackupBuddy.)
- You will be prompted to create a password to run the restore script. Create and confirm your Importer’s password. In the window that pops up, enter a new password or leave it blank to use the Importer password you set up when you first installed Solid Backups. This password is important because it locks the Importer script from unauthorized access. Click “OK,” and the download will begin.
- The next part of the process requires you to create a WordPress database for your copied WordPress site on your server. Solid Backups will take the database from your copy and replace the tables, but you still need a new, blank database.
Be sure to copy the database name, username, and password you create in this section to use later in the Importer’s migration process.
- Next, upload the backup zip file and the Importer file to your server’s directory for the new/moved site. (Basically, a directory is where your WordPress site “lives” on your server. All the files that run the WordPress site are located within this folder/directory.) For this step, you can use FTP access to the server or the File Manager within your cPanel. You need access to upload (or delete) files on your server.
- Open the directory (folder) of the final location of the WordPress site.
- Upload the
importbuddy.php
file and the backup zip file to this empty directory. You can use the Upload function within the File Manager.
After you upload the importbuddy.php
file and the backup zip file, the directory should look like this:
- This final series of steps will guide you in using the importer to finish the site move. Navigate to the site
URL/importbuddy.php
. For example, we’d visit this link in your browser in our example site move:http://examplesite.com/importbuddy.php
. - Follow the remaining importer steps to complete the site move. You’ll need the importer password if you create one. You’ll also need your new database credentials. Then verify the site is working by clicking on the site URL.
10. Click the “Finish Cleanup” button. That’s it! You’ve successfully moved your WordPress site copy to a new location.
Get Solid Backups Now!
Get Solid Backups, the 3-in-1 WordPress backup plugin. Easily back up, restore, and migrate your WordPress site with Solid Backups.
Solid Suite
Sign up now — Get SolidWP updates and valuable content straight to your inbox
Sign up
Get started with confidence — risk free, guaranteed