Blog
How to configure MX records in Cloudflare
Reviewed by the Free Domain Mail editorial team · Updated
Cloudflare can be the authoritative DNS provider while a separate mail service receives messages. MX records must remain DNS-only and match the mail provider exactly.
Confirm Cloudflare is authoritative
Compare the domain's public NS answers with the nameservers shown in Cloudflare. If they differ, edit the authoritative provider instead.
Open DNS > Records and record the existing MX set before making a change.
Add the provider MX values
Choose MX, use @ for the zone apex, enter the full mail-server target and the supplied priority. Cloudflare does not proxy MX records.
Add the complete priority set. Lower numeric values are attempted first; do not invent a backup target.
Validate before removing old routing
Run MX Lookup from outside Cloudflare and send an external test message. Wait for the previous TTL where answers differ.
After inbound delivery is confirmed, validate SPF, DKIM and DMARC for outbound identity.
Common mistakes to avoid
- Adding the domain twice in the Name field.
- Removing old MX before the new provider accepts mail.
- Confusing Cloudflare Email Routing with mailbox storage.
Frequently asked questions
Should the cloud icon be orange?
No. Email DNS records are not proxied through Cloudflare's HTTP proxy.
Can Cloudflare MX coexist with website records?
Yes. A/AAAA/CNAME website records and email MX/TXT records serve separate protocols.
Technical references
Primary specifications and provider documentation relevant to this guide: