DNS record types explained: A, AAAA, MX and more
DNS resource records store information needed by a domain: addresses, mail servers, delegation and other service settings. Each record has a name, type, value and time to live (TTL) for caching. Different types answer different questions, so one domain can have several records for separate purposes.
Addresses and aliases
An A record maps a name to an IPv4 address; AAAA maps it to an IPv6 address. A CNAME record makes a name an alias for another name. A CNAME generally cannot coexist with other data for the same name under the DNS rules, so check your DNS provider’s requirements before adding one. An A record does not prove that a web server works, and no A record does not rule out access over IPv6. Publish an AAAA only when the service actually responds on IPv6.
Mail and delegation
An MX record names a mail exchanger and its preference; a smaller preference number is normally tried first. The exchanger’s name must resolve to an A or AAAA address, not necessarily both. When a domain has no MX, SMTP defines an implicit fallback to its A or AAAA address if present. This is described in RFC 5321. An NS record identifies authoritative nameservers for a zone or a delegation. SOA holds key zone parameters, including a serial number and timing values.
TXT, PTR and SRV
A TXT record stores text values and is often used in SPF policy or proof of domain control. DKIM and DMARC also use DNS, but they serve different authentication tasks; one TXT record does not replace their full setup. A PTR record supports reverse mapping from address to name: IPv4 uses in-addr.arpa, and IPv6 uses ip6.arpa. The owner of an address block or its operator commonly controls this reverse zone, so changing a normal domain’s DNS panel may not be enough. An SRV record locates a specific service, but its presence does not guarantee that service is healthy.
A migration example and checks
Suppose example.com has A and AAAA records for the website, while MX points to a separate mail host and www.example.com is an alias. Moving the website should not inadvertently change the MX records. Lower TTL in advance if you need cached answers to expire sooner; after changing addresses, compare answers from authoritative and recursive servers. Not all users will see a change simultaneously because applications and resolvers may cache data. If mail fails, inspect MX and the addresses to which it points. If the website fails, check the relevant A or AAAA response and then test the service itself. The core DNS record format is specified in RFC 1035.
