cPanel to HestiaCP: what the importer really does.
HestiaCP ships a script called v-import-cpanel. It works, it is poorly documented, and its own source lists two things it cannot do. This is the page I wanted the first time I ran it on a customer's account: the exact command, what lands, what does not, and how to check the result before DNS moves.
Run it as root on the HestiaCP server, against a full cPanel backup — the gzip tarball from cPanel's Backup Wizard, or the output of pkgacct. The script checks the file really is gzip and stops if it is not, so a partial or renamed file is caught before anything is created.
- One tarball, one account. The script creates a Hestia user with the cPanel account's username. It refuses if that user already exists.
- Then it restores files, databases, mail, domains and cron, in that order, fixing ownership as it goes.
- Optional second argument rewrites the MX records to point at the new server. Without it, DNS is left alone.
It needs rsync and file installed on the Hestia box. Both are in Hestia's own install instructions, so they are usually there already.
# import one account, leave DNS alone v-import-cpanel /backup/cpuser.tar.gz # import and rewrite MX to this server v-import-cpanel /backup/cpuser.tar.gz yes
What actually lands.
Read from the script rather than from a feature list. The third column is the part that decides whether the site works when you open it.
| What | Where it lands | Watch for |
|---|---|---|
| Files | public_html for the main domain, each addon and each subdomain | Copied with rsync, then ownership is reassigned to the new user |
| Databases | MariaDB, with users and their original passwords | A database that already exists is skipped, not merged. MySQL 8 collations are rewritten for MariaDB |
| Maildirs, plus password hashes read from cPanel's shadow file | Gzipped messages are decompressed as they land; the domain is rebuilt afterwards | |
| Domains | Main domain, addons and subdomains; parked domains become aliases | DNS records are only touched for MX, and only with yes |
| Cron | Each job, with cPanel's ea-php paths rewritten to /usr/bin/phpX.Y | Jobs calling a binary you have not installed still fail, quietly |
| PHP version | Mapped to a matching PHP-x_y template | If that version is not installed here, the script warns and the site may not load |
Five things it will not do for you.
Two of these are in the script's own header comment. The rest are behaviour you meet an hour in, on a live account, if nobody told you.
Six checks on the test account.
Do these before you change a nameserver, not after the customer emails you.
- Open the site over HTTPS. Confirm the certificate is one you issued here, not the old one cached in the browser, and that the document root is the account's own directory.
- Send and receive. One message in, one out, to an outside address. Then read the headers and check SPF, DKIM and DMARC all pass for the sending domain — the keys are new, so this is a real test.
- Check MX. If you passed
yes, read what was written. If you did not, set it yourself and confirm every sending domain points at the same place. - Read the cron jobs. The script rewrites PHP paths but cannot know whether the rest of the command still makes sense on this server.
- Check the PHP version per domain. A site that ran on 8.3 and lands on 7.4 will fail in ways the error log explains better than the page does.
- Grep the config for old paths. Anything with an absolute path to the old home directory — cache directories, upload paths, mail spool — needs updating.
Doing it without a second outage.
The importer is one step. The sequence around it is what decides whether the customer notices anything.
- Turn off database prefixing before the backup. It is a cPanel setting, changeable while the account is live, and leaving it on means the import stops at the first line.
- Import while the old server is still serving. Nothing in the script touches the source. The account exists twice for a while, which is the point.
- Test on the new IP first. A hosts-file entry pointed at the new address is a full test — HTTPS aside — before any resolver sees it. Fix the site here, not after cutover.
- Lower the TTLs a day earlier. If the zone is still on cPanel's nameservers, you are changing records you do not control yet; do the TTL drop before the move, not during it.
- Move web, then mail. Certificates need public DNS, so they follow the A records. Mail is safer last: keep MX on the old server until the new one sends and receives cleanly, then switch and watch the queue drain.
- Keep the old server for a week. The script never deletes anything, which makes the old box your rollback. Cancelling it on the day of the move throws that away.
Where HestiaCP is the right answer.
This site sells a different panel, so read this part as the reason not to switch rather than the reason to.
- It is small and quiet. A Hestia box with a handful of sites uses very little memory, and the interface is close to the VestaCP one a lot of hosts already know.
- It runs on more than two operating systems. If your fleet is on older Debian or Ubuntu releases, HestiaCP will meet you there; KarnakPanel installs on Ubuntu 24.04 and Debian 13 only.
- The importer is honest. A script that refuses rather than half-guesses is easier to work with than a tidy progress bar that silently drops a database.
The three that come up first.
Short answers.
Can I import more than one account at a time?
Not with v-import-cpanel. It takes one tarball per run and creates one user. For a batch you are scripting the loop yourself, and staging the backups somewhere with room for them.
Will the customer's SSL certificate come across?
Do not plan on it. The script attempts it and its own header lists the attempt as a known failure. Issue a new certificate after DNS points at the new server — that is a few minutes with Let's Encrypt, and it removes a whole class of "why does Chrome warn" tickets.
What about the mail passwords?
They come across: the script reads the hashes from cPanel's shadow file rather than resetting every mailbox. If a hash is missing, it warns per account, and that mailbox needs a new password set by hand.