DNS Record Types Explained: A, AAAA, CNAME, MX and More

January 22, 2024

If you've ever managed a domain, you've probably seen a confusing list of record types. Let me clear things up.

A Records

The most common type. An A record points a domain to an IPv4 address (like 192.168.1.1). When someone visits your website, the A record tells them where to go.

AAAA Records

Same as A records, but for IPv6 addresses. These look like 2001:0db8:85a3:0000:0000:8a2e:0370:7334. As we run out of IPv4 addresses, AAAA records are becoming more important.

CNAME Records

CNAME stands for Canonical Name. It's basically an alias. Instead of pointing to an IP address, it points to another domain name. Super useful when you want www.example.com to go to the same place as example.com.

MX Records

MX stands for Mail Exchange. These tell email servers where to deliver mail for your domain. Without proper MX records, you won't receive emails.

TXT Records

These hold text information. They're used for all sorts of things - verifying domain ownership, email authentication (SPF, DKIM), and security policies.

NS Records

NS stands for Name Server. These records tell the internet which DNS servers are authoritative for your domain.

SOA Records

Start of Authority. Contains administrative information about your domain, like the primary nameserver and how often records should be refreshed.

PTR Records

The reverse of A records. Instead of domain to IP, they map IP to domain. Used mainly for email server verification.

Most of the time, you'll only deal with A, CNAME, and MX records. The others are usually set up once and forgotten.