DomainLens

Lernen

DNS Record Types Explained: A, AAAA, CNAME, MX, TXT and the Rest

A DNS zone is a lookup table. Each record type answers one question about a name, and most confusion comes from expecting a type to answer a question it was never designed for.

Prüfe deine Website vor den Fixes

Starte ein frisches DomainLens-Audit und nutze den Report als Prioritätenliste.

Kostenloses SEO-Audit starten

DNS records explained in one table

Every record maps a name to a value, and the type says what kind of question the value answers. Nine types cover almost everything you will meet.

TypeAnswersExample value
AWhich IPv4 address serves this name203.0.113.10
AAAAWhich IPv6 address serves this name2001:db8::1
CNAMEThis name is an alias for another nametarget.example.net.
MXWhich servers accept mail for this domain10 mail.example.com.
TXTArbitrary text, used for verification and policyv=spf1 include:_spf.google.com ~all
NSWhich nameservers are authoritative for this zonens1.example-dns.com.
PTRWhich name belongs to this IP addressmail.example.com.
CAAWhich authorities may issue certificates0 issue "letsencrypt.org"
SOAAdministrative metadata for the zonens1.example.com. admin.example.com. …

A and AAAA: the address records

A and AAAA are the same idea in two address families. An A record points a hostname at an IPv4 address; AAAA points it at an IPv6 address. A name can carry several of each, and resolvers will hand out different ones — that is the simplest form of load distribution DNS offers.

Publishing only A is entirely normal and costs nothing in search. IPv6 is optional, and crawlers reach IPv4-only hosts without difficulty.

Address records in zone-file form
example.com.        3600  IN  A     203.0.113.10
example.com.        3600  IN  AAAA  2001:db8::1
www.example.com.    3600  IN  A     203.0.113.10

; name              TTL   class type  value
; The trailing dot matters: it marks a fully
; qualified name. Without it, the zone's own
; domain is appended.

CNAME: an alias, with one hard rule

A CNAME says "this name is really that name" — the resolver restarts its lookup at the target. It is the right choice for pointing a subdomain at a service whose address you do not control and should not hardcode.

The rule people hit is that a name with a CNAME may hold no other records. That makes a CNAME impossible at the zone apex, because the apex must carry NS and SOA. Providers work around this with ALIAS or ANAME records, which behave like a CNAME but resolve server-side and so leave the apex free of the conflict.

Valid and invalid CNAME use
; Fine — a subdomain aliasing a service
shop.example.com.   3600  IN  CNAME  shops.myprovider.net.

; Invalid — the apex already needs NS and SOA
example.com.        3600  IN  CNAME  target.example.net.

; The workaround most providers offer
example.com.        3600  IN  ALIAS  target.example.net.

MX and TXT: mail and everything else

MX records name the servers that accept mail for a domain, each with a preference number where lower wins. The number is a priority, not a weight — the second entry is a fallback, not a share of the traffic.

TXT is the catch-all. It carries no fixed meaning, which is exactly why it ended up hosting domain verification, SPF, DKIM and DMARC. The type does not validate the content: a malformed SPF record is a perfectly valid TXT record, which is why these fail silently.

Mail and text records
example.com.        3600  IN  MX   10 mail1.example.com.
example.com.        3600  IN  MX   20 mail2.example.com.

; SPF lives in a TXT record at the apex
example.com.        3600  IN  TXT  "v=spf1 include:_spf.google.com ~all"

; DMARC lives on its own subdomain
_dmarc.example.com. 3600  IN  TXT  "v=DMARC1; p=none; rua=mailto:d@example.com"

The types you meet less often

The one worth adding deliberately is CAA: it takes one line and removes a whole class of misissuance risk. To see what a domain currently publishes, run it through the DNS checker .

  • NS delegates a zone to its authoritative nameservers. Change these and you have moved the whole zone.
  • PTR maps an IP back to a name. It lives in the reverse zone, which your hosting provider usually controls rather than you.
  • CAA lists which certificate authorities may issue for the domain — a cheap way to stop misissuance.
  • SOA holds the zone's serial number and timing values, including the negative-caching TTL that decides how long a "does not exist" answer sticks.
  • SRV points at a service on a specific host and port, used by autodiscover and similar protocols.

How DomainLens contributes

DomainLens reports the records a domain publishes as part of every audit, so a missing address record or absent mail authentication shows up beside the on-page findings. For why a change has not taken effect yet see DNS propagation , for the alias question see CNAME vs A record , and for the mail records see SPF, DKIM and DMARC .

What is the difference between an A record and a CNAME?
An A record points a name at an IP address directly. A CNAME points a name at another name, and the resolver looks that up in turn. Use A when you control the address, CNAME when you point at a service that manages its own.
Why can I not put a CNAME on my root domain?
Because a name with a CNAME may hold no other records, and the root must carry NS and SOA. Providers offer ALIAS or ANAME records that achieve the same result without the conflict.
Do DNS records affect SEO directly?
Only in the sense that a name which does not resolve cannot be crawled at all. Beyond reachability, Google does not read your zone as a ranking input.
How many TXT records can a domain have?
As many as you like, and multiple TXT records at one name are normal. The exception is SPF: exactly one SPF record is allowed, and publishing two invalidates both.

Prüfe das auf deiner Website

Ähnliche Ressourcen