Email on aaPanel-setup, DNS records, and limitations
Running email on aaPanel requires a mail server, clean DNS, rDNS, port review, and deliverability planning.
On this page
Running email directly on a VPS is significantly more complex than running websites. Deliverability depends on IP reputation, correct DNS configuration, rDNS, port policy, abuse prevention, and proper server setup. Many UnderHost VPS customers are better served by an external email provider for business mail, while the VPS handles websites and applications.
Email on a VPS-what to know first
Email requires:
- A mail server (Postfix, Exim, or a full stack like Mail-in-a-Box)
- Port 25 availability for mail delivery-outbound mail may require UnderHost support review for spam prevention and abuse control
- A valid rDNS (PTR) record for your server IP-must match your mail server hostname
- Correct SPF, DKIM, and DMARC records
- An IP address with a clean reputation-new VPS IPs are sometimes pre-listed on spam databases
Even with all of these configured correctly, getting consistent deliverability to Gmail and Outlook inboxes from a new IP is challenging and takes weeks of "warming" (gradually increasing sending volume).
When to use external email instead
For most UnderHost VPS customers, external email is the better choice:
- Google Workspace or Microsoft 365-professional email with established deliverability, reliable spam protection, and easy client setup
- Zoho Mail-free tier available for small teams
- Migadu, Fastmail, or similar-privacy-focused alternatives
With external email, you simply update your domain's MX records to point to the provider, and they handle everything. No server-side email setup required.
Even if you run email on aaPanel for domain mailboxes, consider using an SMTP relay service (Mailgun, Postmark, SendGrid, or Amazon SES) for transactional emails sent by WordPress or your application. Relay services have much higher deliverability rates than a fresh VPS IP.
Install a mail server in aaPanel
If you need a self-hosted mail server, aaPanel's App Store includes mail server options:
- Go to aaPanel → App Store
- Search for Mail server or browse the Server category
- Install the available mail module (typically includes Postfix + Dovecot)
After installation, the mail server section appears in aaPanel's left sidebar. Configure domains, mailboxes, and aliases there.
Before enabling the mail server:
- Open an UnderHost support ticket for mail/port review and explain the legitimate sending use case, expected volume, domain, and abuse controls
- Ensure your server IP has a clean reputation using the UnderHost tools or another blacklist checker
Required DNS records
A self-hosted mail server requires these DNS records-all must be configured at your DNS provider:
| Record | Type | Name | Value |
|---|---|---|---|
| MX | MX | @ | mail.yourdomain.com (priority 10) |
| A (mail hostname) | A | mail | Your server IP |
| SPF | TXT | @ | v=spf1 mx ~all |
| DKIM | TXT | default._domainkey | DKIM public key from mail server |
| DMARC | TXT | _dmarc | v=DMARC1; p=quarantine; rua=mailto:dmarc@yourdomain.com |
| PTR / rDNS | PTR (set at VPS level) | Server IP | mail.yourdomain.com |
For rDNS (PTR record): this is set at the server level, not through your domain DNS provider. Request rDNS configuration through a UnderHost support ticket, specifying the IP and the hostname it should resolve to.
Transactional email from WordPress
WordPress sends emails for admin notifications, password resets, and contact form submissions. By default it uses PHP's mail() function, which often ends up in spam.
Configure WordPress to send via SMTP using a plugin (WP Mail SMTP, FluentSMTP):
- Install and activate WP Mail SMTP
- Configure it with your SMTP relay credentials (Mailgun, SendGrid, etc.)
- Test using the plugin's built-in email test feature
Deliverability checklist
- ☐ Port 25/mail sending reviewed with UnderHost support where required
- ☐ rDNS (PTR) record set to your mail hostname
- ☐ MX record pointing to your mail server
- ☐ SPF record published
- ☐ DKIM signing enabled and TXT record published
- ☐ DMARC policy published
- ☐ Server IP not on major blacklists
- ☐ SSL certificate valid for your mail hostname
- ☐ Sending low volumes initially to warm up the IP
Related: aaPanel DNS | aaPanel security | Email spam issues | SPF/DKIM/DMARC
Need aaPanel hosting?
Install aaPanel on an UnderHost VPS or dedicated server when you want a simple web interface for sites, databases, SSL, and apps.





















