Moving email accounts in Addon Domains cPanel

Email accounts in addon domains

You can create email accounts for addon domains. To learn how to set up an email account for an addon domain, read our Email Accounts documentation.

When you remove the addon domain, is email accounts will no longer appear in the cPanel interface. However, the contents for this email account still exist in the home/username/mail directory.

If you add the domain back to the same account as the primary domain, an addon domain, or a parked domain, the email accounts will reappear in the cPanel interface.
If you move the domain to a different account, you must add the email accounts manually and move the contents of the email account manually. The email accounts must follow the same name and same domain format that they previously followed.
You can use the Email Accounts interface to add new accounts, or you can run the /scripts/addpop script to manually add new email accounts.
To move one email account under a domain, you can run the following command:


# mv /home/old_account/mail/domain_name/email_account /home/new_account/mail/domain_name/

After you run this command, the system creates the /home/new_account/mail/domain_name/ directory. To move all the email accounts under a domain, run the following command:


#mv /home/old_account/mail/domain_name /home/new_account/mail

After you move the files, run the following command to change the ownership of the new account:


# chown -R new_account:new_account /home/new_account/mail/domain_name

Leave a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.