How to mx records for a domain

Content on WhatAnswers is provided "as is" for informational purposes. While we strive for accuracy, we make no guarantees. Content is AI-assisted and should not be used as professional advice.

Last updated: April 4, 2026

Quick Answer: MX (Mail Exchanger) records specify which mail servers are responsible for accepting email messages on behalf of a domain. To set them up, you need to access your domain registrar's or DNS hosting provider's control panel and add or modify MX records, typically pointing to your email service provider's mail servers.

Key Facts

What are MX Records?

MX records, short for Mail Exchanger records, are a type of DNS (Domain Name System) record that specifies the mail servers responsible for receiving email on behalf of a domain name. When someone sends an email to an address at your domain (e.g., you@yourdomain.com), their email server queries the DNS for your domain's MX records to find out where to deliver the message.

Why are MX Records Important?

Without correctly configured MX records, email servers won't know where to send emails addressed to your domain. This means that any emails sent to your domain will either bounce back to the sender with an error or simply get lost. They are fundamental to the functioning of any email service associated with a custom domain.

How Do MX Records Work?

MX records contain two main pieces of information:

For example, a typical set of MX records might look like this:

In this example, mail.yourdomain.com is the primary mail server (priority 10), and backupmail.yourdomain.com is a secondary server (priority 20) that will only be used if the primary server is down.

How to Set Up or Change MX Records

The process for setting up or changing MX records typically involves logging into the control panel provided by your domain registrar (where you purchased your domain name) or your DNS hosting provider (if you manage your DNS separately). The exact steps can vary depending on the provider, but the general process is as follows:

1. Access Your DNS Management Interface

Log in to your account with your domain registrar or DNS host. Look for a section labeled 'DNS Management,' 'Zone Editor,' 'Advanced DNS Settings,' or something similar.

2. Locate MX Records

Within the DNS management interface, find the section for managing DNS records. You'll need to add or edit MX records.

3. Enter the MX Record Details

You will typically need to provide the following information for each MX record:

You will likely need to add multiple MX records if your email provider offers backup mail servers.

4. Save Your Changes

Once you have entered all the necessary MX records, save the changes. Your DNS provider will then update the DNS records for your domain.

5. Wait for DNS Propagation

DNS changes are not instantaneous. It can take anywhere from a few minutes to 48 hours for the changes to propagate across the global DNS network. During this time, some email might still be routed according to the old records, while other email might be routed according to the new ones.

Where to Find MX Record Information

The specific MX record values (priority and hostnames) are provided by your email service provider. Common examples include:

Troubleshooting Common Issues

Correctly configured MX records are essential for reliable email communication for your domain.

Sources

  1. MX record - WikipediaCC-BY-SA-4.0
  2. MX records - Google Workspace Admin Helpfair-use
  3. Create DNS records at any DNS hosting provider for Microsoft 365fair-use

Missing an answer?

Suggest a question and we'll generate an answer for it.