Migrating a WordPress Website to New and Better Host

There are numerous reasons why a site owner might opt to migrate a WordPress website to a new and better host. Most common issue is slow loading speed even after optimizing your site.

This migration process, admittedly, can be a daunting task. So much so that a site owner would rather pay a professional to do it or settle for a host that provides that service. If you have the technical know-how, you can go the third route of doing it yourself.

Below we take a look at what are the steps for migrating a WordPress site to a new host.

1. Back up your website files

As a rule of thumb for any migration process, you should back up all your files. Backing up your files is a requirement for migrating your WordPress installation.

Using an FTP program such as FileZilla, connect to your web host and copy all files from your website’s directory to a folder on your local computer.

This includes your htacces file that is set to be hidden. If you fail to see it, you can consult your FTP program’s help file to have it display hidden files.

2. Export WordPress data base

You can do this by logging in to the cPanel account of your web server and open the phpMyAdmin application.

Select the database that contains your WordPress installation and once done, click on the Export tab on the navigation menu.

3. Create the WordPress database on your new host server

With the credentials that have been supplied to you, log on to your web host and connect to the cPanel software.

Create a MySQL database and note down the password and user name because you will need it soon

4. Edit the wp-config.php file

Where you initially downloaded your website files to there will be a file called wp-config.php that controls access between your WordPress and your database.

Make a copy of this file and store it in your local computer.

Open the original version of the file in your editor and make the following changes;

  • Change the database name
  • Change the database user name
  • Change the database user password

5. Import your database

Launch phpMyAdmin from the cPanel Software on your new server and select your new database.

Once it opens press import tab from the navigation menu.

In the file to import section, you will need to choose the file button and select the SQL file imported previously.

After un-ticking the partial import check box, make sure the format is set to SQL and click on the go button. The database import will begin.

You should receive a message informing you when the import is concluded successfully.

6. Upload the WordPress files to your new host

With the remote directory selected, you can now upload your website files that should now include the updated version of wp-config.php

7. Linking to new URL and defining the new domain

By doing a search and replace for the old domain and replacing with the new one you will also be altering the domain URL, and home URL values in the database which will ensure that trying to log on to the site on the new domain does not try to redirect you over to the old domain.

8. The final touches

You will need to reconfigure your domain DNS settings, so they point the correct records to the new IP address.

DNS changes can take up to 48 hours to fully propagate

Migrating WordPress to a better host is certainly not an easy task for beginner. Missing a step can spell untold problems for you that might need a professional hand to handle. As such it might be a good idea to seek out a professional to do it for you from the beginning.