Configuring Business Email MX records correctly ensures your domain's email arrives at the right mail server. MX (Mail Exchanger) records are a crucial type of DNS record that specifies which mail servers are responsible for accepting email messages on behalf of a domain name and where to route those emails. By properly setting up these records, incoming emails for your domain, such as [email protected], will be directed to your chosen email hosting provider, whether it's Google Workspace, Microsoft 365, or a self-hosted solution.

This guide, updated for 2026, will walk you through the process, covering everything from understanding DNS propagation to implementing essential email authentication protocols like SPF, DKIM, and DMARC.

What Are MX Records and How Do They Work?

MX records are a fundamental component of the Domain Name System (DNS), specifically designed for email routing. When someone sends an email to an address at your domain, their mail server performs a DNS lookup to find the MX records associated with your domain. These records tell the sending server the hostname of the mail server that should receive the email and its priority.

Each MX record consists of two primary parts: a priority value and a mail server hostname. The priority value is an integer, typically ranging from 0 to 65535, with lower numbers indicating higher preference. If multiple MX records exist for a domain, the sending mail server will attempt to deliver the email to the server with the lowest priority value first. If that server is unavailable, it will then try the next lowest priority server, providing a basic level of redundancy for email delivery.

For instance, if your domain has two MX records, one with priority 10 pointing to mail.example.com and another with priority 20 pointing to backup.example.com, emails will first try to reach mail.example.com. Only if mail.example.com is unreachable will backup.example.com be attempted. This mechanism is defined in IETF RFC 5321, Section 5, which specifies the Simple Mail Transfer Protocol (SMTP).

Proper MX record configuration is the cornerstone of reliable email communication for any business. Misconfigured records can lead to lost emails, affecting client communication and internal operations.

You can query MX records using command-line tools like dig on Linux/macOS or nslookup on Windows. As of April 2026, these tools remain the standard for DNS diagnostics.

dig MX yourdomain.com +short

This command will return the MX records for yourdomain.com, showing their priority and target hostnames.

Prerequisites for Configuring MX Records

Before you begin configuring your MX records, ensure you have the following essential components in place:

  • Registered Domain Name: You must own a registered domain name (e.g., yourcompany.com) to which you can assign email services.
  • DNS Management Access: You need access to your domain's DNS management interface. This is typically provided by your domain registrar (e.g., GoDaddy, Namecheap, Cloudflare) or a dedicated DNS hosting service.
  • Email Hosting Provider: You must have an active account with an email hosting provider, such as Google Workspace, Microsoft 365, Zoho Mail, or a self-hosted mail server. Your provider will supply the specific MX record values you need to enter. Many hosting providers, including a managed email hosting provider like Valebyte, offer comprehensive solutions that simplify this setup.

Without these prerequisites, you won't be able to properly direct your domain's email traffic.

Step-by-Step Guide to Setting Up MX Records

Setting up MX records involves a series of precise steps to ensure correct email delivery. Follow these instructions carefully:

  1. Gather MX Record Details from Your Email Provider: Your email hosting provider (e.g., Google Workspace, Microsoft 365) will provide a list of specific MX records. These typically include hostnames (e.g., ASPMX.L.GOOGLE.COM) and corresponding priority values (e.g., 1, 5, 10). Make sure to copy these values accurately, as even a small typo can prevent email delivery. For example, Google Workspace provides a clear list of MX records for their service.
  2. Access Your DNS Management Interface: Log in to the control panel of your domain registrar or DNS hosting provider. Look for a section labeled 'DNS Management', 'DNS Settings', 'Zone Editor', or similar. This is where you will add, modify, or delete DNS records for your domain.
  3. Delete Existing MX Records (If Any): If your domain previously used another email service, there might be old MX records present. It's crucial to remove all existing MX records to avoid conflicts with your new configuration. Only after confirming all old records are gone should you proceed.
  4. Add New MX Records: For each MX record provided by your email host, you will create a new entry. The fields typically include:
    • Type: Select 'MX'.
    • Host/Name: Often leave this blank or enter @ for the root domain, or specify a subdomain (e.g., mail) if your provider requires it.
    • Value/Points To/Mail Server: Enter the mail server hostname provided by your email host (e.g., ASPMX.L.GOOGLE.COM).
    • Priority: Enter the numeric priority value (e.g., 1, 5, 10).
    • TTL (Time To Live): This specifies how long DNS resolvers should cache the record. A common value is 3600 seconds (1 hour). For initial setup, a shorter TTL (e.g., 300 seconds) can be useful for faster propagation, but remember to increase it later for better performance.
  5. Verify Propagation: After adding the records, it takes time for DNS changes to propagate across the internet. This propagation delay, known as TTL, can range from a few minutes to 48 hours, though typically it's much faster, often within an hour for common providers as of 2026-04. You can check the propagation status using online tools like What's My DNS or by using dig again.

