Skip to content

Moving a cPanel workload to a managed PaaS without a flag day

Move a busy site from cPanel to a managed PaaS in phases instead of one risky weekend. Split the move into separate tracks for the code, database, mail and files, then switch DNS once all of them are ready.

Moving a busy site from a cPanel server to a managed PaaS (platform as a service, where the provider runs the servers and you deploy the application) goes best as several smaller moves. A cPanel server keeps the code, the database, the mail and the uploaded files together on one machine, and the PaaS splits them apart. Each piece can move on its own, and each one costs something different if it goes wrong. Run the code, database, mail and files as four parallel tracks, then switch DNS to the new platform once, at the end, when all four are ready. That avoids a flag day, the single weekend when everything changes at once and any part can break.

What’s happening

A cPanel host bundles the app server, MySQL/MariaDB, Exim, the file system, and DNS into one IP. A managed PaaS unbundles them: the app server is an autoscaling container pool, the database is a separate cluster, mail is a third-party API, and persistent files live in object storage. The migration is not a copy — it is a rewrite of where each component lives, with the application’s configuration updated to match.

How to verify

On the cPanel source, capture the inventory:

du -sh /home/<user>/public_html
mysqldump --all-databases | wc -c
ls /home/<user>/mail | head
whmapi1 get_domain_info domain=example.com

On the PaaS destination, validate the targets exist:

# app container reaches the database
curl http://app:port/healthz
# object storage credentials work
mc ls s3/bucket
# DNS still authoritative for the source until cutover
dig @<src-ip> example.com SOA

The fix

  1. Database first — replicate the cPanel MySQL into the PaaS database as a follower, run the application against the cPanel primary, validate query patterns under load.
  2. Code path — push the application to the PaaS, point its config at the PaaS database, hit it via --resolve host header. Fix anything that assumed local file paths (/home/user/public_html).
  3. File storage — sync /home/<user>/public_html/uploads/ (or equivalent) to object storage on a 5-minute cron until cutover. Switch the application to read from object storage.
  4. Mail — if the cPanel host is the MX, this is the longest tail. Either keep cPanel as MX with the app pointing at the PaaS, or migrate mailboxes to a service like Google Workspace before flipping DNS.
  5. DNS cutover — once all four tracks are green, lower the TTL, flip the A record to the PaaS load balancer, watch traffic.

If you would rather not coordinate the four tracks yourself, see migration solutions and start a conversation.