CyberPanel: email setup with SnappyMail

Create mail domains and email accounts in CyberPanel, publish MX, SPF and DKIM records, then sign in to the SnappyMail webmail client on your Linux VPS.

  • Intermediate
  • Linux VPS
  • 5 min read

By RunRacks Team · Published

CyberPanel email setup means three things: a mail domain that Postfix and Dovecot will accept mail for, DNS records that tell the world where that mail lives, and a mailbox you can actually log in to. This guide walks through all three on a Linux VPS, then shows you how to open SnappyMail, the webmail client that ships with CyberPanel, and how to point Outlook or a phone at the same mailbox.

The result is a working [email protected] address that sends and receives, with DKIM signing so your messages are less likely to land in spam.

Before you start

You need:

  • A Linux VPS with CyberPanel already installed and reachable at https://203.0.113.10:8090.
  • Root or admin access to CyberPanel, and SSH access to the server.
  • A domain whose DNS you control — either at your registrar or through CyberPanel's own DNS if the domain uses your server's nameservers.
  • Outbound TCP port 25 open. Many providers block it by default; check with your host before you spend time debugging mail that never leaves the server.
  • A reverse DNS (PTR) record for your server IP that matches your mail hostname. Ask your provider to set it if you cannot.

Create the mail domain

CyberPanel ties mail to a website entry, so create the site first if it does not exist.

  1. Log in to the CyberPanel dashboard at https://203.0.113.10:8090.
  2. Go to Websites → Create Website, enter example.com, choose a package, and submit.
  3. Go to Mail → Create Mail Domain, select example.com from the list, and click Create Mail Domain.

CyberPanel now writes the domain into the Postfix virtual mailbox maps and creates the Dovecot mail directory under /home/vmail/.

Next, issue a certificate for the mail hostname so webmail and IMAP run over TLS without browser warnings:

  1. Go to SSL → Manage SSL.
  2. Pick mail.example.com from the dropdown.
  3. Click Issue SSL.

Add MX, SPF, DKIM and DMARC records

Add these records at your DNS provider. Replace 203.0.113.10 with your server IP.

Text
mail.example.com.     A      203.0.113.10
example.com.          MX  10  mail.example.com.
example.com.          TXT     "v=spf1 mx a ip4:203.0.113.10 ~all"
_dmarc.example.com.   TXT     "v=DMARC1; p=none; rua=mailto:[email protected]"

Now generate the DKIM key inside CyberPanel:

  1. Go to Email → DKIM Manager.
  2. Select example.com and click Generate DKIM.
  3. Copy the selector name and the TXT value the panel shows you.

Publish that TXT record at your DNS provider. The host is usually <selector>._domainkey.example.com — use exactly the selector CyberPanel displays, because the selector name is part of the signature lookup.

Text
default._domainkey.example.com.  TXT  "v=DKIM1; k=rsa; p=MIGfMA0GCSq..."

Create email accounts

  1. Go to Mail → Create Email.
  2. Select the domain example.com.
  3. Enter the username deploy, a strong password, and a mailbox quota.
  4. Submit, then repeat for any other addresses you need.

The full address is [email protected]. CyberPanel stores the mailbox under /home/vmail/example.com/deploy/ if you need to inspect it over SSH.

Sign in to SnappyMail

SnappyMail is the webmail front end bundled with CyberPanel. Open it in one of two ways:

  • https://mail.example.com/snappymail once the mail domain certificate is issued.
  • https://203.0.113.10:8090/snappymail from the panel hostname.

Log in with the full address [email protected] and the mailbox password. The first login creates the SnappyMail account profile; you can change the display name and signature under Settings.

For a desktop client or phone, use these settings:

Text
IMAP server:  mail.example.com
IMAP port:    993  (SSL/TLS)
SMTP server:  mail.example.com
SMTP port:    587  (STARTTLS)
Username:     [email protected]
Password:     your mailbox password

Check it works

From SSH, confirm the records are live:

Terminal
dig +short MX example.com
dig +short TXT default._domainkey.example.com
dig +short TXT example.com

You should see your mail hostname, the DKIM public key, and the SPF string. Then check that the mail ports answer:

Terminal
openssl s_client -connect mail.example.com:993 -quiet

A TLS handshake without an error means Dovecot is listening.

Finally, send a test message from SnappyMail to an address you can check elsewhere, and reply to it. Open the received message headers and look for Authentication-Results containing dkim=pass and spf=pass. That is the real confirmation that CyberPanel email setup is complete.

Troubleshooting

  • SnappyMail says the login failed. The mailbox may not exist yet, or you typed the short username instead of the full address. Recreate the account under Mail → Create Email and log in as [email protected].
  • Mail sends but lands in spam. Usually a missing or mismatched DKIM record. Compare the selector in the panel with the DNS hostname character by character, and confirm your PTR record matches mail.example.com.
  • Messages never arrive at all. Check port 25 outbound with your provider, then read /var/log/mail.log for Connection refused or timed out lines.
  • Webmail shows a certificate warning. The certificate was issued for the panel hostname, not mail.example.com. Add the A record, wait for propagation, and re-issue SSL for the mail domain.
  • `dkim=temperror` in headers. The DKIM TXT record is missing or split incorrectly. Some DNS panels break long values into chunks — paste the whole string as one record.

Next steps

Was this guide helpful?

Still stuck?

Ask RunRacks AI for a quick answer, or open a ticket and our team will take a look at your server.

Control panels

CyberPanel: back up and restore a website

Create on-demand and scheduled website backups in CyberPanel, download the archives off the server, and restore a site from a backup when something breaks.

  • Intermediate
  • Linux VPS
  • 6 min read