DNS is the phone book of the internet — it translates human-readable domain names into the IP addresses that computers actually use. When a site goes down, email stops delivering, or a deployment doesn't take effect, DNS records are often where the investigation starts. Understanding what each record type does — and being able to look them up instantly — is a core developer skill.
The DevToolShack DNS Lookup tool queries any domain's DNS records in real time, directly in your browser. No terminal, no dig command, no sign-up required.
How DNS Resolution Works
When you type devtoolshack.com in a browser, the process goes roughly like this:
- Your computer checks its local cache — if it's seen this domain recently, use the cached IP
- Ask your ISP's (or configured) recursive DNS resolver
- The resolver asks the root name servers which name servers handle
.com - The root servers point to the
.comTLD name servers - The TLD name servers point to the domain's authoritative name servers
- The authoritative name servers return the actual DNS records
- The result is cached (per the TTL value) and returned to your browser
This whole chain typically completes in under 100ms. The TTL (Time To Live) value on each record controls how long it can be cached before the next lookup is required.
The Essential Record Types
A Record
Maps a domain name to an IPv4 address. The most fundamental DNS record — without it, your domain doesn't point anywhere.
example.com. 300 IN A 93.184.216.34
AAAA Record
Same as A, but for IPv6 addresses. As IPv6 adoption grows, having both A and AAAA records is increasingly important.
example.com. 300 IN AAAA 2606:2800:220:1:248:1893:25c8:1946
CNAME Record
An alias — points one domain name to another. Commonly used to point www to the root domain, or to point a subdomain to a CDN or service provider.
www.example.com. 300 IN CNAME example.com.
example.com) alongside an MX or TXT record. Use an A record at the root, or use CNAME flattening if your DNS provider supports it (Cloudflare does).MX Record
Mail Exchange — specifies which mail servers handle email for the domain. Has a priority number; lower priority = preferred server.
example.com. 300 IN MX 10 mail1.example.com.
example.com. 300 IN MX 20 mail2.example.com.
TXT Record
Stores arbitrary text data. Used for many purposes — SPF and DKIM email authentication, domain ownership verification (Google Search Console, SSL certificates), DMARC policies.
# SPF record — authorises specific mail servers to send for this domain
example.com. 300 IN TXT "v=spf1 include:_spf.google.com ~all"
# Domain verification
example.com. 300 IN TXT "google-site-verification=abc123..."
NS Record
Name Server — specifies which DNS servers are authoritative for the domain. Set at your domain registrar to point to your DNS provider.
example.com. 86400 IN NS ns1.cloudflare.com.
example.com. 86400 IN NS ns2.cloudflare.com.
SOA Record
Start of Authority — contains administrative information about the zone: primary name server, contact email, serial number, and timing values for secondary servers. Usually managed automatically by your DNS provider.
Common DNS Troubleshooting Scenarios
| Symptom | Records to Check |
|---|---|
| Website not loading after domain change | A record — verify it points to the right IP |
| Email not delivering | MX records — verify they exist and point correctly |
| Emails going to spam | TXT records — check SPF, DKIM, and DMARC are configured |
| SSL certificate failing domain validation | TXT or CNAME records — the CA may require a validation record |
| DNS change not propagating | Check the TTL — cached records won't refresh until TTL expires |
| Subdomain not working | A or CNAME record for the specific subdomain |
Querying DNS From the Command Line
# Look up A records
dig example.com A
# Look up all record types
dig example.com ANY
# Query a specific DNS server (bypass local cache)
dig @8.8.8.8 example.com A
# Short output — just the answer
dig +short example.com A
# Check MX records
dig example.com MX
# Windows equivalent
nslookup example.com
nslookup -type=MX example.com
TTL and DNS Propagation
Every DNS record has a TTL (Time To Live) measured in seconds. When you change a record, the change doesn't instantly reach everyone — old cached values remain until their TTL expires. Common TTLs:
- 300 seconds (5 min) — used when you're about to make changes; quick propagation
- 3600 seconds (1 hour) — common default for most records
- 86400 seconds (24 hours) — used for stable records like NS
If you're planning a DNS change, reduce the TTL to 300 at least an hour before the change. After the change is confirmed working, increase it back.