site migration DNS email SEO 29 November 2026 6 min

When you move a site to new hosting, copying the files and the database is the easy part. Things go wrong elsewhere: email that disappears on switch day, pages that change their address and drop out of Google, DNS changed too early. Below is the order we follow for our own migrations. It works for WordPress, PrestaShop, a hand-built site or a custom app.

What do you need before you start?

  • access to the old hosting panel, or at least FTP and database access;
  • access to wherever the domain's DNS is managed (the registrar, Cloudflare or the old host);
  • a list of the mailboxes on the domain and their passwords, if email also lives at the old host;
  • a quiet day for the switch, not your busiest sales day of the month.

Step 1: lower the TTL a day ahead

The TTL tells internet providers how long to remember the site's old address. If it's set to 24 hours, some visitors will keep landing on the old server for a full day after the change. A day before, set the TTL of the A and MX records to 300 seconds (5 minutes). The next day, the switch spreads in minutes instead of hours.

Step 2: copy the site and test it on the new server

Copy the files and the database, then update the database credentials on the new server. Before touching DNS, open the site on the new server from your own computer through the hosts file: add a line with the new server's IP and the domain name. You see the new site exactly as visitors will, and nobody else notices anything. Check:

  • the home page, a product or article page and the contact form;
  • the admin login and a test order, if it's a shop;
  • images and uploaded files, which often go missing in the copy;
  • the PHP version, which should match or be compatible with the site.

Step 3: sort out email before DNS

This is where most things get lost. If email stays where it is (Gmail, Proton, Microsoft 365), leave the MX records alone and move only the site. If email was at the old host and moves too:

  • create the same mailboxes, with the same names, on the new server;
  • copy the old messages over IMAP, with a sync tool or from the new host's panel;
  • change the MX only once the new mailboxes exist, then sync once more to catch mail that arrived on the old server in the meantime.

Update the domain's SPF and DKIM records for the new mail server too. Without them, mail sent from the domain often lands in spam.

Step 4: switch the DNS

Point the A record (and AAAA, if there is one) to the new server's IP. With the TTL lowered in step 1, most visitors reach the new server within minutes. Install the SSL certificate right away so the site doesn't show an insecure connection warning. With Let's Encrypt, the certificate is issued a few minutes after the domain points to the new server.

Step 5: keep page addresses or add 301 redirects

Google remembers pages by their address. If a page moves from /product.php?id=12 to /products/running-shoes and there's no redirect, Google sees one page that vanished and a new one with no history. The old page's rankings are lost.

  • if the addresses stay the same, there is nothing to do;
  • if they change, list the old and new addresses and add a 301 redirect from each old one to its new one;
  • after the move, resubmit the sitemap in Google Search Console and watch the page report for 404 errors for a few days.

Step 6: don't cancel the old hosting right away

Keep the old account running for another week or two. If you forgot something, a mailbox, a file or a subdomain, you can still get it from there. Close it only after everything has worked on the new server for a few days.

Frequently asked questions

How long is the site down during a migration?

If you follow the steps above in order, practically not at all. The old site keeps running until you switch DNS, and the new one is already tested. For shops, pause orders for a few minutes while you copy the final version of the database, so an order placed at that exact moment isn't lost.

Will I lose Google rankings if I change hosts?

No, as long as page addresses stay the same and the site doesn't get slower. Google doesn't penalise a server change. Rankings drop when pages with traffic return 404 or the new site loads slowly.

Do I have to do all of this myself?

No. At BTU, migration is free when you move to us: we move the site, the database and the email, test everything on the new server and tell you exactly when to switch DNS. If you'd rather do it yourself on WordPress, the detailed steps are in our WordPress migration guide.

Ready to launch?

Web hosting on NVMe and LiteSpeed in the EU, cloud servers and dedicated servers in 118 cities, with support from real people.

See hosting plans See hosting plans

Already have a site somewhere else?

Send us the login details for your current host and we move the files, databases and email accounts. Moving is free with every hosting plan.