Hosting

How to migrate a website to a new host without downtime

A step-by-step migration plan covering backups, DNS TTLs, testing on a preview, email, and what to check after the switch.

By Oxflare Engineering2 min read

Updated

Server rack illustration

Moving a website between hosts is routine for engineers but nerve-racking the first time. The key is to run the new site in parallel with the old one, test it thoroughly and only then point your domain at it.

1. Take inventory

List what you are moving: website files, databases, email accounts and messages, cron jobs, SSL certificates, DNS records and any special server settings such as PHP version or extensions.

2. Lower the DNS TTL

A day before the move, set the TTL on your A and MX records to 300 seconds. This makes the final switch take effect quickly.

3. Copy the site

Use a full account backup if both hosts use cPanel, or copy files over SFTP and export the database. For WordPress, a migration plugin or WP-CLI works well. Import everything into the new host.

4. Test on a preview

View the new copy without changing DNS, using a temporary URL or by editing your computer's hosts file. Click through key pages, submit forms, test checkout and log in to the admin area.

5. Freeze changes

For sites that take orders or comments, schedule a short content freeze, or plan a final database sync just before the switch.

6. Switch DNS

Update your A records (or nameservers) to point to the new host. With a low TTL, most visitors arrive at the new server within minutes.

7. Move email carefully

If email is moving too, copy mailboxes in advance, switch MX records, then run a final sync to catch messages that arrived during the change.

8. Check after the move

  • HTTPS works on every version of the domain.
  • Forms send email and payments complete.
  • Scheduled tasks are running.
  • Search Console shows no new crawl errors.

Keep the old hosting for a week before cancelling, in case you need to retrieve something. Or let our team do the whole thing for free with assisted migration.

Put it into practice

Our team can set this up for you, or answer any questions.