| Type | Example | What it’s for |
|---|---|---|
SOA | @ IN SOA ns1.example.com. hostmaster.example.com. ( 2026111701 7200 3600 1209600 300 ) | One per zone, at the top. The main name server, the admin mailbox (its @ written as a dot), the serial, and the timers the other name servers follow. |
NS | @ IN NS ns1.example.com. | The zone’s name servers. Use at least two, ideally on different networks. |
A | www IN A 192.0.2.10 | An IPv4 address. |
AAAA | www IN AAAA 2001:db8::10 | An IPv6 address. |
CNAME | blog IN CNAME example.github.io. | “This name is really that name.” Nothing else can share the name, so the zone’s own name (@) can’t be a CNAME. |
MX | @ IN MX 10 mail.example.com. | Mail servers, lowest number tried first. Must name a host with its own A or AAAA record, never an IP address or a CNAME. |
TXT | @ IN TXT "v=spf1 mx -all" | SPF, DMARC, DKIM keys and site verification. Each quoted part holds at most 255 characters; write longer values as several quoted parts. |
SRV | _sip._tcp IN SRV 10 60 5060 sip.example.com. | Priority, weight, port and host for services like SIP, XMPP, LDAP and Active Directory. |
CAA | @ IN CAA 0 issue "letsencrypt.org" | Which certificate authorities may issue certificates for the domain. |
PTR | 10 IN PTR www.example.com. | Reverse lookups, in zones like 2.0.192.in-addr.arpa. |
mail.example.com becomes mail.example.com.example.com. Write mail or mail.example.com.@ means the zone’s own name. A line that starts with a space or tab belongs to the same name as the line above it.$TTL sets how long other servers may keep an answer, for every record that doesn’t give its own. Put it at the top.; starts a comment. Parentheses let one record run over several lines, as the SOA usually does.2026111701, then 2026111702 for a second change that day.nsupdate, DHCP or DNSSEC signing) has to be frozen before you edit the file: sudo rndc freeze example.com, edit, then sudo rndc thaw example.com. Otherwise BIND overwrites your changes.sudo cp /etc/bind/db.example.com /etc/bind/db.example.com.baksudo named-checkzone example.com /etc/bind/db.example.com. It prints OK and the new serial.sudo rndc reload example.com. If it doesn’t load, sudo journalctl -u named -n 50 says why. (Older Debian and Ubuntu call the service bind9.)dig @localhost www.example.com +short, then dig +nssearch example.com to see that every name server gives out the new serial.Paste a zone file and every problem is listed by line: the errors that make BIND refuse to load the zone, and the mistakes it accepts that still break lookups, such as a missing trailing dot that turns mail.example.com into mail.example.com.example.com. The checker was tested against BIND’s own named-checkzone. You also get the next serial number and the commands to check, load and confirm the zone on the server.
On the server, run sudo named-checkzone example.com /etc/bind/db.example.com. It prints OK and the serial, or the line BIND rejects. This page finds the same errors and adds the mistakes BIND accepts but that break lookups, such as a missing trailing dot or an MX record that points to a CNAME.
A name with a CNAME record can’t have any other record, and BIND refuses to load a zone that breaks this rule. Keep either the CNAME or the other records. The zone’s own name always has SOA and NS records, so it can never be a CNAME: give it A and AAAA records instead.
A name without one is relative, so the zone name is added to it. In example.com, mail.example.com becomes mail.example.com.example.com., which doesn’t exist. Write the full name with a dot at the end, mail.example.com., or just mail.
Any whole number up to 4294967295 that goes up every time the zone changes. Most people use the date plus two digits, like 2026111701. If the serial doesn’t go up, the other name servers keep the old copy. To push a zone to a secondary whatever its serial, run sudo rndc retransfer example.com on that secondary.
No. An MX record must name a host that has its own A or AAAA record. An IP address there is read as a host name and doesn’t work; a CNAME breaks the rules for mail (RFC 2181), and some mail servers won’t deliver to it. The same goes for NS and SRV records.
Related tools: DNS Propagation Checker · Email DNS Generator (SPF, DKIM, DMARC) · All tools A–Z
Most tools run entirely in your browser. Tools marked 📡 contact outside services, as listed in the Privacy Policy. Review commands before you run them; see the Terms.