There are many reasons why you need to replace old web hosting services and migrate the WordPress website to the best hosting service. Some of the reasons that often occur for example are caused by slow loading speed, downtime problems, lack of support, to prices that are not comparable to service. In this tutorial, we will show you how to move WordPress hosting.
What do you need?
Before starting the steps in this tutorial, make sure that you have:
- Access to the WordPress admin dashboard
- Access to the control panel or FTP and database hosting
- Access to the new hosting control panel or FTP
- Access to the domain panel
Step 1: Choose a new WordPress host
When choosing a new hosting, be careful and think carefully. Do research. If you have chosen to make a change, you might have a good reason to do it.
Make sure that you with the new hosting provider do not rediscover the same problem. The host more cheaply is not a reason. The best hosting should be selected to allow us to focus on our business and not to continuously migrate our hosting.
Step 2: Back up your website files
Requirements, you need to have access to WordPress files first. Actually, all you need is to move files from the old hosting service to the new hosting and edit the code in the wp-config.php file.
Transferring files can be via File Manager, the FTP client.
Step 3: Export the WordPress database
Exporting your database can be an easy method that only requires some steps to solve it.
Log in to the cPanel account of your web server and open the phpMyAdmin application.
Select the database that contains your WordPress installation from the list in the left sidebar and after selecting click on the Export tab on the navigation menu.
Step 4: Create the WordPress database on your new host server
Before we start migrating to a new hosting, we want to set up a WordPress installation. To do this, you need to create a database that will only import your SQL information.
Log in to your new hosting with the user credentials they provide you and connect with the cPanel software system. For this tutorial, we will use the MySQL Database application. If your hosting doesn’t run the application then you might need to contact their support team to get their steps in creating a new database.
Write the name of the info, the new MySQL username, and the password.
You will need it soon.
Step 5: Edit the wp-config.php File
Browse the folder on your local computer wherever you download your website file. in that folder, there is a file known as wp-config.php that controls access between WordPress and the database.
Duplicate this file and save it in another folder on your local computer. this is often needed to recover changes when we are wrong later.
Open the first version of the file together with your favorite text editor and make the following changes below:
- Change Database Name
- Change Database Username
- Change Database User Passwords
- Change the Customs Code (optional)
Step 6: Import your database
Now you have a new database to work on and we will start the import method.
Launch phpMyAdmin from the cPanel code on your new hosting and select your new database from the left sidebar. After opening, select the Import tab from the navigation menu and you can import SQL files there.
Step 7: Upload the WordPress files to your new host
Now you have the new database and you’ve reconfigured the wp-config.php file, it’s time to start uploading your website’s files.
Connect to your new hosting, open the FTP program and browse to the folder on your website that you will create. If this is the main one, or only one site is installed on this web server, uploading the file to the public_html folder is the usual directory.
With the designated remote directory you will be able to transfer your website files which currently have to include the latest version of wp-config.php.
As with previous downloads, this process can take some time.
Step 8: Check the new site temporarily
You can check your site temporarily by setting up the etc / hosts file that points to your domain to make sure everything all setting is correct.
Step 9: Defining a new domain
If you move to a new/different domain then you have to read more on this step, if not, then you will be able to skip this because you don’t need to update your website to point to a different domain.
The issue that is often heard when Migrate WordPress site is the web still directs to the previous domain. To fix this issue we need to change the website database to point the website to the new domain.
Step 10: The last stage
In fact, this step includes two separate things with several days including (potentially).
You need to reconfigure your domain’s DNS settings before you can use the site on your new hosting. They are set to point to your old host and you need to point to the new IP address of the correct record.
This process depends on where you register your domain. Details to complete this process are too diverse to be discussed in this post, but all the details you need to make this change must be at your domain registrar.
Changes the DNS may take up to 48 hours to spread completely. It is best to do this when the traffic level is expected to be lower. You should avoid making any changes to your website during this 48-hour because you might change the old version of the site.
You will able access a new hosting when you go to your website after a 48 hour period has expired. At this point, to delete files and databases, you can connect to your old hosting. A copy of the local backup of these files and the export database must still be available, along with the original wp-config.php file if you need to roll back the migration. Holding these files for long periods of time can be a good idea just to be on the safe side.