Home › Knowledgebase › KB-1138

How to Move Your Business Website to a New Host Without Any Downtime

Summary

This guide helps you troubleshoot and resolve: How to Move Your Business Website to a New Host Without Any Downtime. Follow the steps below to fix the issue.

Quick Tip: Need immediate assistance? 💻 Open a Ticket

Common Causes

Migrating a business website to a new hosting provider requires careful planning to minimise disruption. While true "zero-downtime" is difficult to achieve due to DNS propagation, you can move your files, databases, and email while keeping your site accessible to the vast majority of visitors. The key is to set up and verify the new environment before changing your domain's DNS records.

Pre-Migration Checklist

Before you begin moving any data, gather the necessary access credentials and information for both your current and new hosting providers.

Do not cancel your current hosting account until the migration is fully complete and you have verified that the new host is working correctly.

Detailed Instructions

Step 1: Set Up the New Hosting Environment

  1. Sign up for your new hosting plan and add your domain name to the new account.
  2. Create a new database on the new server via your hosting control panel.
  3. Create a database user with full permissions for that database.

Step 2: Migrate Website Files

  1. Connect to your current host using an FTP client like FileZilla.
  2. Download all website files from the public_html or www directory to your local computer.
  3. Connect to your new host using the same FTP client.
  4. Upload the files to the corresponding directory on the new server.

Step 3: Migrate the Database

  1. Log into phpMyAdmin on your current host.
  2. Select your website's database and click the Export tab.
  3. Choose the Quick export method and click Go to download the .sql file.
  4. Log into phpMyAdmin on your new host.
  5. Select the new database you created and click the Import tab.
  6. Upload the .sql file and click Go to import the data.
For dynamic websites (e.g., e-commerce or membership sites), put the old site into maintenance mode or stop writes to the database before the final export to prevent data loss during the transition.

Step 4: Update Configuration Files

Your website needs to know where the new database is located. You will need to edit your configuration file (e.g., wp-config.php for WordPress or config.php for other platforms).

  1. Open the configuration file in a text editor.
  2. Update the database name, username, and password to match the new host's credentials.
  3. Update the database host if it is not localhost.
  4. Save the file and upload it to the new server, overwriting the existing version.
If you are using a Content Management System (CMS), check if there are any "search and replace" tools available to update internal links from the old domain or IP to the new one.

Step 5: Test the New Environment

Before changing your DNS, you need to verify the site works on the new server without affecting your live visitors.

  1. Find the IP address of your new hosting server in your new provider's dashboard.
  2. Edit your local computer's hosts file to point your domain to that new IP address.
  3. On Windows, the file is located at C:\Windows\System32\drivers\etc\hosts.
  4. On macOS, use the Terminal and run sudo nano /etc/hosts.
  5. Add a line at the bottom: 123.45.67.89 yourdomain.com.au (replace with your actual IP and domain).
  6. Visit your website in a browser. You are now viewing the new server while the rest of the world still sees the old one.
  7. Test all forms, shopping carts, and login pages to ensure functionality.
  8. Remove the entry from your hosts file after testing so your computer resolves the domain via public DNS again.

Step 6: Update DNS Records

Once you have verified the new site is working, you can point your domain to the new host.

  1. Log into your domain registrar's management portal.
  2. Navigate to the DNS Management or Nameservers section.
  3. Update your A record to point to the new server's IP address.
  4. If changing nameservers, enter the new nameservers provided by your new host.
  5. Save the changes.
DNS propagation can take anywhere from a few minutes to 48 hours. During this time, some visitors may still see the old site, which is normal and does not constitute downtime.

Troubleshooting

Website displays a database connection error

Images or styles are missing after migration

DNS changes are not reflecting

If you encounter issues during your migration that you cannot resolve, you can Open a Ticket for assistance from our Brisbane-based support team.

Still Having Issues?

Need more help? If the issue persists after trying these steps, please open a support ticket and our team will assist you.

💻 Open a Ticket