What is an MX record?
Mail Exchanger (MX) records tell the world which mail servers accept incoming mail for your domain and where emails sent to your domain should be routed to. You can send emails without the MX record configured for your domain name, but if the MX record is not set up correctly, you will not receive email.
MX record format
A typical MX record looks like the following in standard BIND format:
$ORIGIN example.com. @ 3600 IN MX 10 mx1.dynu.com. @ 3600 IN MX 20 mx2.dynu.com.An anatomy of the MX Record
@ 3600 IN MX 10 mx1.dynu.com.looks like the below:
|Host Label||TTL||Record Class||Record Type||Priority||Mail Server Host|
It defines the hostname of a record and whether the hostname will be appended to the label. Fully qualified hostnames terminated by a period will not append the origin.
The time-to-live in seconds. It specifies how long a resolver is supposed to cache or remember the DNS query before the query expires and a new one needs to be done.
Mainly 3 classes of DNS records exist:
- IN (Internet) – default and generally what internet uses.
- CH (Chaosnet) – used for querying DNS server versions.
- HS (Hesiod) – uses DNS functionality to provide access to databases of information that change infrequently.
The record format is defined using this field. Common record types are A, AAAA, CNAME, CAA, TXT etc. In the case of an MX record, the record type is MX.
An integer that represents the priority for an email server. If you have only one mails server, the priority can be set to any integer between 0 and 65535. The preference is used when you have more than one mail server for any single domain name. In this case, the priority indicates the order in which the mail servers should be used. The lower preference number is the higher priority. Two MX records with the same priority will share the load. The server with the higher preference number will be used only if the servers with lower preference number are unavailable, which makes the server with the higher preference number a backup mail server.
Mail Server Host
The domain name of the email server. Specify the name (such as mail.example.com) of an A or AAAA record. The domain name cannot point to a CNAME record.
How to add an MX record?
For instructions on how to add an MX record with us, you may refer to the tutorial here.
MX record glossary
An MX (mail exchange) record is an entry in your DNS zone file which specifies a mail server to handle a domain's email. You must configure an MX record to receive emails to your domain.
Berkeley Internet Name Daemon - is the most commonly used DNS software on the Internet and Dynu observes BIND format.
A preference number that helps computers decide which server to send mail to if there are multiple mail servers defined. Lower numbers have a higher priority.