
DNS Not Resolving? 8 Proven Fixes for "Server Not Found" Errors
You open your browser, type a URL, and get hit with "Server Not Found," "This site can't be reached," or the dreaded DNS_PROBE_FINISHED_NXDOMAIN. Your internet connection is active โ you can ping IP addresses directly โ but domain names refuse to resolve.
This is a DNS resolution failure, and it's one of the most common connectivity problems users encounter. DNS (Domain Name System) translates human-readable domain names like example.com into the IP addresses computers actually use. When that translation breaks, websites become unreachable even though the underlying internet connection is fine.
The good news: most DNS failures have clear, fixable causes. Work through these 8 fixes in order โ the first three resolve the majority of cases.
Understanding Where DNS Failures Occur
DNS resolution passes through several layers before a name gets resolved:
Your Device โ Local DNS Cache โ Router โ ISP DNS Server โ Root DNS ServersA failure at any point produces the same frustrating browser error. Identifying which layer is broken helps you target the right fix. Use this quick diagnostic table:
| Test Command | Works? | What It Means |
|---|---|---|
ping 8.8.8.8 | Yes | Internet is working; DNS is broken |
ping 8.8.8.8 | No | Broader connectivity problem |
nslookup google.com | Yes | DNS works; browser may be the issue |
nslookup google.com 1.1.1.1 | Yes but above fails | Your default DNS server is broken |
nslookup google.com 192.168.1.1 | No | Router DNS is failing |
Run these in Command Prompt (Windows) or Terminal (macOS/Linux) before proceeding. The results will tell you exactly which fix to prioritize.
Fix 1: Flush Your DNS Cache
Your operating system caches DNS lookups to speed up repeat visits. Stale cached records โ from domain changes, CDN migrations, or simply bad data โ cause resolution failures for domains that work fine elsewhere.
This is the fastest fix and resolves a surprising number of problems.
Windows:
ipconfig /flushdnsmacOS (Ventura/Sonoma):
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponderLinux (systemd-based):
sudo systemd-resolve --flush-cachesChrome's internal DNS cache (separate from the OS): Navigate to chrome://net-internals/#dns and click Clear host cache. Then go to chrome://net-internals/#sockets and click Flush socket pools.
After flushing, retry the failing domain immediately. If it loads, a stale cache record was the culprit.
Fix 2: Restart Your Router Properly
A proper router restart โ not just pressing the power button โ clears DHCP leases, ARP tables, and routing state that can corrupt DNS assignments:
- Unplug the router from the wall (don't just press restart โ some routers soft-reboot too quickly)
- Wait 30 full seconds โ this ensures capacitors drain and memory clears
- Power back on and wait 2 minutes for the router to fully initialize before testing
This resolves DNS issues caused by routers assigning incorrect or expired DNS server addresses to connected devices via DHCP. It also fixes issues where the router's own DNS resolver has hit a memory limit or entered a degraded state.
Fix 3: Switch to a Public DNS Server
If your ISP's DNS server is down, slow, or selectively blocking domains, switching to a public DNS provider bypasses the problem entirely. This is the most impactful long-term fix.
| DNS Provider | Primary | Secondary | Notes |
|---|---|---|---|
| Cloudflare | 1.1.1.1 | 1.0.0.1 | Fastest globally, strong privacy |
| 8.8.8.8 | 8.8.4.4 | Reliable, but Google logs queries | |
| Quad9 | 9.9.9.9 | 149.112.112.112 | Blocks known malware domains |
| OpenDNS | 208.67.222.222 | 208.67.220.220 | Optional content filtering |
| NextDNS | Custom | Custom | Configurable blocking and logging |
Windows (manual DNS change):
- Control Panel โ Network and Internet โ Network Connections
- Right-click your active connection โ Properties
- Select Internet Protocol Version 4 (TCP/IPv4) โ Properties
- Select "Use the following DNS server addresses"
- Enter primary:
1.1.1.1, secondary:1.0.0.1 - Click OK โ close all windows โ test
macOS:
- System Settings โ Network โ [your connection] โ Details โ DNS
- Click + and add
1.1.1.1and1.0.0.1 - Remove old DNS entries โ click OK
Android:
Settings โ Network & Internet โ Private DNS โ enter one.one.one.one
iOS:
Settings โ WiFi โ tap your network โ Configure DNS โ Manual โ add 1.1.1.1
Fix 4: Release and Renew Your IP Address
A corrupted DHCP lease can assign incorrect DNS server addresses to your device. Releasing and renewing forces a fresh assignment.
Windows:
ipconfig /release
ipconfig /renewmacOS: System Settings โ Network โ [Connection] โ Renew DHCP Lease
Linux:
sudo dhclient -r && sudo dhclientAfter renewal, run ipconfig /all (Windows) or cat /etc/resolv.conf (Linux/Mac) to confirm the DNS servers listed match what you expect.
Fix 5: Check for DNS Hijacking
Malware commonly redirects DNS queries to attacker-controlled servers that return incorrect results. Signs of DNS hijacking:
- You get redirected to unexpected pages when typing URLs
- SSL certificate warnings appear on sites that normally work
- Some sites work but others are mysteriously unreachable
- Ads appear on sites that shouldn't have them
How to check:
Run nslookup google.com and look at the "Server" line in the output โ it should show your router's IP or the DNS server you configured, not an unfamiliar address.
Use our DNS Lookup tool to query a known domain and verify the result matches what authoritative sources return.
If you suspect hijacking:
- Run a malware scan (Windows Defender, Malwarebytes)
- Log into your router (
192.168.1.1or192.168.0.1) and check the DNS settings under WAN configuration - If router settings look unfamiliar or changed, factory-reset it immediately
Fix 6: Disable IPv6 Temporarily
Some ISPs have incomplete or broken IPv6 DNS infrastructure. When a device prefers IPv6 DNS and the ISP's IPv6 DNS server is degraded, resolution fails even though IPv4 works.
Windows:
- Control Panel โ Network Connections โ right-click connection โ Properties
- Uncheck Internet Protocol Version 6 (TCP/IPv6)
- Click OK
macOS: System Settings โ Network โ [Connection] โ Details โ TCP/IP โ Configure IPv6: Link-local only
If disabling IPv6 fixes the problem, your ISP has an IPv6 DNS issue. Report it to their support team, or keep using a public DNS provider that handles IPv6 correctly (Cloudflare's 2606:4700:4700::1111 works reliably).
Fix 7: Inspect Your Hosts File
The hosts file lets the OS resolve specific domain names without querying DNS at all. It overrides everything. Malware frequently modifies this file to redirect legitimate domains to malicious IPs โ or to null addresses that cause failures.
Location:
- Windows:
C:\Windows\System32\drivers\etc\hosts - macOS/Linux:
/etc/hosts
A healthy hosts file contains only a handful of lines:
127.0.0.1 localhost
::1 localhostAny lines pointing legitimate domains (google.com, cloudflare.com, etc.) to unexpected IP addresses should be removed. Open the file in a text editor with admin privileges and delete any suspicious entries.
Fix 8: Enable DNS over HTTPS (DoH)
If your ISP actively interferes with DNS queries โ through filtering, throttling, monitoring, or transparent proxy โ DNS over HTTPS routes queries through an encrypted HTTPS connection that ISPs cannot easily inspect or block.
Chrome:
Settings โ Privacy and security โ Security โ Use secure DNS โ With: Cloudflare (1.1.1.1)
Firefox:
Settings โ Privacy & Security โ scroll to "DNS over HTTPS" โ Enable using: Default Protection
Edge:
Settings โ Privacy, search and services โ Use secure DNS โ Choose a service provider: Cloudflare
For system-wide encrypted DNS on all devices (not just browsers), see our DNS over HTTPS guide.
When All Fixes Fail: ISP Outage
Sometimes the problem genuinely isn't yours. ISPs experience DNS outages lasting minutes to hours. Signs:
- All devices on your network are affected simultaneously
- The problem started suddenly with no changes on your end
- Switching to Google or Cloudflare DNS (Fix 3) resolves it immediately
Check your ISP's status page or their social media for outage reports. Switching to a public DNS server (Fix 3) will bypass the outage and restore access immediately โ that fix is also the permanent solution to recurring ISP DNS reliability issues.
Quick Reference: Fix Priority
| Fix | Time Required | Resolves |
|---|---|---|
| Flush DNS cache | 30 seconds | Stale cached records |
| Restart router | 3 minutes | Corrupted DHCP/router DNS state |
| Switch DNS server | 5 minutes | ISP DNS down or blocked |
| Release/renew IP | 1 minute | Bad DHCP lease |
| Check for hijacking | 5โ10 minutes | Malware-modified DNS |
| Disable IPv6 | 2 minutes | Broken ISP IPv6 DNS |
| Inspect hosts file | 2 minutes | Malware-modified host overrides |
| Enable DoH | 3 minutes | ISP DNS interference |
If you've worked through all 8 fixes and DNS still doesn't resolve, the problem is likely in network infrastructure above your router. For broader connectivity issues, see our Network Troubleshooting Guide.
Related Articles
WhatIsMyLocation Team
Our team of network engineers and web developers builds and maintains 25+ free networking and location tools used by thousands of users every month. Every article is reviewed for technical accuracy using real-world testing with our own tools.
Related Articles
Try Our Location Tools
Find your IP address, GPS coordinates, and more with our free tools.