InfoPhilicWordPressHow to Migrate WordPress Blog to new Server with Zero Downtime

How to Migrate WordPress Blog to new Server with Zero Downtime

WordPress is most popular CMS. It provides lots of features when it is self-hosted. If you have running WordPress blog and wants to migrate from old host provider to the new host provider. Then this tutorial is for you because here I am going to share a trick to migrate WordPress blog with almost zero downtime. Isn’t it cool??

During startup, you go with a starter plan or a shared hosting plans to start a new blog. But eventually, when your blog gets more traffic, you start facing some server issue like down time. So, this is the time you have to move on Virtual Private Server (VPS) or a dedicated server. During migration, you have to move all the files from old server to the new server.

Migrating your blog from old host to new one is quite tricky. There are some risks during migration: You may –

  • Break your blog.
  • Face downtime.
  • Loses your data.

DNS resolution takes almost 24 hours to propagate successfully. So, I would advise you to migrate WordPress blog during the time you get low traffic such as night time.

After migration, you may face some minor issues regarding with speed or optimization. So choose a free day so that you can fix them.

Read: Is BigRock the host for you?

So, all set ??

Let’s start with the migration process,

You have to work on both host services so keep both host info while working on. Open your current WordPress dashboard and delete –

Deleting unwanted stuff will reduce the size of both database and the wp-uploads directory. And hence you can save some minutes while downloading a backup from the old host.

Download wp-content directory from old host

  1. Use Filezilla (a free FTP Client) and connect your website.
  2. Now make a backup of wp-contents directory. (Download entire directory)

You can use a File manager from Host’s cPanel to do so. One benefit of using cPanel here is you can compress the wp-content folder and download it. Follow steps to download using cPanel:

  1. Log into the cPanel and Go to File Manager
  2. Click public_html and select your website directory
  3. Choose wp-contents folder, right click and select compress
  4. Once the compressed file created, you can download it.

It may take a long time depending on the size of your wp-contents directory. So have some patience.

Take database backup from host’s cPanel

To take database backup follow steps:

  1. In cPanel go to phpMyAdmin.
  2. Select your database and click Export.
  3. Choose SQL Format and click Go button.
  4. Refer screenshot below.

database-backup

You can also take database backup using backup wizard located in cPanel.

Once you done with the above steps, move to the new host.

Install WordPress on new host

Log into the new host’s cPanel and install WordPress using installer tool. For step by step guide use our tutorial How to install WordPress from Cpanel.

Upload wp-content directory on new host

Now, upload wp-contents directory to the new host. Use FTP Client (FileZilla) to upload wp-content folder.

If you are uploading compressed wp-content folder then don’t forget to extract it.

To extract you have to open File Manager from cPanel and navigate top compressed wp-content folder >> right click and extract.

Make sure all the files and folder are properly uploaded on the new host.

Create Database on New Host

Now you have to create a database on your new host. For that follow steps:

DON’T FORGET TO COPY AND PASTE YOUR DATABASE NAME, USERNAME AND PASSWORD ON STICKY NOTE OR SOMEWHERE ON NOTEPAD.

  1. Log into your new host’s cPanel.
  2. Go to MySQL Database Wizard.
    database-wizard
  3. Input required name for your database and click Next Step button.
    create-database
  4. Now input username and choose password (use password generator button to use Very strong password).
    database-username
  5. Click Create User button.
  6. Now you have to add a user to database check the ALL PRIVILEGES check box and click Next Step.
    privileges

Here you all set to upload database backup on your new host.

Upload Database to new host

To upload database on new host you have to follow these steps:

  1. Log into your new host’s cPanel
  2. Go to phpMyAdmin
  3. Choose the database which you have created earlier
  4. Click Import >> Choose downloaded database backup file (.SQL file format) and click Go button.

Refer below screenshot

Upload Database to new host

After importing click on structure option in top Navigation and note down table prefix.

Till now you have noted following things for your database:

  • Name
  • Username
  • Password
  • Table prefix

Edit wp-config.php file

Now, you have to edit existing wp-config.php file on your new WordPress installation.

  1. Go to new host’s cPanel.
  2. Select File Manager.
  3. Select your WordPress directory.
  4. Navigate to wp-config.php file.
  5. Right, click and choose Code Edit.
  6. Now add all the noted values in the wp-config file.
  7. Save it.

update-config-file

That’s it, you are done with almost 98% migration.

Migrate WordPress by changing Nameservers

Now you have to point DNS Nameservers to your new host. This will completely migrate WordPress blog to new host. Before that check all the things to make sure you didn’t miss anything.

To change nameservers choose low traffic duration of your site as I said earlier, it takes 24 hours to propagate.

Quick recap:

  1. Download wp-content directory from old host
  2. Take database backup from host’s cPanel
  3. Install WordPress on new host
  4. Upload wp-content directory on new host
  5. Create Database on New Host
  6. Upload Database to new host
  7. Edit wp-config.php file
  8. Update Nameserver to point to new hosting

Conclusion

So, this is how you can easily migrate your existing WordPress blog to the new host. I hope this tutorial will help you to migrate WordPress blog with zero downtime, but if you stuck anywhere just drop a comment for help.

You'll also like:
Continue to the category
Amit Malewar
Amit Malewarhttps://www.infophilic.com/
Amit Malewar has been the tutorial writer since 2013. His passion for helping people in all aspects of technology flow through the expert coverage he provides. In addition to writing for InfoPhilic, Amit loves to read and try new things.

Comment Policy: Your words are your own, so be nice and helpful if you can. Please, only use your real name and limit the amount of links submitted in your comment. We accept clean XHTML in comments, but don't overdo it please.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

GET STARTED
POPULAR NOW

How to Calibrate battery on your android device

For smartphone users, battery problems are the biggest concern. So to overcome this problem I am writing this short tutorial to calibrate battery. Battery issue...
DEALS

Cloudways Hosting

Load WordPress site in as fast as 37ms!
spot_img