MX Record
Definition
MX Record: A Mail Exchanger (MX) record is a type of DNS record that specifies which mail servers are responsible for receiving email on behalf of a domain, directing incoming mail to the correct server and enabling priority-based failover when multiple servers are configured.
What is an MX Record?
An MX (Mail Exchanger) record is a DNS record that tells the world which servers handle email for your domain. When someone sends an email to john@yourdomain.com, their email server does not magically know where to deliver it. Instead, it looks up your domain's MX records to find the address of your mail servers. Without MX records, your domain cannot receive email at all.
MX records are essential infrastructure for any domain used for email. Whether you use Google Workspace, Microsoft 365, or your own mail server, the MX records tell senders where to deliver mail. They are separate from sending email - you can have a domain that sends but cannot receive if MX records are not configured.
How MX Records Work
The email delivery process using MX records:
- Sender composes email - User writes to john@yourdomain.com
- Sender's server queries DNS - Looks up MX records for yourdomain.com
- DNS returns MX records - Lists mail server(s) and priorities
- Sender connects to mail server - Uses highest priority (lowest number) server first
- Email delivered - Sender's server hands off the message
- Failover if needed - If primary fails, tries next priority server
MX Record Structure
An MX record has two key components:
- Priority - A number indicating preference (lower = higher priority)
- Mail Server - The hostname of the server that receives email
Example MX records for a domain using Google Workspace:
yourdomain.com MX 1 aspmx.l.google.com
yourdomain.com MX 5 alt1.aspmx.l.google.com
yourdomain.com MX 5 alt2.aspmx.l.google.com
yourdomain.com MX 10 alt3.aspmx.l.google.com
In this example, senders try aspmx.l.google.com (priority 1) first. If it is unavailable, they try either alt1 or alt2 (both priority 5), then alt3 (priority 10) as a final backup.
Common MX Configurations
Different email providers require different MX records:
Google Workspace:
- Primary: aspmx.l.google.com (priority 1)
- Alternates at priorities 5, 5, 10, 10
Microsoft 365:
- Single record: yourdomain-com.mail.protection.outlook.com
- The exact hostname varies by tenant
Zoho Mail:
- mx.zoho.com, mx2.zoho.com, mx3.zoho.com
MX Records vs Other DNS Records
MX records are part of a larger DNS ecosystem:
- MX Records - Tell where to deliver incoming email
- A Records - Map domain names to IP addresses
- SPF Records - Specify authorized sending servers (TXT record)
- DKIM Records - Contain public keys for email signing (TXT record)
- DMARC Records - Define authentication policy (TXT record)
MX records are for receiving email. SPF, DKIM, and DMARC are for authenticating sent email. All work together but serve different purposes.
Do You Need MX Records to Send Email?
No - MX records are only for receiving email. You can send email from a domain without MX records, though this is unusual. However, lacking MX records can cause deliverability issues:
- Some spam filters check if the sending domain can receive mail
- Reply-to addresses will not work if MX records are missing
- Appears suspicious to have sending-only domain
Best practice is to have MX records configured for any domain you send email from.
Common MX Record Issues
Problems that can occur with MX records:
- Missing MX records - Domain cannot receive any email
- Wrong priority numbers - Traffic goes to backup instead of primary
- Typo in server hostname - Delivery fails entirely
- Stale records after migration - Old provider still receiving mail
- TTL too long - Changes take hours or days to propagate
Common Misconceptions
Many believe MX records affect email sending - they do not; MX is only for receiving. Others think changing MX records is instant - but DNS propagation can take hours depending on TTL settings. A dangerous misconception is that MX records alone enable email - you also need a functioning mail server at the specified hostname.
WarmySender works with any email provider (Gmail, Outlook, custom SMTP) regardless of your MX configuration. However, for complete email functionality, ensure your domains have proper MX records alongside authentication records for sending.
Frequently Asked Questions
Do I need an MX record to send email?
No - MX records only control incoming email delivery. You can technically send email from a domain without MX records. However, best practice is to have MX records configured because: (1) Some spam filters check if sending domains can receive mail, (2) Reply-to addresses need working MX to receive responses, (3) Sending-only domains appear suspicious. Configure MX records for any domain you send email from.
How do I check my MX records?
Use MXToolbox.com (free) - enter your domain and it shows all MX records with priorities. Alternatively, use command line: 'nslookup -type=mx yourdomain.com' on Windows or 'dig mx yourdomain.com' on Mac/Linux. Your DNS provider's dashboard also shows current records. If MX records are missing, check your email provider's documentation for the correct values to add.
How long do MX record changes take to propagate?
MX record changes typically propagate within 1-4 hours, though it can take up to 48 hours for worldwide propagation. The time depends on your TTL (Time To Live) setting - lower TTL means faster propagation. Before changing MX records (like when switching email providers), lower TTL to 300-600 seconds a day before the change, make the change, then restore normal TTL after confirming everything works.