How to Clone a WordPress Site Easy Method – Move or copy a WordPress site to another server
Cloning OR Copying a wordpress between two host is a bit complicated process but i’m sure if you follow these steps then you will find its easier than any other process.
Say if you have Site A & Site B and you would like to clone Site A to Site B, So here are the Quick & Simple steps for that.
Step 1. You need to take a backup of Site A using Backup Plugin OR Login to your hosting control panel and create backup. You can Install BackUpWordPress and generate latest site & database Backup. Download them on local computer OR if Site B is hosted on VPS hosting then download backup using wget command through SSH
Step 2. Create a Database on Site B, note down the database credentials. Upload the backup file on Site B Root. Make sure Site B root (public_html) has extracted files, not the zip file.
Step 3. Open wp-config.php located Under Site B root and use the database details which you previously noted down in step 2. Save the file & close.
Step 4. Go to Site B phpmyadmin and select the Site B database which you have created in Step 2. Then got wp_options table and find siteurl & home rows and edit the Site B url.
Step 5. Find .htaccess file under Site B root and change the url from Site A to Site B, if it is not there anywhere then close the file without saving. If you on Nginx server then make the changes in nginx.conf from Site A to Site B & directory locations.
Step 6. Login to Admin via Site B admin URL and use the username & password of Site A. Once you login change the password if required otherwise go to Setting and change the Blog Name & Description.
If you visit your site then will notice its live & working but media links & page, post links are going back to Site A. To change them the final Step
Step 7. Download plugin called Velvet Blues Update URLs, install the plugin and activate. Then go to Tools (From Left Sidebar under admin) >> Update URLs. In Old URL section put your Site A URL and in New URL Put your Site B URL and select all Options under it but make sure you leave “Update ALL GUIDs”. Then hit Update URLs Now.
It’s done! All Site B URL are changed including links & media & other URL. In some cases some images are missing but in that case you will have to update them manually. How to Clone a WordPress Site Easy Method is ended in minutes.