Let’s say you are not satisfied with your current provider or you found a better host and you want to move your WordPress website. If you are not sure how to do this, we have a solution for you. With our how to transfer WordPress site to another hosting guide, you will finish the entire job in a matter of minutes.
Make A Backup Of Your WordPress
This is a standard procedure in case anything goes wrong but it is also a needed step in our guide. Don’t use any plugins but instead connect to your web host by using a FTP software, such as CuteFTP. Find your WordPress directory and copy (download) all the files to your PC. Make sure to remember the location where you copied them in case you need them. Don’t erase your website yet.
Upload Your WordPress files To The New Server
Use CuteFTP (or another program) to connect to your new web host. Choose the desired directory and upload all the files you downloaded in the first step of how to transfer WordPress site to another hosting.
Use PhpMyAdmin To Export Your Database
Log into phpMyAdmin and find the database of your WordPress website. Choose export from the top menu and then pick the quick export method, leaving the SQL format. The software will now create a “wordpress.sql” file for you, which you need to save to your PC.
Create A New MySQL Database
Log in to the control panel of your account with the new web host. Find the section for MySQL databases and create a new one with the appropriate name.
Edit The “Wp-config.php”
After creating the new database, locate the root domain of the WordPress website that you uploaded with FTP software or by using a file manager within the control panel. Make sure to fill in the appropriate data in the underlined sections:
/** The name of the database for WordPress */ define('DB_NAME', 'cpuser_dbname'); /** MySQL database username */ define('DB_USER', 'cpuser_uname'); /** MySQL database password */ define('DB_PASSWORD', '******'); /** MySQL hostname */ define('DB_HOST', 'localhost');
Save the file by overwriting the previous version of it on the server.
Import Your WordPress Database
The final step of how to transfer WordPress site to another hosting requires you to log into phpMyAdmin again, this time from your new web host account. Choose the database you created for the website and select Import from the top menu. Select the SQL file you previously saved on your computer and start the import process.