Grab Your Free 17-Point WordPress Pre-Launch PDF Checklist:
Migrate a WordPress site to a new host and new domain manually | WP Learning Lab –
Exclusive for WPLearningLab viewers, up to 50% off hosting:
To migrate a WordPress site to a new host and new domain you must create a full backup of the site you’re moving and replicate it in the new hosting by following these instructions.
To migrate WordPress site to new host there are two steps. First, we need to prep the existing site for transfer and then initiate the actual transfer.
To backup the files, log into your cPanel account and open the file manager. In the file manager select all of the files in the root of your WordPress site. Then click on the Compress button to zip up all the files.
Once zipped, click on the backup and then click the download button to download the zip file.
Following that, log into phpMyAdmin and open the database that belongs to your site. Click on the Export tab. Then choose the Quick open, make sure SQL is selected and export the database.
This will download the SQL file to your hard drive.
Now you have a full backup of your site.
Next, open the cPanel account in your new host, or even in your current host.
Open the File manager in that cPanel account. Now find the root folder of your new domain. Click on the Upload link and select the ZIP file you created earlier to upload it.
Once it’s uploaded, selected it and click on Extract to unzip it.
Now all your site files are in place.
We now have to add the credentials for a new database to your wp-config.php file.
First create the new MySQL database in the cPanel account. Then add the database name, database username and username password to the wp-config.php file.
Next, log in to the phpMyAdmin and find the database you just created. It should be empty, if it is not then drop all of the tables in that database.
Once empty, click on the Import tab. For the import, select the SQL file that you created and downloaded earlier.
This will upload your site’s entire database.
Once the upload is completed, open the wp_options table. The first two rows of that table will contain the URL of your old site. Update them to contain the URL of your new domain. Make sure the updates ‘stick’ by refreshing the page and making sure the new domain is still in both fields.
Now you can access your new domain and your old site will be there.
You can login with the username and password you used on the old site.
You may have to reset some of the permalinks by visiting the pages on your site. If they do not load, you will need to change the status of the page to Draft and then change it back to Published. That will reset the permalink and make that page accessible again.
That’s all there is to it. I hope this information helps you! If you have any questions leave a comment below or ping me @WPLearningLab on Twitter.
If you want more excellent WordPress information check out our website where we post WordPress tutorials daily.
Connect with us:
WP Learning Lab Channel: