NXDOMAIN
What is NXDOMAIN?
NXDOMAIN is the DNS response code, defined in RFC 1035, a server returns when a queried domain doesn't exist at all, distinct from an empty NOERROR answer meaning the name exists but lacks that record type. AdminKit's negative caching entry explains how resolvers cache an NXDOMAIN answer using the zone's SOA minimum TTL.
By AdminKit team, Netbase JSC · Updated
NXDOMAIN is the DNS response code (RFC 1035, an Internet Standard per its IETF Datatracker entry) a server returns when a queried domain name does not exist at all, as distinct from NOERROR with an empty answer, which means the name exists but has no record of the requested type. A resolver that receives NXDOMAIN for a name can cache that negative result for a TTL set by the queried zone’s SOA record (RFC 2308), so repeated queries for a nonexistent name don’t keep hitting authoritative servers. This caching is why a newly registered domain, or a typo’d one a registrar hasn’t delegated yet, can keep returning NXDOMAIN for a while even after the correct delegation is published, and why some ISPs and public Wi-Fi networks intercept NXDOMAIN responses to redirect users to a search or ad page instead of returning the accurate “this name doesn’t exist” answer — a practice ICANN’s Security and Stability Advisory Committee examined directly in its report on DNS response modification, warning of the risks this kind of NXDOMAIN substitution creates. Google Public DNS’s FAQ states that it always returns NXDOMAIN for a name that does not exist, and that seeing a redirect page instead may come from a browser plug-in or from an ISP intercepting and replacing NXDOMAIN responses. See the negative caching entry for how long that cached NXDOMAIN answer actually persists, and the SOA record entry for the minimum-TTL field that sets it.
AdminKit groups nXDOMAIN under its DNS cluster — browse the AdminKit glossary index for other related terms.
Frequently asked questions
How is NXDOMAIN different from an empty NOERROR answer?
NXDOMAIN means the queried domain name doesn't exist at all, while NOERROR with an empty answer means the name exists but has no record of the requested type -- the name is real, just not for that query.
Why can a newly registered domain keep returning NXDOMAIN after it's delegated?
Because a resolver that already cached an NXDOMAIN for that name keeps returning the cached negative result for a TTL set by the zone's SOA record, even after the correct delegation is published, until that cache entry expires.
Why do some ISPs and public Wi-Fi networks intercept NXDOMAIN?
To redirect users to a search or ad page instead of returning the accurate 'this name doesn't exist' answer -- a behavior that breaks the normal meaning of NXDOMAIN for anything relying on an accurate response.
What record controls how long a negative NXDOMAIN result gets cached?
The queried zone's SOA record, per RFC 2308 -- its minimum field sets the TTL for how long a resolver may cache that negative answer before re-querying.