Here's an example of what typical MX records might look like in a DNS zone file configuration, often managed through a web interface:

@     IN    MX    10  mail.yourdomain.com.    ; Primary mail server
@     IN    MX    20  backup.yourdomain.com.  ; Backup mail server

; For Google Workspace, it would look like:
@     IN    MX    1   ASPMX.L.GOOGLE.COM.
@     IN    MX    5   ALT1.ASPMX.L.GOOGLE.COM.
@     IN    MX    5   ALT2.ASPMX.L.GOOGLE.COM.
@     IN    MX    10  ALT3.ASPMX.L.GOOGLE.COM.
@     IN    MX    10  ALT4.ASPMX.L.GOOGLE.COM.

Understanding MX Record Priorities

The priority value assigned to each MX record is critical for reliable email delivery. When a sending mail server queries for MX records, it receives a list that often includes multiple entries. The server then attempts to connect to the mail server with the lowest priority number first. If that server is unreachable, busy, or rejects the connection for any reason, the sending server will try the next MX record in ascending order of priority.

This system allows for redundancy and load balancing. You can configure a primary mail server with a low priority (e.g., 10) and one or more backup servers with higher priorities (e.g., 20, 30). This ensures that if your primary mail server experiences downtime, incoming emails can still be delivered to a backup server, preventing mail loss. Many email providers, like Microsoft 365, provide multiple MX records with varying priorities to ensure high availability for their services.

Here is a comparison of how different priority settings can direct email flow:

PriorityHostnameFunctionBehavior
10mail1.example.comPrimary Mail ServerFirst attempt for email delivery.
20mail2.example.comSecondary Mail ServerAttempted if mail1 is unavailable.
30mail3.example.comTertiary Mail ServerAttempted if both mail1 and mail2 are unavailable.
100spambox.example.comLow-Priority Spam Catch-allOnly used if all higher-priority servers fail, often for filtering.

It's important to assign unique priority values to each MX record, even if they point to different servers from the same provider. This provides a clear order of preference for incoming mail.

Beyond MX: Essential Email Authentication Records

While MX records direct email, they don't prevent spoofing or spam. To enhance email deliverability, security, and sender reputation, you must configure additional DNS records: SPF, DKIM, and DMARC. These authentication mechanisms help receiving mail servers verify that emails originating from your domain are legitimate.

Sender Policy Framework (SPF)

SPF (Sender Policy Framework) is a DNS TXT record that specifies which mail servers are authorized to send email on behalf of your domain. When a mail server receives an email, it can check your domain's SPF record to verify if the sending IP address is listed as authorized. If it's not, the email might be marked as spam or rejected. SPF helps prevent email spoofing, where malicious actors send emails pretending to be from your domain.

An SPF record is published as a TXT record in your DNS. It typically starts with v=spf1 and includes mechanisms like include (to allow third-party senders, e.g., your email provider), ip4/ip6 (for specific IP addresses), and an all mechanism (~all for softfail, -all for hardfail). A common SPF record for a domain using Google Workspace might look like this:

yourdomain.com.   IN   TXT   "v=spf1 include:_spf.google.com ~all"

The _spf.google.com part tells receiving servers to also check Google's authorized sending IP addresses. The ~all indicates a softfail, meaning emails from unauthorized servers might be accepted but marked with a warning.

DomainKeys Identified Mail (DKIM)

DKIM (DomainKeys Identified Mail) provides a way to verify the authenticity of an email sender and ensure that the email content has not been tampered with in transit. It uses cryptographic signatures. When an email is sent, the sending server signs the email with a private key. The corresponding public key is published as a DNS TXT record for your domain. Receiving mail servers can then retrieve this public key to verify the email's signature.

DKIM records are usually long strings of characters generated by your email hosting provider. You'll typically add a TXT record for a specific subdomain, often prefixed with a