Cleanbox
Features Blog Pricing Developers Tools
Sign in Start free trial

How to Look Up MX Records for Any Domain

How to Look Up MX Records for Any Domain

MX (Mail Exchange) records are DNS records that tell sending mail servers where to deliver email addressed to your domain. When someone sends an email to you@yourdomain.com, the sender's mail server queries your domain's MX records to find out which server accepts your email.

If your MX records are wrong, missing, or pointing to the wrong server, email to your domain will bounce or disappear. Checking your MX records is the first diagnostic step for almost any email delivery problem.

How to check MX records

Use the Cleanbox MX Lookup tool — enter any domain and see its MX records instantly, including priority values and the servers they point to.

You can also check from the command line:

dig MX yourdomain.com +short

Or on Windows:

nslookup -type=MX yourdomain.com

Reading MX record results

A typical MX lookup returns one or more records, each with a priority number and a mail server hostname:

10 mx1.yourmailprovider.com
20 mx2.yourmailprovider.com
FieldMeaning
Priority (10, 20)Lower numbers are tried first. If the primary server (10) is unavailable, the sender tries the secondary (20)
HostnameThe mail server that accepts email for your domain

What MX records look like for common providers

ProviderMX records
Google Workspace1 aspmx.l.google.com, 5 alt1.aspmx.l.google.com, etc.
Microsoft 3650 yourdomain-com.mail.protection.outlook.com
Fastmail10 in1-smtp.messagingengine.com, 20 in2-smtp.messagingengine.com
Zoho Mail10 mx.zoho.com, 20 mx2.zoho.com
ProtonMail10 mail.protonmail.ch, 20 mailsec.protonmail.ch

Common MX record problems

No MX records

If your domain has no MX records, sending servers fall back to the domain's A record (the web server IP). Most web servers are not configured to accept email, so the message bounces. The fix: add MX records pointing to your email provider.

MX pointing to an IP address

MX records must point to a hostname, not an IP address. 10 203.0.113.10 is invalid. Use 10 mail.yourdomain.com and create a separate A record for mail.yourdomain.com that resolves to the IP.

MX pointing to a CNAME

Technically, MX records should not point to a hostname that is itself a CNAME (alias). While many mail servers tolerate this, it violates the RFC and can cause intermittent delivery failures. Point your MX record directly to the final hostname.

Stale MX records after migration

When you switch email providers (e.g., from Google Workspace to Microsoft 365), you must update your MX records. Old records pointing to the previous provider mean email is delivered to a server that no longer has your mailboxes — messages bounce or disappear.

Missing secondary MX

Having only one MX record means a single server failure makes your domain unable to receive email. Most email providers give you at least two MX records (primary and backup). If yours only provides one, the risk is usually acceptable for small domains but problematic for business-critical email.

MX records and email security

MX records reveal your email infrastructure

Your MX records are public — anyone can query them. This tells attackers exactly which email platform you use, which informs targeted phishing and social engineering. This is not something you can prevent (email fundamentally requires public MX records), but it is something to be aware of.

MX gateway filtering

If you use an email security gateway like Cleanbox Relay, your MX records point to the security service instead of your mail server. The gateway filters incoming email and forwards clean messages to your actual mail server. This architecture means attackers cannot bypass the filter by connecting directly to your mail server — all email must pass through the MX gateway first.

Use the MX lookup tool to check whether your domain's MX records point to your mail server directly or through a filtering gateway.

Related tools

MX records are one piece of your domain's email configuration. For a complete picture:

  • MX Lookup — Find the mail servers for any domain
  • SPF Checker — Verify which servers are authorized to send for your domain
  • DKIM Checker — Validate your DKIM signing configuration
  • DMARC Lookup — Check your domain's spoofing protection policy
  • NS Lookup — Query nameservers and other DNS records for your domain

For more on how MX records fit into email infrastructure, see What Is an MX Relay and Why Your Domain Needs One and our complete guide to DNS for email.

Ready to take control of your inbox?

Start protecting your email with Cleanbox — free plan available, no credit card required.

Get started free