DNS-only mode, shown as a grey cloud in the Cloudflare dashboard, means Cloudflare only answers DNS queries for that record and returns your server’s real IP address. Visitors then connect straight to your cPanel server. Proxied mode, the orange cloud, returns Cloudflare’s own addresses instead: visitors connect to Cloudflare, and Cloudflare connects to your server. The proxy only carries web traffic on a fixed list of HTTP and HTTPS ports. On a cPanel server, that means mail hostnames and FTP must always be DNS-only, while your website’s hostnames can be either. Most of the odd behaviour after moving a cPanel domain to Cloudflare, such as bounced mail or failed certificate renewals, comes from records that were proxied by accident.
Proxied vs DNS-only at a glance
| DNS-only (grey cloud) | Proxied (orange cloud) | |
|---|---|---|
| What a DNS lookup returns | Your server’s IP | Cloudflare’s IPs |
| Who visitors connect to | Your cPanel server | Cloudflare, which then connects to your server |
| Ports that work | All of them | HTTP and HTTPS on Cloudflare’s supported ports only |
| Caching, WAF and DDoS protection for the site | No | Yes |
| Visitor IP your server sees | The visitor’s | Cloudflare’s, until you restore the real IP |
| Right for | Mail, FTP, SSH and other non-web services | Website hostnames such as example.com and www |
Cloudflare’s network ports reference lists the ports its proxy handles: 80, 8080, 8880, 2052, 2082, 2086 and 2095 for HTTP, and 443, 2053, 2083, 2087, 2096 and 8443 for HTTPS. Anything else sent to a proxied hostname, such as SMTP on port 25, IMAP or FTP, does not reach your server.
Which cPanel records go where
- Always DNS-only:
mail.example.com, every hostname an MX record points to, the SMTP and IMAP hostnames your mail clients use,ftp.example.com, and the server’s own hostname. - Your choice:
example.comandwww.example.com. Proxy them if you want Cloudflare’s caching and WAF (web application firewall). Leave them DNS-only if you only want Cloudflare as your DNS host. - Usually DNS-only:
cpanel,whm,webmail,cpcalendarsandcpcontacts. Ports 2083 and 2087 are on Cloudflare’s list, so these names can technically be proxied. Left DNS-only, cPanel’s own login protection keeps seeing your real IP address instead of a Cloudflare one.
Watch for one trap. An MX record points to a hostname, and that hostname must not be proxied. If your MX points at example.com itself and you proxy example.com, incoming mail breaks. Point the MX at a separate mail.example.com record that stays DNS-only.
How to check each record
Look up each hostname and compare the answer with your server’s IP:
dig +short www.example.com
dig +short mail.example.com
dig +short MX example.com
Example output for a zone where www is proxied and mail is not. The cPanel server here is 203.0.113.10:
104.21.48.7
172.67.160.12
203.0.113.10
10 mail.example.com.
The first two addresses belong to Cloudflare, so www is proxied. mail.example.com returns the server’s own IP, so it is DNS-only, as it should be. Cloudflare publishes its address ranges at cloudflare.com/ips if you need to confirm who owns an address. If a mail or FTP hostname returns a Cloudflare address, switch that record to DNS-only.
Certificates: AutoSSL behind a proxied record
AutoSSL proves that you control a domain either by serving a file over HTTP or by checking a DNS record. Both checks can fail with Cloudflare in front:
- HTTP check: with the record proxied, the request passes through Cloudflare first. A redirect at Cloudflare, such as the one Always Use HTTPS adds, can make the check fail.
- DNS check: when your zone is hosted at Cloudflare, cPanel cannot create the TXT record this check needs, because cPanel no longer controls the zone.
Read the result for the domain under WHM » SSL/TLS » Manage AutoSSL, on the Logs tab. If validation is failing, the simplest fix is to set the web records to DNS-only, run AutoSSL, and turn the proxy back on once the certificate is installed. For a site that stays proxied for good, another option is a Cloudflare Origin CA certificate on the cPanel server, which Cloudflare trusts in Full (strict) mode. Browsers do not trust Origin CA certificates, so a hostname that uses one must stay proxied.
When you do proxy the website
- Set the SSL/TLS mode to Full (strict). Flexible mode connects from Cloudflare to your server over plain HTTP, so that leg is unencrypted, and it often causes redirect loops on sites that force HTTPS. See fixing the Flexible SSL redirect loop.
- Restore the visitor’s IP on the server. Every connection now comes from a Cloudflare address, so logs, rate limits and security tools see Cloudflare instead of the visitor. Configure Apache’s
mod_remoteipor Nginx’s realip module to read theCF-Connecting-IPheader, as shown in real client IP behind Cloudflare on cPanel. - Do not count on the proxy to hide your server. Your mail and FTP records are DNS-only, and on most cPanel servers they point to the same IP as the website. Proxying hides that address only from lookups of the website’s own hostnames.
If this is the kind of work you’d rather never own again, it’s the daily job of Managed Cloud Ops — book an infrastructure review.