DNS Record Types & Configuration Directory

Developer guide to DNS record types (A, CNAME, MX, TXT, SPF, DKIM, DMARC, CAA, NS). Inspect zone file syntax, copy dig / nslookup terminal commands, and review configuration best practices.

Showing 14 of 14 DNS Record TypesClick any record for syntax, TTL guides & lookup commands
A RecordRFC 1035

A Record (IPv4 Address)

Maps a human-readable domain name directly to a 32-bit IPv4 address (e.g. 192.0.2.1).

Terminal Query:
dig +short A example.com
AAAA RecordRFC 3596

AAAA Record (IPv6 Address / Quad-A)

Maps a domain name to a 128-bit IPv6 address (e.g. 2001:0db8:85a3:0000:0000:8a2e:0370:7334).

Terminal Query:
dig +short AAAA example.com
CNAME RecordRFC 1035

CNAME Record (Canonical Name / Alias)

Creates an alias pointing one domain or subdomain to another domain name.

Terminal Query:
dig +short CNAME www.example.com
ALIAS RecordProvider-specific (RFC Draft)

ALIAS / ANAME Record (Virtual Apex CNAME)

A virtual DNS record that allows CNAME-like behavior at the root domain apex without violating RFC 1035.

Terminal Query:
dig +short A example.com # Resolves dynamically to target IP
MX RecordRFC 5321

MX Record (Mail Exchange)

Specifies the mail servers responsible for accepting incoming email messages on behalf of the domain.

Terminal Query:
dig +short MX example.com
TXT RecordRFC 1035

TXT Record (Text / Arbitrary Data)

Carries arbitrary machine-readable or human-readable text associated with a domain.

Terminal Query:
dig +short TXT example.com
SPF RecordRFC 7208

SPF Record (Sender Policy Framework TXT)

A TXT record that defines which mail servers and IP addresses are authorized to send email on behalf of your domain.

Terminal Query:
dig +short TXT example.com | grep "v=spf1"
DKIM RecordRFC 6376

DKIM Record (DomainKeys Identified Mail TXT)

Publishes a cryptographic public key in DNS used to verify that an email message was signed by the domain and not tampered with in transit.

Terminal Query:
dig +short TXT google._domainkey.example.com
DMARC RecordRFC 7489

DMARC Record (Domain-based Message Authentication TXT)

Instructs receiving mail servers what action to take (none, quarantine, or reject) if an email fails both SPF and DKIM checks.

Terminal Query:
dig +short TXT _dmarc.example.com
CAA RecordRFC 8659

CAA Record (Certification Authority Authorization)

Specifies which Certificate Authorities (CAs) are permitted to issue TLS/SSL certificates for your domain.

Terminal Query:
dig +short CAA example.com
PTR RecordRFC 1035

PTR Record (Pointer / Reverse DNS)

Resolves an IP address back to its canonical domain name (Reverse DNS / rDNS lookup).

Terminal Query:
dig +short -x 192.0.2.1
NS RecordRFC 1035

NS Record (Name Server)

Delegates a DNS zone to use specific authoritative nameservers.

Terminal Query:
dig +short NS example.com
SRV RecordRFC 2782

SRV Record (Service Locator)

Defines the location (hostname and port number) of servers for specific protocols like SIP, XMPP, or LDAP.

Terminal Query:
dig +short SRV _sip._tcp.example.com
SOA RecordRFC 1035

SOA Record (Start of Authority)

Specifies authoritative core parameters for the DNS zone including serial number, primary nameserver, and administrator email.

Terminal Query:
dig +short SOA example.com