Key takeaways:
- MX records act like email traffic guides. They make sure every message reaches the correct mail server without delays or errors.
- Backups and priorities keep mail moving, even if one server is offline.
- A quick check of your MX setup avoids problems and helps your messages land where they should.
Ever wondered what an MX record is and how it powers your inbox?
Think of it as a GPS that tells every email which mail server to reach. Without the right setup, email delivery goes off course.
In this guide, we’ll explain how MX records work, why they matter for email delivery, and when you might need to check or update them.
What is an MX record?
An MX record (mail exchange record) is a DNS entry that tells email servers which mail server should receive emails for your domain.
An MX record is part of the DNS system that enables smooth mail delivery. When someone sends an email, the sender’s server performs a DNS query to find the domain’s MX records. These records list mail servers by priority, so the server with the lowest number is used first.
If the primary server is down, backup servers take over automatically. Valid MX records must point to A or AAAA record, not CNAMEs, to properly resolve to an IP address.
How MX records work
Every time you hit “Send,” email servers follow a precise chain of steps to make sure your message reaches the right inbox. Here’s how it works:
- The sender’s system starts the process by preparing the message for transfer using the Simple Mail Transfer Protocol or SMTP connection.
- A DNS query checks the domain’s DNS records to find the correct MX record and its associated mail server.
- If multiple MX entries exist, the one with the lowest number is tried first. Backup servers, often linked to alternate IP addresses, act as fallbacks to keep mail delivery smooth.
- The chosen mail exchange server receives and processes the email, sending it to the correct destination.
Quick analogy: Think of MX records as traffic signs directing cars (emails) to the right building (email servers) without getting lost.
MX record example
Seeing MX records in action makes them easier to understand. Below are simple setups showing how email servers are defined in DNS records for a domain.
Scenario 1: Primary and backup mail servers
This setup uses two MX records with different priorities to support failover. The server with the lower number gets used first, while the higher one acts as a backup.
Table of MX record values:
Domain | Priority | Mail Server | TTL |
example.com | 10 | mail1.example.com | 3600 |
example.com | 20 | backupmail.example.com | 3600 |
Zone file snippet:
- The server with priority 10 is the main server, and priority 20 is the backup.
- These servers are connected to IP addresses through A or AAAA (IPv6) records.
Together, these settings show how MX records control email flow. A main server handles most messages, while backup servers help keep things running smoothly, even if one server fails.
Scenario 2: Load balancing with equal priority values
This setup uses two MX records with the same priority to evenly distribute mail traffic. DNS may direct emails to either server, helping balance the load.
Table of MX record values:
Domain | Priority | Mail Server | TTL |
example.com | 15 | mail1.example.com | 3600 |
example.com | 15 | mail2.example.com | 3600 |
Zone file snippet:
- Both servers use the same priority value (15), which means DNS treats them equally.
- Incoming emails may be routed to either server, depending on availability or load.
- This setup supports load balancing and helps distribute traffic and reduce the chance of server overload.
With this configuration, mail delivery becomes more reliable, especially when email volume is high or one server experiences delays.
Why MX record priority matters
Priority values in your DNS MX records determine which preferred mail server is used first. A lower priority number (e.g., 10) means that server gets the first shot to handle inbound mail. If it’s unavailable, the system moves on to the next one with a higher number (e.g., 20), acting as a backup mail server.
- Think of it like race participants: the server tagged with 10 always tries first; if it’s down, the one with 20 takes over.
- Multiple entries with the same priority create a round-robin setup, distributing email load evenly across servers. This load balancing boosts reliability and performance.
- Properly set priority levels build redundancy and keep the mail flow consistent. This is necessary for uninterrupted email delivery.
It’s common to assign MX priorities in clean intervals like 5 or 10 to keep things organized and easy to manage. This doesn’t guarantee failover, but it can help route emails to a backup server if the main one isn’t working.
Pro tip: Always double-check your DNS settings and consult your provider if you’re unsure. To avoid delivery issues, assign the lowest value to the most preferred server.
What are MX records used for?
Email systems rely on MX records for smooth delivery and reliable backups. Let’s look at most common ways MX records are used:
- Business email hosting. An MX record routes messages through reliable mail servers linked to your domain, helping businesses maintain professional communication.
- Backup servers and failover. Using multiple MX records ensures that if the main server goes down, a backup server will handle mail traffic seamlessly.
- Cloud services and security. Platforms like Google Workspace rely on DNS MX record setups to manage email servers, spam filters, and delivery paths.
- Load distribution. Round robin configuration allows several MX records with equal priority to split incoming traffic across servers, reducing downtime.
- IP-based routing. MX records link to IP addresses to make sure emails always land on the correct server.
These use cases show how MX records keep email traffic stable, secure, and always on track.
Common MX record mistakes
Incorrect MX record settings can lead to delivery failures or delays. Below are common mistakes and how to fix them:
Mistake | How to fix it |
Pointing MX to a CNAME | MX records must point to an A or AAAA record. Update it to the correct record type. |
Incorrect priority numbers | Assign the lowest number to your primary mail server, and higher numbers to backups. |
TTL misconfigurations | Choose an appropriate TTL value to avoid slow propagation and delays in updates. |
Missing or outdated MX records | Double-check your DNS settings and make sure the mail server addresses are current. |
Pro tip: Keep your MX setup clean and consistent. Test every change to make sure email delivery stays smooth.
How to find your MX records
You can check your DNS MX records using an online tool, the command line, or through the Network Solutions Dashboard. Here’s how:
Using an online MX record lookup tool
- Go to MXToolbox.
- In the search bar, type your domain name (e.g., example.com).
- Select MX Lookup and hit Enter.
- Review the results to see your MX records, mail servers, and priority values.
Using the nslookup command
- Open your terminal or command prompt.
- Type the following and press Enter:
- You’ll see the domain’s MX record entries and mail exchanger hostnames.
Using the Network Solutions Dashboard
- Log in to your Network Solutions account.
- Go to the Manage Advanced DNS Records section.
- Click Advanced DNS Manager.
- View or edit your MX records to confirm accuracy or make changes as needed.
Ensure smooth email delivery with Network Solutions
MX records keep your emails on track by directing them to the right mail servers. Network Solutions simplifies DNS MX record management with Google Workspace integration, secure professional email hosting, and built-in tools to maintain smooth communication for your business.
Discover our guides on email hosting and domain management and DNS setup for step‑by‑step help.
Frequently asked questions
If an MX record is missing, mail servers won’t know where to route emails for your domain. Without this DNS MX record, messages can bounce back or fail to reach the inbox.
An MX record directs emails to the correct mail server, while other DNS records like A or CNAME handle website traffic or IP mapping. MX records are only for email routing.
An MX record for Gmail routes emails through Google’s mail servers using Google Workspace. It uses the SMTP connection protocol to make sure messages reach the Gmail inbox.
No, MX records must point to an A or AAAA record, not a CNAME. Using a CNAME can break email routing and cause delivery failures.