DNS Zone File Editor
Parse a BIND zone into an editable record table, catch mistakes and export valid zone syntax with TXT chunking.
Zone file
23 lines · 914 charsBIND syntax only. The file never leaves this tab; clear the draft to remove it from this browser.
Records & validation
13 records · 0 errors · 0 warnings| Owner | TTL | Type | Rdata |
|---|---|---|---|
| — | SOA | ns1.example.com. hostmaster.example.com. 2026010101 7200 3600 1209600 3600 | |
| — | NS | ns1.example.com. | |
| — | NS | ns2.example.com. | |
| — | A | 192.0.2.53 | |
| — | A | 192.0.2.54 | |
| — | A | 192.0.2.10 | |
| — | A | 192.0.2.10 | |
| — | A | 192.0.2.11 | |
| — | A | 192.0.2.25 | |
| — | MX | 10 mail.example.com. | |
| — | SRV | 0 5 5060 sip.example.com. | |
| — | TXT | v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghij (2 chunks) | |
| — | TXT | v=spf1 a mx -all |
SOA serial helper
The date in the serial is in the past: use today's date, revision 01.
Examples
Sticky owner and relative names
$ORIGIN example.com.
$TTL 3600
@ IN A 192.0.2.10
IN A 192.0.2.11@ A 192.0.2.10
@ A 192.0.2.11The indented second line inherits the apex owner; the two A records form a round-robin set.
DKIM TXT chunking
selector._domainkey IN TXT "<more than 255 octets>"selector._domainkey IN TXT ( "<255 octets>"
"<remaining octets>" )Chunking counts UTF-8 octets, not characters, and the chunks concatenate back to the original value.
Serial bump
2026010101 (dated in the past)2026112701 (today + revision 01)Date-style serials use YYYYMMDDNN: a past date resets to today at 01; the same date increments NN.
About this tool
The DNS Zone File Editor turns a BIND zone file into an editable record table. It parses directives, parenthesised SOA blocks, quoted TXT strings and blank owners, then re-serialises the result as valid zone syntax. Every step runs in your browser tab: no DNS queries, no uploads, no account.
Validation covers the mistakes that make zone edits fail after propagation: exact duplicate records, CNAME coexisting with other data at the same owner, MX/NS/SRV targets that point at aliases, malformed IPv4 and IPv6 addresses, SOA serial and timer problems, TTL anomalies, relative names with no $ORIGIN, and missing apex NS records. Findings name the affected row so you can jump straight to it.
Export is canonical and deliberately conservative. SOA and NS records come first, the rest are sorted by name and type, names are written relative to $ORIGIN where possible, and explicit TTLs appear only when they differ from $TTL. Long TXT values are split into quoted character-strings of at most 255 octets — the unit that RFC 1035 actually limits — so DKIM and SPF records survive the round trip. Comments remain attached to their records instead of disappearing.
What this tool does not do
- BIND master-file syntax only; tinydns and Windows DNS exports are not native formats, though BOM and CRLF are handled.
- No live DNS resolution is performed and the tool does not check whether referenced hosts actually exist.
- $GENERATE templates are reported but not expanded, and $INCLUDE files cannot be resolved offline.
- DNSKEY, RRSIG, DS and NSEC records are displayed and preserved verbatim, but signatures and signing order are not validated.
- Non-ASCII owner names are flagged; the tool does not convert them to punycode A-labels for you.
- Comments are preserved by attaching them to the following record, so comments that sat between records may move with that record after sorting.
How to use this tool
Paste or load a zone
Paste a BIND zone file into the left pane, load a local .zone file, or choose one of the examples.
Review the record table
Use the type chips and search box to find a row. Click a row to open its type-specific fields.
Fix findings
Read the validation report, click a finding to highlight its row, and edit or remove records as needed.
Check the SOA serial
Use the serial helper to apply an RFC 1912-style YYYYMMDDNN bump before you ship the zone.
Export
Copy or download the canonical zone text and run named-checkzone against it before publishing.
Use cases
Edit a self-hosted BIND zone
Add a mail A record and an MX, check the SOA serial, and export a file named-checkzone will accept.
Review infrastructure-as-code diffs
Paste a generated zone, inspect the record table for conflicts and normalise it before committing.
Migrate a client zone
Bring a Windows-exported zone with BOM and CRLF line endings into a clean BIND-style canonical file.
Debug a DKIM record
See a long TXT as one editable string while the export splits it into legal 255-octet chunks.
Zone syntax handled by the editor
| Input form | What the editor does |
|---|---|
| $ORIGIN example.com. | Sets the origin used to expand @ and relative names; emitted as a header. |
| $TTL 3600 or 1h | Default TTL for records without an explicit TTL; unit suffixes are normalised to seconds. |
| name [ttl] [class] type rdata | TTL and class may appear in either order; IN is the default class. |
| IN A 192.0.2.1 | Leading whitespace keeps the previous owner (sticky owner rule). |
| @ IN SOA ns hostmaster ( … ) | Multi-line parenthesised rdata is parsed and re-emitted with labelled timers. |
| TXT "a" "b" | Quoted strings are joined for editing, then re-chunked by 255 octets on export. |
| \" \\ \; \DDD | Escapes are decoded for editing and re-escaped losslessly, including decimal octet escapes. |
| $GENERATE / $INCLUDE | Reported as unsupported: templates are not expanded and includes are not resolved. |
Input is BIND master-file syntax. dig/AXFR output can be pasted as a starting point, but it is not itself a zone file.
Common mistakes
Mistake:Forgetting the trailing dot on a target name.
Fix:A name without a dot is relative to $ORIGIN, so mail becomes mail.example.com. Write mail.example.com. when you mean an FQDN.
Mistake:Lowering the SOA serial after an edit.
Fix:Secondary servers compare serials and ignore a zone whose serial went backwards. Apply the suggested YYYYMMDDNN bump.
Mistake:Putting an A or MX record next to a CNAME at the same name.
Fix:RFC 1034 forbids it; move the address record to another owner or drop the CNAME.
Mistake:Assuming 255 TXT characters is the same as 255 TXT octets.
Fix:UTF-8 characters can take up to four bytes. This tool chunks by octets and preserves \DDD escapes.
Mistake:Trusting a zone that has no apex NS record.
Fix:named-checkzone expects at least one NS at the zone apex; the validation report calls out the omission.
Frequently asked questions
What are $ORIGIN and @ in a zone file?
$ORIGIN sets the domain that unqualified names are appended to. @ means the zone apex — the value of $ORIGIN. So with $ORIGIN example.com., a record named www becomes www.example.com., while @ becomes example.com. A name that already ends in a dot is absolute and is not changed.
Why must TXT strings be split at 255?
RFC 1035 limits each character-string in a TXT record to 255 octets, not 255 JavaScript characters. A DKIM key longer than that must be stored as several quoted strings inside the same record; resolvers concatenate them. This editor splits on octet boundaries, so UTF-8 text and \DDD escapes stay intact.
What makes a CNAME invalid with other records?
RFC 1034 says a name that has a CNAME cannot have any other record: no A, AAAA, MX or TXT at the same owner. Otherwise resolvers cannot decide which answer to return. The editor flags both the CNAME and the conflicting rows. DNSSEC records such as RRSIG are a documented nuance and are outside this check.
How should I bump my SOA serial?
Use the YYYYMMDDNN form from RFC 1912: the date followed by a two-digit revision. If the current serial has today's date, increment the revision (…04 becomes …05). If it is older, use today's date with revision 01. Future-dated serials keep increasing. Never lower a serial — secondary servers will ignore the zone.
Are my zone changes published anywhere?
No. Parsing, validation and export all happen in this browser tab. There is no DNS query, no server request and no upload. A draft is kept in this browser's local storage so you can come back to it; use Clear to delete it.
Does the editor preserve comments?
Yes. Comments are attached to the record that follows them and are written back out during export. Because records are sorted canonically, a comment may end up next to a different neighbour than in the original file, but its record stays with it.
Can I paste dig or AXFR output?
You can paste it as a starting point: lines with the same shape as resource records are parsed. dig output often includes headers, TTL columns and comments that are not zone syntax, so review the validation report before exporting. The tool does not query nameservers itself.
Why does a relative name without $ORIGIN fail?
BIND cannot tell whether www means www.example.com. or a name outside the zone. Add $ORIGIN example.com., or write fully qualified names with a trailing dot. The editor reports every affected line.
Does this replace named-checkzone?
No. It catches common authoring mistakes and emits conservative syntax, but named-checkzone is the authoritative check against your BIND version and configuration. Run it on the exported file before publishing.
References & standards
- RFCRFC 1034 — Domain Concepts and Facilities
- RFCRFC 1035 — Domain Names: Implementation and Specification
- RFCRFC 1912 — Common DNS Operational and Configuration Errors
- RFCRFC 2181 — Clarifications to the DNS Specification
- RFCRFC 7208 — Sender Policy Framework (SPF)
- docBIND 9 Administrator Reference Manual — zone file format
Related tools
API Mock Server
Define mock REST routes and intercept fetch calls client-side
AsyncAPI Validator
Validate AsyncAPI 2.x and 3.x documents offline, browse channels and messages, and check protocol binding coverage.
Bandwidth Calculator
Estimate how long a file takes to transfer at a given connection speed — correctly handling bits vs bytes (Mbps vs MB/s) and SI vs binary size units
Bandwidth-Delay Product Calculator
Compute BDP from bandwidth and RTT: required TCP window, scaling factor, in-flight MSS and buffer notes. Auditable math, entirely in your browser.
Broken Link Checker
Extract http(s) links from pasted HTML and check them via proxy
Bulk Redirect Map Generator
Generate nginx map blocks, Apache RedirectMatch rules, Netlify _redirects and vercel.json from one old-to-new URL list, with status codes, wildcards and conflict detection.