Website migration

How to move a WordPress site to a new host: Website Migration

Website Migration

As your website expands, your current hosting provider might not be able to meet your needs in terms of storage space, performance, or customer support. In such a situation, website migration to a different host can be helpful in achieving your objectives.

So, are you thinking to move your WordPress site to a new host or a different server? 

Well, website migration is a challenging task because it might cause data loss and downtime. It might be possible that your website would be temporarily inaccessible to users and search engines which negatively impact your search engine rankings and also result in a loss of sales.

To save you from this havoc, we have created a step-by-step guide to smoothly migrate WordPress website and make the entire process stress-free. And the good thing is you can repeat the process every time while migrating your site to a new host or server.

Let’s get started-

How to move WordPress site to a new host : Step-by-step guide

1. Select a new hosting company to migrate the WordPress website

If your current web host is unable to handle the increasing traffic even after optimizing your WordPress site, it’s time to migrate WordPress to a more suitable host. 

Choose carefully to avoid frequent website migrations. Bluehost is a good option for reliable shared hosting, Siteground is for cloud hosting or location-specific providers, and WP Engine is for managed WordPress hosting. 

Keep your new hosting account empty before proceeding with WordPress installation.

2. Install and activate Duplicator to start site migration

Website migration

Start the process of website migration by installing and activating the Duplicator plugin on your website.

  • As soon as it is activated, go to the WordPress admin area and navigate to Duplicator » Packages page
  • Now click the ‘Create New’ button in the right corner of your page. This action will set the stage for migrating your site to the new host.
  • Create a new package in Duplicator by clicking on “Package” and then, click the Next button.
  • Ensure that all scan results are satisfactory (displaying “Good” for each), then proceed to click on the Build button. 

It might take a few minutes to finish, so keep the tab open as the plugin performs its job.

  • After the process is finished, simply click on the ‘One-click download’ link to download both files. The Archive file is essentially a backup of your entire website, whereas the Installer file simplifies the installation process.

3. Import files to a new host

Upload both the archive and installer files to your new web host by connecting to your new web host using FTP.

Simply use your website’s domain name as the host when connecting your FTP client. However, it might be possible that your domain name is still taking traffic to your old host, you will need to connect using your server’s IP address or hostname to connect using FTP. 

Check your new hosting account’s control panel dashboard for this info. Contact your new web hosting company for assistance in case you don’t get it there.

Once connected, upload both the installer.php file and your archive .zip file to the root directory of your website, usually located at /username/public_html/ folder.

4. Prevent downtime by changing the host file

To ensure your website remains accessible during site migration to a new hosting company, you can temporarily access the new site on your computer without affecting the old site. 

Find the IP address of your new web hosting server in your cPanel dashboard, and use the hosts file on your computer to map your domain name to the new IP address. 

To do so- 

  • Windows users need to right-click on Notepad and select Run as Administrator.
  • Navigate to the C:\Windows\System32\drivers\etc folder to open the host’s file. 
  • For Mac users, you can use the Terminal app and enter a command to edit the host file. 
  • Once you have the file open, enter the IP address you copied from cPanel followed by your own domain name, then save your changes. 

This will help you to access the files on your new host using your own domain name, while the rest of the world continues to access your site from the old host. 

Once the migration is complete, remember to undo the changes you made to the hosts file.

5. Create a MySQL Database on Your New Hosting service provider

To run the installer on your new hosting provider, create a MySQL database. 

  • In your new hosting account’s cPanel dashboard, go to the Databases section and click on the MySQL databases icon.
  • Enter a name for your new database and click “Create Database.” 
  • Then, create a new user and add them to the database by selecting the user and database from the dropdown menus in the “Add User to a Database” section. 
  • Remember to take note of the database name, username, and password for use in the next step.

6. Initiate the Duplicator migration process

To proceed with the Duplicator website migration process, follow these steps-

  • Write this address in your browser http://www.domain-name/installer.php. (Here, write your domain name).
  • Check the terms and conditions box and click “Next” to continue.
  • Now add your MySQL host and database name. You need to write your username and password.
  • Make click on the ” Test Database” button to check the information is right.
  • If done without any error, Duplicator will import your WordPress database from the archive zip into your fresh database.
  • Click “Next” to proceed without updating the site URL.

7. Change DNS (Domain Name Server)

To switch your domain to the new hosting server, you need to update your DNS nameservers by logging in to your domain registrar’s account.

Obtain the DNS nameserver information from your new host (usually a couple of URLs), and locate the domain management area in your registrar’s account to access the nameservers section. 

Switch to custom nameservers and enter your new hosting provider’s information, then save changes.

DNS changes can take up to 48 hours to propagate. While waiting, keep your old hosting account for a week to ensure a seamless WordPress migration.

You can also check out our previous blog on how to ensure a smooth transition of your WordPress site.

Final Thoughts

Moving your site to a new server or host can be a daunting process. We hope with the help of this step-by-step guide, you’ll be able to carry out the site migration process seamlessly. If you still find it challenging, don’t hesitate to call us. We have a team of WP site migration experts ready to help you migrate your site smoothly without causing downtime.

whatsapp logo