Free email toolsOpen and check
MX lookup: who runs a domain's email
Type a domain or an email address to see its mail servers in priority order, its SPF and DMARC records in plain words, and which company actually holds the mailboxes.
Only the domain, the part after the @, is sent to Cloudflare's public DNS resolver (cloudflare-dns.com) to look it up. The rest of an address never leaves this page, and nothing you type is saved or counted.
What an MX record is
An MX (mail exchanger) record is a line in a domain's DNS that says which servers take its email. When someone writes to [email protected], their mail server asks DNS for example.com's MX records and hands the letter to the server named there. Each record holds two things: a priority number and a host name, like 10 mx.zoho.com.
MX records only cover mail coming in. They don't decide which server your mail app reads from or sends through (that's IMAP and SMTP, set in the app; see IMAP and SMTP settings). That split is why two companies can share one domain's mail: a filter like Proofpoint takes the letter first and passes it on to Microsoft 365, which holds the mailboxes.
How MX priority works
The number is a preference, and the lower one wins. RFC 5321, the standard for delivering mail, puts it plainly: "Lower numbers are more preferred than higher ones." A sender tries the lowest first and only moves down the list when that server doesn't answer. Zoho's records for a domain of your own show the pattern: mx.zoho.com at 10, mx2.zoho.com at 20, mx3.zoho.com at 50.
Records with the same number share the work. The RFC tells senders to pick among them at random, which is why iCloud lists mx01.mail.icloud.com and mx02.mail.icloud.com both at 10. The numbers mean nothing beyond their order, so 1, 5 and 10 behave exactly like 10, 50 and 100.
With no MX record at all, senders fall back to the domain's own address record and treat it as an MX at priority 0. RFC 5321 calls this the implicit MX. A website's server usually isn't set up to take mail, so in practice the letter bounces or waits in a sender's retry queue.
Check MX records in Terminal
A Mac already has the tools. Open Terminal (Applications › Utilities) and type:
dig MX fastmail.com +short
It prints one line per record, priority first. On my Mac today that gave:
10 in1-smtp.messagingengine.com. 20 in2-smtp.messagingengine.com.
dig, nslookup and host all live in /usr/bin; I checked on macOS 26.6, where dig reports version 9.10.6. The same question with the other two:
nslookup -type=mx fastmail.com host -t mx fastmail.com
SPF is a TXT record on the domain itself, and DMARC sits at a name of its own:
dig TXT example.com +short dig TXT _dmarc.example.com +short
Terminal asks whatever DNS server your Mac uses (your router, your internet provider, a VPN), while the tool above asks Cloudflare's. Both give the same records unless one is holding an older copy: every record carries a time to live, the time it "may be cached before the source of the information should again be consulted" (RFC 1035). So a change you just made can take that long to show up everywhere.
MX hostnames by provider
Each row comes from the provider's own setup page, or, where no page lists them, from the records of the provider's own domain, read on 19 November 2026. The tool matches on the end of the host name.
| Provider | MX hosts | Worth knowing |
|---|---|---|
| Gmail | gmail-smtp-in.l.google.com, then alt1 to alt4 | From gmail.com's own records |
| Google Workspace | smtp.google.com, priority 1 | Domains set up before 2023 may still use the older aspmx records, which Google still supports |
| Outlook.com, Hotmail | *.olc.protection.outlook.com | From outlook.com's and hotmail.com's own records |
| Microsoft 365 | <token>.mail.protection.outlook.com | Newer domains can get <token>.<sub>.mx.microsoft, signed with DNSSEC |
| Yahoo Mail, AOL Mail | *.yahoodns.net | From yahoo.com's and aol.com's own records |
| iCloud Mail and iCloud+ custom domains | mx01.mail.icloud.com, mx02.mail.icloud.com, both 10 | |
| Zoho Mail | mx.zoho.com 10, mx2.zoho.com 20, mx3.zoho.com 50 | The ending changes with the data centre: zoho.eu, zoho.in and so on |
| Yandex 360 | mx.yandex.net, 10 | |
| Fastmail | in1-smtp.messagingengine.com 10, in2-smtp.messagingengine.com 20 | Fastmail says these are the only two |
| Proton Mail | mail.protonmail.ch 10, mailsec.protonmail.ch 20 | |
| GoDaddy | smtp.secureserver.net 0, mailstore1.secureserver.net 10 | |
| IONOS | mx00.ionos.com, mx01.ionos.com | Older setups use the 1and1.com names |
| OVHcloud | mx0.mail.ovh.net 1, mx1 5, mx2 50, mx3 100, mx4 200 | For every OVHcloud email plan but Private and Dedicated Exchange |
| Gandi | spool.mail.gandi.net 10, fb.mail.gandi.net 50 | |
| Rackspace Email | mx1.emailsrvr.com 10, mx2.emailsrvr.com 20 | |
| Namecheap Private Email | mx1.privateemail.com, mx2.privateemail.com, both 10 | |
| Cloudflare Email Routing | route1, route2, route3.mx.cloudflare.net | Forwards mail to other addresses; priorities set by Cloudflare |
| Mimecast (filter) | Hosts under mimecast.com | mimecast.com's own records name service-alpha-inbound-a.mimecast.com |
| Proofpoint (filter) | *.pphosted.com; Essentials: *.ppe-hosted.com | proofpoint.com's own records use pphosted.com |
| Barracuda (filter) | *.ess.barracudanetworks.com |
Common problems
No MX records
The tool says so, and senders fall back to the implicit MX described above. The usual cause is a domain bought for a website whose email was never set up, or records lost while moving the domain's DNS to a new company. Your mail provider's setup page lists the records to add back.
A null MX: 0 .
One record with priority 0 and a single dot as the host is a deliberate "no mail here". RFC 7505 defines it so senders can bounce at once instead of retrying for days. example.com itself has one. If your own domain shows it and you expect mail, someone switched mail off at your DNS host.
Records from two providers
After a move from, say, GoDaddy to Google Workspace, the old records often stay next to the new ones. Senders use the lowest number that answers, so letters can keep landing in the old mailbox you no longer check. Delete the old provider's MX records once the new ones are in.
A filter in front of the mailbox
Schools and companies often put Proofpoint, Mimecast or Barracuda first, so the MX names the filter and says nothing about the mailbox behind it. The tool then looks at two more clues. Microsoft tells Microsoft 365 admins to point autodiscover.<domain> at autodiscover.outlook.com, so when that name is there the mailboxes are probably at Microsoft. Failing that, the SPF record often names the company that sends the domain's mail.
Two SPF records
A domain gets one SPF record. RFC 7208 says that with more than one, the check "produces the 'permerror' result", which means SPF fails for every letter. It happens when a second service's setup page says "add this TXT record" and someone adds it instead of merging it into the first. The tool flags it. SPF also allows only 10 DNS lookups in all (each include, a, mx and redirect counts one), and the tool counts the ones in the record itself.
How Roost uses MX records
Roost reads MX records for the same reason this page does. When you type an address in setup, it first checks the domain against the ones it knows by heart (gmail.com, icloud.com, outlook.com, zoho.com and others). For any other domain it asks DNS for the MX records and names the provider with the same patterns as the tool above: Google means Gmail's servers, Microsoft means Microsoft's sign-in, and a Zoho host also says which data centre to use.
When the MX names nobody it knows, Roost looks the domain up in Mozilla's public list of mail settings (the one Thunderbird uses), then the company behind the mail server. Next it checks whether autodiscover points at Microsoft, and only then asks Microsoft's sign-in whether the domain belongs to a Microsoft 365 school or company. If all of that comes up empty, it tries imap. plus your domain and shows the server fields when that fails. The order matters: Microsoft's sign-in recognises fastmail.com, so until Roost 1.4.1 read Fastmail's messagingengine.com hosts first, Fastmail addresses were labelled Microsoft 365.
In the app the lookup goes through your Mac's own DNS, not Cloudflare. The domain reaches Mozilla and Microsoft only in the steps above, as Where your mail goes lists. Setup for each provider, step by step, is on the Add an inbox pages.
Questions
What does this page send, and to whom?
Only the domain, to Cloudflare's public resolver (cloudflare-dns.com) over HTTPS, three or four times per lookup: for the MX records, the TXT records, _dmarc, and sometimes autodiscover. Cloudflare's privacy page for the resolver says it deletes its logs within 25 hours and doesn't write the asker's IP address to disk. Nothing goes to Roost, and the page keeps nothing.
Why does the lookup fail on my network?
Some networks block DNS over HTTPS, and then this page can't reach Cloudflare. dig MX yourdomain.com +short in Terminal still works there, because it uses ordinary DNS.
Can it check DKIM too?
No. A DKIM key lives at <selector>._domainkey.<domain>, and the selector is only written in a signed letter's DKIM-Signature header (the s= tag), so there's nothing to look up from the domain alone.
What do ~all and -all mean in SPF?
They say what to do with mail from servers the record doesn't list. -all is a fail: refuse it. ~all is a softfail: probably not allowed, so most receivers deliver it but trust it less. ?all is neutral, and a record with no all at all ends up neutral too.
Do MX records change which server I type into my mail app?
No. Mail apps use IMAP to read and SMTP to send, with their own server names. The IMAP and SMTP settings pages list them per provider.
Sources
- IETF, RFC 5321, section 5.1 (MX preference, equal preferences at random, the implicit MX), read 19 November 2026
- IETF, RFC 7505, A "Null MX" No Service Resource Record, read 19 November 2026
- IETF, RFC 1035, sections 3.2.1 (TTL) and 3.3.9 (MX), read 19 November 2026
- IETF, RFC 7208, SPF, sections 4.5, 4.6.2, 4.6.4 and 4.7, read 19 November 2026
- IETF, RFC 7489, DMARC, sections 6.3 and 6.6.3, read 19 November 2026
- IETF, RFC 6376, DKIM, sections 3.5 and 3.6.2.1, read 19 November 2026
- Google, Set up MX records for Google Workspace and Set up SPF, read 19 November 2026
- Microsoft, External Domain Name System records for Microsoft 365 and How SMTP DNS-based Authentication of Named Entities (DANE) works, read 19 November 2026
- Zoho, Configure email delivery (MX records), read 19 November 2026
- Yandex 360, MX record, read 19 November 2026
- Apple, Set up an existing domain with iCloud Mail, read 19 November 2026
- Fastmail, Domain set up: MX only, read 19 November 2026
- Proton, Set up a custom domain with Cloudflare, read 19 November 2026
- GoDaddy, DNS settings for Professional Email, read 19 November 2026
- IONOS, MX records for IONOS email, read 19 November 2026
- OVHcloud, Adding an MX record to your domain's configuration, read 19 November 2026
- Gandi, Why MX records have a priority (June 2021), read 19 November 2026
- Rackspace, DNS record definitions, read 19 November 2026
- Namecheap, Private Email records for domains with third-party DNS, read 19 November 2026
- Cloudflare, Email Routing DNS records and Email Routing, read 19 November 2026
- Proofpoint, Proofpoint Essentials getting started guide (PDF, 2016), read 19 November 2026
- Barracuda, How to set up MX records for domain verification, read 19 November 2026
- MX records of gmail.com, outlook.com, hotmail.com, yahoo.com, aol.com, mimecast.com, proofpoint.com and example.com, and Mozilla's autoconfig list at autoconfig.thunderbird.net, read through DNS and HTTPS on 19 November 2026
- Cloudflare, DNS over HTTPS: JSON format and 1.1.1.1 public DNS resolver privacy commitments, read 19 November 2026
- Roost's setup code:
ProviderDetector.swiftandMXLookup.swift, and its 1.4.1 release notes on the changelog