
Changing hosting providers sounds risky, but most "migration disasters" come from doing the steps in the wrong order – switching DNS before the new server is ready, forgetting email, or losing the orders that came in during the move. This guide gives you the exact order that keeps a website online the whole time, for any cPanel-to-cPanel move and for WordPress, WooCommerce or custom PHP sites.
Screenshots are from a real cPanel account (Jupiter theme). Domain names and usernames are replaced with example values.
The zero-downtime idea in one paragraph
Your domain's DNS decides which server visitors reach. As long as DNS points to the old host, visitors see the old site – even while the new copy is being built. So you copy everything to the new host, test it there privately, and only then change DNS. If the DNS change spreads fast (low TTL), the switch happens within minutes and nobody notices.
Migration checklist (in order)
| When | Step |
|---|---|
| 2 days before | Inventory everything and lower the DNS TTL |
| Day of move | Back up files, databases and email from the old host |
| Day of move | Restore on the new host and fix configuration |
| Day of move | Test the new copy before DNS points to it |
| Switch time | Short content freeze, final database sync, change DNS |
| Next 7 days | Watch, fix leftovers, keep the old host as a fallback |
Step 1 – Make an inventory
Write down everything the old account does. The items people forget are the ones that break after the move:
- Domains: main domain, addon domains, subdomains and parked/alias domains (cPanel → Domains).
- Databases: every MySQL database and which site uses it (cPanel → MySQL Databases).
- Email: mailboxes, forwarders, autoresponders and filters – and whether email is hosted on the server at all or on Google Workspace / Microsoft 365.
- Cron jobs: scheduled tasks (cPanel → Cron Jobs) – backups, invoice reminders, feed imports.
- PHP version and settings: MultiPHP Manager and INI Editor values such as
memory_limitandupload_max_filesize. - DNS records: every record in the Zone Editor – especially MX, TXT (SPF, DKIM, Google/Microsoft verification) and any CNAMEs for third-party services.
- SSL: free AutoSSL or a paid certificate you need to re-install.
Step 2 – Lower the DNS TTL (24–48 hours before)
TTL ("time to live") tells resolvers how long to cache a DNS answer. Many zones use 14,400 seconds (4 hours) or even 86,400 (24 hours) – which means some visitors would keep reaching the old server for that long after you switch.
Wherever your DNS is managed (usually the old host's Zone Editor or your registrar), set the TTL of the A records for the domain and www – and the MX record if email moves too – to 300 seconds. Do it at least one full old-TTL period before the move so the short TTL is what resolvers have cached.
Step 3 – Back up the old account
Option A: Full cPanel backup (cPanel-to-cPanel, easiest)
If both hosts use cPanel, a full backup contains files, databases, email, DNS zones and settings in one archive. On the old host open cPanel → Backup → Download a Full Account Backup. The new host restores it with WHM's transfer tool – you cannot restore a full backup from inside cPanel yourself, so send it to your new provider's support (or ask them to pull the account directly from the old server, which is faster).
Option B: Partial backups (works everywhere)
Open cPanel → Backup Wizard → Back Up → Partial Backup:
- Home Directory – all website files.
- MySQL Databases – one
.sql.gzfile per database. - Email Forwarders & Filters – the configuration (mailbox contents are moved separately, see Step 6).
You can also export a single database in phpMyAdmin: select it, open Export, keep Quick and format SQL, and click Export.
Large site? Browser downloads of multi-gigabyte archives often fail. Ask the new host to transfer it server-to-server, or download over FTP/SFTP.
Step 4 – Restore on the new host
- Add the domain to the new cPanel account (main domain is set when the account is created; addon domains in cPanel → Domains).
- Upload the files into the domain's document root (usually
public_html) and extract them in File Manager. - Create the database and user with the Database Wizard, giving the user ALL PRIVILEGES. The account prefix is different on the new server, so the names will change – e.g.
olduser_shopbecomesnewuser_shop. - Import the database in phpMyAdmin → select the new database → Import → choose the
.sqlor.sql.gzfile. Files over the upload limit can be restored with Backup Wizard → Restore → MySQL Database instead. - Update the configuration with the new database name, user and password – for WordPress that is the database section of
wp-config.php; Laravel and other frameworks use the.envfile; custom PHP apps usually have aconfig.php. - Match the PHP version and the INI values from your inventory.
- Re-create cron jobs – remember the home path in each command changes to the new username.
Step 5 – Test before switching DNS
Never "test" by changing DNS. Instead, make your own computer see the new server:
- Hosts file: add a line with the new server's IP and your domain to your computer's hosts file (on Windows:
C:\Windows\System32\drivers\etc\hosts, edited as administrator; on macOS/Linux:/etc/hosts). Your browser now loads the new copy; everyone else still sees the old one. Remove the line after testing. - Or use the temporary preview URL your new host provides.
Click through the important pages, log in to the admin area, submit a contact form, place a test order and check images, uploads and HTTPS. If a page shows "Error establishing a database connection", the configuration in Step 4.5 doesn't match – see database connection errors in cPanel. A blank page or error 500 usually means a PHP version or extension difference – see fixing a 500 error.
Step 6 – Don't forget email
Email is the part most migrations get wrong.
- Email on Google Workspace or Microsoft 365? Then the mail itself doesn't move. Just copy the MX, SPF, DKIM and verification TXT records exactly into the new DNS zone.
- Email on the cPanel server? Create the same mailboxes (same addresses) on the new host before the switch. After DNS changes, new mail arrives at the new server; old messages can be copied with an IMAP migration tool or by connecting both accounts in an email client and dragging folders across.
- Set up SPF and DKIM on the new server (cPanel → Email Deliverability) so mail doesn't land in spam – details in cPanel email not sending.
Step 7 – The switch
- Content freeze: for shops, forums and anything with user activity, put the old site in maintenance mode for the last 15–30 minutes, or at least stop publishing.
- Final sync: export the database again from the old host and import it on the new one, so the last orders, comments and sign-ups are included. Copy any new uploads.
- Change DNS: either update the A records (and MX if needed) to the new IP, or change the domain's nameservers at the registrar to the new host's nameservers. With a 300-second TTL most visitors move within minutes; nameserver changes can take a few hours because the TLD's own caching applies.
- SSL: AutoSSL issues the certificate once DNS points to the new server; run it manually in cPanel → SSL/TLS Status to speed it up. Problems? See SSL not working.
Step 8 – After the move
- Keep the old hosting active for 7 days – a free fallback if something was missed.
- Check the old server's mailboxes once more for messages that arrived during propagation.
- Watch the error log and Google Search Console for 404s and crawl errors for a week.
- Raise the DNS TTL back to 3,600–14,400 seconds once everything is stable.
- Set up backups on the new host – see back up and restore in cPanel.
- Only then cancel the old plan – and download a final full backup first.
Does moving hosts hurt SEO?
Not if the domain and URLs stay the same. Google only sees a new IP address. What can hurt is downtime during the move, slower hosting, broken HTTPS or missing pages – which is exactly what the steps above prevent. A faster server often improves rankings because Core Web Vitals get better. If you also change the domain or URL structure, set up 301 redirects from every old URL to the new one.
Frequently asked questions
How long does a website migration take?
A typical WordPress or business site takes 1–3 hours of work. DNS propagation then takes from minutes (low TTL, A record change) to a few hours (nameserver change).
Can I migrate from a non-cPanel host (Plesk, DirectAdmin, a site builder)?
Yes, with the partial method: download the files and a database export, then import them as in Step 4. Website builders such as Wix or Squarespace don't export a working site – those need to be rebuilt, often in WordPress (see install WordPress in cPanel).
Will my email stop working during the move?
Not if you create the same mailboxes on the new server before changing MX/DNS and check the old mailboxes for a few days afterwards.
Can the new host do the migration for me?
Most good hosts can. A server-to-server cPanel transfer copies everything – files, databases, email and settings – with less risk than manual downloads.
Let us move it for you. XMart Host's team migrates cPanel accounts, WordPress sites and email for new customers – see hosting migration to XMart Host – onto fast cPanel hosting or a VPS for larger sites.
