MX Record
An MX, or Mail Exchange, record identifies the mail servers responsible for receiving email for a domain.
MX records affect email delivery rather than ordinary website traffic.
What It Means in Practice
Suppose a business uses:
hello@example.comThe domain's MX records tell sending mail systems which provider should receive messages addressed to that domain.
Cloudflare's DNS setup documentation shows MX records alongside other email-related DNS records used to route and authenticate mail. Cloudflare's email DNS examples
Example
A simplified record might look like:
Type: MX
Name: example.com
Server: mail.example-provider.com
Priority: 10Several MX records can exist with different priorities.
MX Record vs. Website Hosting
Website hosting and email hosting are often completely separate.
For example:
A record
→ website host
MX record
→ email providerChanging website hosting should therefore not require changing MX records unless the email service is changing too.
Why It Matters
Accidentally deleting or changing MX records can interrupt incoming email even while the website continues to work normally.
This is one of the main risks when moving DNS providers or nameservers.
Related Email Records
Email configuration frequently also uses TXT Records for standards such as:
- SPF
- DKIM
- DMARC
Those records help with email authentication and anti-spoofing controls.
Common Problems
Common problems include:
- MX records lost during DNS migration
- Email assumed to be hosted with the website
- Old mail provider records left behind
- Incorrect priority
- New provider configured before old system migration is ready
- Testing only the website after a nameserver change
How to Improve
Before changing DNS or nameservers:
- Document current MX records
- Identify the email provider
- Record associated TXT records
- Verify the complete mail configuration at the new DNS provider
- Test incoming and outgoing email after the change