Quick answer: DNS records tell the internet where your website and email live. A and AAAA point to your web server. CNAME makes one name an alias of another. MX says where email goes. TXT holds notes like SPF and site verification. NS says which company hosts all of these.
The records you will use most
A and AAAA: your website’s address
example.com. A 203.0.113.10
example.com. AAAA 2001:db8::10
A is for IPv4, AAAA for IPv6. AAAA is optional. Add it only if your host gives you an IPv6 address.
CNAME: an alias
www.example.com. CNAME example.com.
www now follows wherever example.com points. You still need a redirect so visitors end up on one version.
MX: where email goes
example.com. MX 10 mail.example.com.
example.com. MX 20 backup-mail.example.com.
The lowest number is tried first. An MX record must point to a host name, not an IP address and not a CNAME.
TXT: notes and proof
TXT records hold SPF, DKIM and DMARC for email, plus codes that prove you own the domain to Google, Microsoft and others. See our SPF, DKIM and DMARC guide.
NS: who runs your DNS
NS records name the servers that hold all your other records. You change them at your domain registrar. Important: if your NS records point to your host or to Cloudflare, edit your records there, not at the registrar.
CAA: who may issue certificates
example.com. CAA 0 issue "letsencrypt.org"
Optional. It stops other certificate companies from issuing certificates for your domain.
Rules that cause most DNS mistakes
- No CNAME on the root domain. A CNAME cannot share a name with other records, and the root always has NS and SOA records. Use an A record, or your DNS host’s ALIAS or “CNAME flattening” feature.
- Editing the wrong place. Check your NS records first. Changes only count where they point.
- Forgetting the TTL. TTL is how many seconds other servers may keep the old answer. Before a big change, lower it to 300 a day ahead.
- A trailing dot. In zone files,
mail.example.com.with a dot is a full name. Without it, some editors add your domain again.
How long do changes take?
Most changes show within the record’s TTL, often 1 to 4 hours. Nameserver changes can take 24 to 48 hours, because the servers for .com and other endings keep them longer.
Check it with our free tools: DNS Lookup · Email Checker · WHOIS Lookup