Move mail deliberately, not incidentally

Changing nameservers moves DNS for everything at once, including MX. If mailboxes have not been created on the new host first, mail bounces during the window.

The sequence that works

A safe order:

  • Copy files and database to the new host
  • Recreate every mailbox and forwarder
  • Test the site by hosts file
  • Lower DNS TTL a day ahead
  • Switch nameservers
  • Keep the old account for two weeks

Afterwards

Check SSL reissued, cron jobs recreated, and that the old server is not still receiving mail. Keeping the old account briefly costs little and has saved many migrations.