What is an MX record in DNS?

Back to blog overview
Posted on 2025-08-19

Without MX records, your business email would never reach its destination – it’s the map that guides every message to the right mail server.

 

What is an MX record

An MX record (mail exchanger record) is a DNS record that directs email to the mail servers responsible for receiving messages on behalf of your domain. Every domain that transports email must have at least one MX record configured – without it, senders have no way to know where to deliver your messages.

 

MX records work with priority values to provide redundancy. Each record gets a number (typically 10, 20, 30), where lower values indicate higher priority. This system ensures email delivery continues even if your primary mail server goes offline.

 

Here's what an actual MX record looks like:

 

Crucially, MX records point to hostnames, not IP addresses. The hostname then resolves to an IP address through a separate A or AAAA record. This separation between email routing and web hosting means you can host your website with one provider while using completely different servers for email – a flexibility that MX records make possible.

 

The complete DNS lookup sequence follows this path: Domain → MX record → A record → IP address. Here's a typical configuration with multiple MX records:

  • dnsense.io. IN MX 10 mx1.google.com.
  • dnsense.io. IN MX 20 mx2.google.com.
  • dnsense.io. IN MX 30 mx3.google.com.

 

When mail servers encounter equal priority values, they randomly distribute connections between those servers, effectively load balancing incoming email. MX record TTL values control how long this information stays cached, affecting how quickly changes propagate across the internet.

 

Common MX record configurations

Small businesses often start with a single mail server setup, though this lacks redundancy. Most organizations quickly move to multiple mail servers with staggered priority levels. Third-party email providers like Google Workspace and Microsoft 365 provide their own MX record sets, handling all the complexity of redundancy and scaling. Some companies add backup MX servers specifically for disaster recovery, queuing messages when primary servers are offline.

 

Warning: Never point MX records directly to IP addresses – always use hostnames. Direct IP configuration breaks many email standards and often results in delivery failures.

 

For high-volume senders, equal priority values across multiple servers provide automatic load balancing without complex configuration.

 

MX record best practices

Aim to always configure multiple MX records for redundancy – single points of failure in email routing cost businesses thousands per hour. Set appropriate priority gaps (10, 20, 30) to clearly define server preference. Verify that your SPF and DKIM records align with your MX configuration to prevent authentication failures.

 

Always test email delivery immediately after making changes. Monitor the blacklist status of all mail servers in your MX records, as one blacklisted server can impact your entire email reputation.

 

Essential email DNS records checklist:

  • MX records for mail routing
  • SPF for sender verification
  • DKIM for message signing
  • DMARC for policy enforcement

 

Simplify your email management

Managing MX records across multiple domains and email providers can quickly become a puzzle. Different providers require specific configurations, priority settings vary, and one mistake can mean lost emails.

 

When you're maintaining email routing for dozens of domains across various registrars and hosting providers, centralized DNS management isn't just convenient – it's essential for business continuity.

 

Questions about MX records or email routing? Contact our team – we aim to help businesses ensure reliable email delivery every day.