DNS Record Types: Complete Reference, IANA Type Codes, and Lookup Tools

DNS resource records (RRs) are typed text instructions stored inside an authoritative DNS zone file that tell recursive resolvers how to route web traffic, deliver email, and verify domain cryptographic keys. Each record type carries a numeric IANA code. The 13 core types govern routing, email, security, and lookups.

All 13 DNS Resource Record Types by IANA Code

Every entry in a BIND zone file or DNS control panel belongs to a standardized resource record type defined by the Internet Assigned Numbers Authority (IANA). Modern production domains rely on 12 official wire record types plus virtual apex alias records (ALIAS and ANAME), although dozens of experimental or retired record types exist in historical RFCs. An asterisk owner name creates the catch-all form of any of these records, and the Wildcard DNS tester shows how RFC 4592 matching treats it. The table below compares all 13 DNS record types by decimal type code, value format, root-domain (@) compatibility, and core function.

Record Type IANA Type Code Value / RDATA Format Allowed at Root (@)? Core Infrastructure Function
A Type 1 32-bit IPv4 address (93.184.216.34) Yes Maps a domain or subdomain to an IPv4 server address.
AAAA Type 28 128-bit IPv6 address (2606:4700:4700::1111) Yes Maps a domain or subdomain to an IPv6 server address.
CNAME Type 5 Target domain name (example.com.) No (Conflicts with SOA/NS) Points an alias subdomain (www) to a canonical target hostname.
ALIAS / ANAME Virtual (Type 1/28) Target domain name (app.paas.com.) Yes (Synthesizes A/AAAA) Points the root domain (@) to a hostname by resolving IPs at the edge.
MX Type 15 Priority integer + Mail host (10 smtp.google.com.) Yes Directs incoming domain email to authorized mail servers by priority.
TXT Type 16 Quoted text string (<= 255 chars per chunk) Yes Stores machine-readable SPF, DKIM, DMARC, and site-verification strings.
NS Type 2 Nameserver FQDN (ada.ns.cloudflare.com.) Yes (Mandatory, 2+ min) Declares which authoritative DNS servers hold the master zone file.
SOA Type 6 MNAME, RNAME, Serial, and 4 timers Yes (Mandatory, exactly 1) Defines primary zone authority, serial version, refresh, and NXDOMAIN TTL.
PTR Type 12 Canonical hostname (mail.example.com.) Published in .arpa zones Maps an IPv4 or IPv6 address back to a hostname (Reverse DNS / rDNS).
SRV Type 33 Priority, Weight, Port, Target Published at _service._proto Discovers hostnames and TCP/UDP port numbers for VoIP, Teams, and games.
CAA Type 257 Flags (0/128), Tag, CA Value Yes (Inherits to subdomains) Restricts which Certificate Authorities are allowed to issue SSL/TLS certs.
DS Type 43 Key Tag, Algorithm, Digest Type, Digest Published in parent TLD zone Stores the SHA-256 hash of your child KSK at the registrar for DNSSEC.
DNSKEY Type 48 Flags (256/257), Protocol 3, Alg, Key Yes Publishes the public ZSK and KSK cryptographic keys inside your zone.

Use Section 1 below for web routing and alias records (A, AAAA, CNAME, ALIAS, PTR, SRV), Section 2 for email and zone authority records (MX, TXT, NS, SOA), Section 3 for cryptographic security records (CAA, DS, DNSKEY), and Section 4 to run live browser-based lookups for any record type.

1. Address, Alias, Reverse DNS, and Service Routing Records (A, AAAA, CNAME, ALIAS, PTR, SRV)

Seven guides cover the records that connect hostnames to IPv4 and IPv6 addresses, alias subdomains and root domains to cloud targets, resolve IP addresses backward to hostnames, and locate custom TCP/UDP application ports. Choose a record guide below to view its syntax, rules, and examples:

2. Email Routing, Text Verification, and Zone Authority Records (MX, TXT, NS, SOA)

Seven guides explain the administrative records that control domain authority, inbound mail routing, and sender verification. Select a guide below for syntax rules, priority numbers, and zone timer values:

3. Certificate Authorization and DNSSEC Cryptographic Records (CAA, DS, DNSKEY)

Four guides detail the cryptographic DNS records that restrict which Certificate Authorities are allowed to issue SSL/TLS certificates for your domain (CAA) and link your signed child zone (DNSKEY) to the parent TLD registry (DS). Open a guide below to harden your zone:

4. Live Browser-Based DNS Record Lookup Tools (All 13 Lookups)

Query any DNS record type in real time directly from your browser over encrypted DNS-over-HTTPS (Cloudflare 1.1.1.1, Google 8.8.8.8, and AliDNS 223.5.5.5) with zero server logging. Select the all-in-one lookup tool or a dedicated single-record checker below:

Every resource record guide and live lookup tool in this DNS Record Types guide helps you configure IPv4 and IPv6 routing (A, AAAA, CNAME, ALIAS), authenticate domain email (MX, TXT), manage zone authority (NS, SOA, PTR, SRV), and enforce cryptographic security (CAA, DS, DNSKEY).

Frequently Asked Questions

Which DNS record types are mandatory in every DNS zone file? ▾

Every valid DNS zone file requires two mandatory administrative record types at the root (@): exactly one SOA (Start of Authority) record and at least two NS (Nameserver) records. All other record types (A, AAAA, CNAME, MX, TXT, CAA) are added based on whether the domain hosts a website or sends email.

Can a CNAME record coexist with other DNS records on the same hostname? ▾

No, a CNAME record never coexists with any other record type on the exact same hostname under RFC 1034 and RFC 2181. Publishing a CNAME at the root apex violates the DNS specification and breaks email delivery because the root domain (@) always contains mandatory SOA and NS records alongside MX and TXT records. Use an ALIAS, ANAME, or Cloudflare CNAME Flattening record at the root domain instead.

What is the difference between an A record, a CNAME record, and an MX record? ▾

In practice, these three records handle the three core jobs of an everyday domain: an A record points a hostname directly to a numerical IPv4 address (93.184.216.34) to load a website; a CNAME record points a subdomain (www.example.com) to another domain name (example.com); and an MX record tells mail servers where to deliver incoming email addressed to @example.com.

Why don't my subdomain records (_dmarc, DKIM, or SRV) show up when I query my root domain? ▾

In real-world troubleshooting, DNS lookups only return records attached to the exact hostname label you query; there is no "list all subdomains" query in public DNS. To see a DMARC, DKIM, or SRV record, you must query its specific prefix hostname (such as _dmarc.example.com, selector1._domainkey.example.com, or _sip._tls.example.com).