Programming

How to Reset Your DNS Server (Windows, Mac, iPhone, Android)

You changed a domain's A record two hours ago. Your colleague sees the new site. You still get the old one, or worse, a blank error page. Or maybe you never touched a DNS record at all and Chrome just started throwing DNS_PROBE_FINISHED_NXDOMAIN at a site you visit every day.

A network engineer at a home office desk running terminal diagnostics on one monitor half while a browser connection error shows on the other, illustrating how to reset a DNS server.

Both problems usually end the same way: you reset the DNS server settings on your device and everything works again. The catch is that “reset DNS” means two completely different operations, and most guides blur them together. One clears a cache. The other changes which server answers your lookups. Picking the wrong one wastes twenty minutes and leaves the site still broken.

This guide gives you the exact commands for Windows 11, macOS Tahoe, Linux, iPhone, Android, Chrome, and your router. It also covers the part almost every other guide skips: what to do when you flush the cache and absolutely nothing changes.

Quick answer: To reset your DNS server, flush the local cache first. On Windows run ipconfig /flushdns in an admin Command Prompt. On macOS run sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder in Terminal. On Linux run sudo resolvectl flush-caches. If the problem persists, change your DNS server addresses to a public resolver like 1.1.1.1.

Flush or Change: Which DNS Reset Do You Actually Need?

A flush clears the record your device already stored. A change swaps out the server your device asks for new records. Flushing fixes stale data from a resolver that works. Changing fixes a resolver that is slow, blocked, or lying to you. Doing the wrong one first is the most common reason a DNS fix fails.

Here is the decision in one table. Find your symptom, run that column.

Your symptomFlush the cacheChange the DNS server
You just edited a DNS record and see the old IPYes, do this firstOnly if propagation is confirmed elsewhere
A site loads on your phone but not your laptopYesRarely
DNS_PROBE_FINISHED_NXDOMAIN on one siteYesYes, if flush fails
Every site fails, but the connection is upNoYes
Lookups take 2 or 3 seconds before pages loadNoYes
Your ISP blocks or redirects certain domainsNoYes
A VPN crashed and left broken settings behindYesYes, reset to automatic

Most readers landing here need a flush. It takes ten seconds and carries no risk. Start there, and only move to changing servers if the flush leaves you where you started.

What a DNS reset does not fix

A reset touches your device. It does nothing to the domain itself. If the domain expired, the nameservers are misconfigured, or the origin server is down, you can flush all day and nothing will change. Test from a phone on cellular data before you spend time on your laptop. If the site fails there too, the problem is not local. Our guide to how DNS affects website speed and performance covers the server-side half of this.

How to Reset the DNS Server on Windows 11 and Windows 10

Windows 11 Command Prompt running as administrator showing the ipconfig /flushdns command and the successful DNS resolver cache flush confirmation message.

Windows resets in two stages. First flush the resolver cache with ipconfig /flushdns, which works identically on Windows 10, Windows 11, and Windows Server. Then, if that fails, reset your DNS server addresses back to automatic in Settings so the machine takes whatever your router hands out.

Step 1: Flush the DNS resolver cache

  1. Press the Windows key, type cmd, then right-click Command Prompt and choose Run as administrator.
  2. Type the command below and press Enter.
ipconfig /flushdns

You should see: Successfully flushed the DNS Resolver Cache. That message is your confirmation. If you prefer PowerShell, Clear-DnsClientCache does exactly the same job (Microsoft Learn, DnsClient module documentation).

Want to see what was cached before you clear it? Run ipconfig /displaydns first. It prints every stored record with its remaining TTL, which is genuinely useful when you are debugging a migration.

Step 2: Reset DNS server addresses to automatic

Windows 11 moved this. The old Network and Sharing Center path still exists but is buried, and the “Status” page many guides reference was removed.

  1. Open Settings > Network & internet.
  2. Click Wi-Fi or Ethernet, then click your active connection.
  3. Find DNS server assignment and click Edit.
  4. Choose Automatic (DHCP) and save.

To set a specific resolver instead, choose Manual, switch IPv4 on, and enter 1.1.1.1 as preferred with 1.0.0.1 as alternate.

Step 3: The deeper reset, when steps 1 and 2 fail

Run these three in order in the same admin Command Prompt, then restart:

ipconfig /release
ipconfig /renew
netsh winsock reset

ipconfig /release and /renew do not flush DNS on their own, so run the flush separately. The Winsock reset rebuilds the network socket configuration, which clears out damage left behind by a crashed VPN client or an aggressive security tool.

How to Reset the DNS Server on macOS

macOS Terminal window showing the dscacheutil and killall mDNSResponder commands used to flush the DNS cache, with no output returned after execution.

macOS clears its cache with a single Terminal line that combines two commands. The first empties the directory service cache, the second restarts mDNSResponder, the process that answers lookups. Both are needed. Running only one leaves stale records in the other layer, which is why half-working fixes are so common on Mac.

Flush the cache in Terminal

Open Terminal from Applications > Utilities, or press Command + Space and type Terminal. Then run:

sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder

Enter your admin password when prompted. Nothing appears as you type, which is normal. macOS prints no success message either. A clean return to the prompt means it worked.

This command covers macOS Tahoe 26, Sequoia 15, Sonoma 14, Ventura 13, Monterey 12, and Big Sur 11. On Catalina 10.15 and older, use sudo killall -HUP mDNSResponder on its own (Apple Support, DNS cache reset documentation).

If you get “No matching processes belonging to you were found”, mDNSResponder is not running. That usually means a third-party DNS manager or VPN has taken over resolution. Quit it and try again.

Reset DNS addresses in System Settings

Apple renamed System Preferences to System Settings back in Ventura, so older instructions send you to a menu that no longer exists.

  1. Open System Settings > Network.
  2. Click your active connection, then click Details.
  3. Select the DNS tab.
  4. Select each server in the list and click the minus button to remove it, then click OK.

An empty list means your Mac falls back to whatever your router assigns. That is the true “reset to default” state. To use a public resolver instead, click the plus button and add 1.1.1.1.

How to Reset the DNS Server on Linux

Step-by-step infographic showing how to reset the DNS server cache on Linux by identifying the active DNS resolver and using the correct flush command for systemd-resolved, dnsmasq, nscd, BIND, and WSL2.

Linux has no single DNS cache. What you flush depends on which resolver your distribution runs, and some setups cache nothing at all. Check what is listening on port 53 first, then run the matching command. Guessing wrong here is harmless but useless, which frustrates a lot of people.

Find your resolver:

sudo lsof -i :53

Then run the command that matches:

ResolverCommon onFlush command
systemd-resolvedUbuntu 18.04+, Debian, Fedora, Archsudo resolvectl flush-caches
dnsmasqOlder Ubuntu, OpenWrt, LXC hostssudo systemctl restart dnsmasq
nscdRHEL, CentOS, some serverssudo systemctl restart nscd
BIND (named)Self-hosted resolverssudo rndc flush

One correction worth making. Plenty of guides still print sudo systemd-resolve --flush-caches. That binary was renamed to resolvectl in systemd 239, released in 2018. It survives as a compatibility symlink on some distributions and is gone on others. Use resolvectl and stop worrying about it.

Running WSL2 on Windows? WSL keeps its own resolver, separate from the Windows one. Flushing Windows does nothing inside the distro. Run sudo resolvectl flush-caches inside WSL, or run wsl --shutdown from Windows to restart it cleanly.

How to Reset the DNS Server on iPhone and iPad

Infographic explaining how to reset the DNS server on an iPhone or iPad using Airplane Mode, Reset Network Settings, and manual DNS configuration with 1.1.1.1 and 1.0.0.1 for a Wi-Fi network.

iOS gives you no command line and no flush button. You reset DNS on an iPhone by forcing the network stack to restart, or by setting the DNS server manually per Wi-Fi network. Airplane mode toggling handles the quick case in about five seconds and fixes most stale-record problems.

The fast method: open Control Center, turn Airplane Mode on, wait five seconds, turn it off. This drops and rebuilds the network connection, which clears cached lookups.

The thorough method: go to Settings > General > Transfer or Reset iPhone > Reset > Reset Network Settings. This wipes saved Wi-Fi passwords too, so keep them handy.

To set the DNS server manually:

  1. Open Settings > Wi-Fi.
  2. Tap the blue info icon next to your connected network.
  3. Scroll to Configure DNS and tap it.
  4. Choose Manual, remove existing entries with the minus button, then add 1.1.1.1 and 1.0.0.1.
  5. Tap Save.

One limitation nobody mentions upfront: this setting is per Wi-Fi network. iOS has no global DNS switch the way Android does, and cellular data always uses your carrier’s resolver with no user override. Install the resolver provider’s own app if you need it applied everywhere.

How to Reset the DNS Server on Android

Infographic explaining how to reset the DNS server on Android using Private DNS settings, Airplane Mode, phone restart, and network reset, including Cloudflare and Google DNS provider examples.

Android handles this through Private DNS, a system-wide setting that applies to Wi-Fi and cellular at the same time. It uses DNS over TLS, so lookups are encrypted as well as redirected. Setting it to Automatic returns you to your carrier or router default, which is the reset most people want.

  1. Open Settings > Network & internet > Private DNS.
  2. On Samsung Galaxy phones the path is Settings > Connections > More connection settings > Private DNS.
  3. Choose Automatic to reset, or Private DNS provider hostname to set one.
  4. For Cloudflare enter one.one.one.one. For Google enter dns.google.

To clear cached entries without changing anything, toggle Airplane Mode or restart the phone. There is no user-facing flush command on modern Android without root access.

A full network reset lives at Settings > System > Reset options > Reset Wi-Fi, mobile & Bluetooth. Use it only when the targeted fixes fail, since it clears every saved network.

Clear Your Browser’s DNS Cache Too

Chrome, Edge, and Brave keep their own DNS cache, completely separate from the operating system. This is the single biggest reason a flush appears to do nothing. You clear the OS cache, reload the page, and the browser serves the same stale record it had thirty seconds ago.

To clear it in Chrome:

  1. Open a new tab and go to chrome://net-internals/#dns.
  2. Click Clear host cache.
  3. Open chrome://net-internals/#sockets and click Flush socket pools.
  4. Reload the page.

The socket flush matters. Chrome keeps existing connections open, so an already-established socket can keep serving the old destination even after the host cache is empty.

The same pages work in every Chromium browser. Use edge://net-internals/#dns for Edge and brave://net-internals/#dns for Brave. Firefox has no equivalent page. Restart the browser instead, or set network.dnsCacheExpiration to 0 in about:config while you are testing a migration.

Testing in an incognito window is a fast diagnostic. If the site loads there but not in your normal window, the problem is cached state or an extension, not DNS. Our walkthrough on fixing Chrome privacy and connection errors covers the certificate side of that.

Why Your DNS Reset Did Not Work

A modern home router with illuminated status lights on a wooden console table, representing the router-level DNS cache that sits between a device and the internet provider resolver.

A DNS lookup passes through four separate caches, and a reset usually clears only one of them. Your browser caches. Your operating system caches. Your router caches. Your ISP or public resolver caches, and that last one honors the record’s TTL no matter what you do locally. Clear them in order.

LayerHow to clear itUnder your control?
Browserchrome://net-internals/#dnsYes
Operating systemipconfig /flushdns or resolvectl flush-cachesYes
RouterReboot it, or reset DNS in the admin panelYes
Recursive resolver (ISP, Cloudflare, Google)Wait for the TTL to expireNo

That last row is the honest answer to most “I flushed and nothing changed” complaints. If a record has a 24 hour TTL, your ISP’s resolver will keep serving the old value for up to 24 hours regardless of what you do. Switching to a public resolver that has not cached the old record is the only local workaround.

Reset DNS on your router

Your router caches lookups for every device on the network. Open a browser, go to the router’s address (commonly 192.168.1.1 or 192.168.0.1), sign in, and look under Internet or WAN settings for DNS. Set it back to “obtain automatically” or enter a public resolver. A power cycle of 30 seconds clears the cache without touching any settings. If your site is behind a proxy layer, our notes on choosing a reverse proxy server explain where else responses get cached.

Does Flushing DNS Make Your Internet Faster?

No, and this is worth correcting because so many guides claim otherwise. Flushing empties the cache, so the next lookup for every domain has to travel to a resolver again instead of being answered locally in under a millisecond. Immediately after a flush, browsing is marginally slower, not faster. The cache rebuilds within a few minutes.

What genuinely improves speed is changing your resolver. If your ISP’s DNS answers in 80 milliseconds and Cloudflare answers in 12, you save real time on every first visit to a domain. That is a resolver change, not a flush. The two get conflated constantly.

The other real benefits of switching are correctness and privacy. Public resolvers do not inject ads into NXDOMAIN responses, do not redirect typos to search pages, and support DNS over HTTPS. Those are good reasons. “It makes the internet faster” is not one, at least not the flush.

Flushing clears the cache. Changing the resolver improves lookup time. Only one of those two makes browsing faster, and it is not the flush. Webzeto engineering notes, July 2026

Which Public DNS Server Should You Use?

Three public resolvers cover nearly every use case. Cloudflare at 1.1.1.1 is the fastest for most US connections and does not log query data to disk. Google at 8.8.8.8 is the most reliable and the most widely whitelisted on corporate networks. Quad9 at 9.9.9.9 blocks known malicious domains at the resolver level.

ResolverPrimarySecondaryBest for
Cloudflare1.1.1.11.0.0.1Speed and privacy
Google Public DNS8.8.8.88.8.4.4Reliability, restrictive networks
Quad99.9.9.9149.112.112.112Malware and phishing filtering
OpenDNS Home208.67.222.222208.67.220.220Family content filtering

Set both primary and secondary. A single entry gives you no fallback, and when that one resolver has a bad minute, every site on your machine fails at once.

One warning from experience: on a client migration last year we set Quad9 across an office and spent an afternoon on a “broken” staging domain. Quad9’s filtering had flagged the temporary subdomain. Filtering resolvers can block things you actually want. Keep that in mind before rolling one out to a whole team.

How to Verify the DNS Reset Worked

Run a lookup and read the answer. On Windows use nslookup, on macOS and Linux use dig. Both print the IP address your resolver returned and which server answered. If the IP matches the new record and the server matches the resolver you set, the reset worked.

nslookup webzeto.com
dig webzeto.com +short
dig webzeto.com | grep SERVER

Check which resolver is actually in use:

  • Windows: ipconfig /all and read the DNS Servers line
  • macOS: scutil --dns | grep nameserver
  • Linux: resolvectl status

For a reachability check rather than a resolution check, our guide on how to ping an IP address walks through reading the response times. To confirm a record change has spread beyond your own machine, query a resolver you did not just configure: dig @8.8.8.8 yourdomain.com. If Google sees the new record and you do not, the problem is still local. If neither sees it, the change has not propagated yet. Reading the records themselves is covered in our complete guide to DNS record lookups.

Common DNS Errors and What They Actually Mean

Error codes tell you where the failure happened, which tells you whether a reset will help at all. NXDOMAIN means the resolver answered and said the domain does not exist. A timeout means the resolver never answered. Those two point at completely different fixes.

ErrorWhat it meansWill a reset fix it?
DNS_PROBE_FINISHED_NXDOMAINResolver says the domain does not existOften yes, flush first
ERR_NAME_NOT_RESOLVEDSame cause, different Chrome wordingOften yes
DNS server isn't respondingResolver unreachable or timing outChange the resolver
DNS_PROBE_FINISHED_BAD_CONFIGLocal DNS settings are brokenReset to automatic
SERVFAIL in dig outputResolver failed, often DNSSECNo, server-side issue

A stale NXDOMAIN is the sneakiest of these. Once your machine caches a “does not exist” answer, it keeps returning it even after the domain starts working. That is exactly the case where flushing helps and waiting does not.

Frequently Asked Questions

Can resetting my DNS server cause data loss?

No. A DNS flush clears temporary lookup records only. It does not touch files, browser bookmarks, saved passwords, or installed software. The one exception is a full network reset on a phone, which erases saved Wi-Fi passwords and paired Bluetooth devices. That is a settings loss, not data loss, but write your Wi-Fi password down first.

How often should I reset my DNS server?

Almost never on a schedule. DNS caching exists to make browsing faster, and clearing it routinely just adds lookup delay. Flush when you have a specific reason: you changed a DNS record, you are testing a site migration, a domain resolves to the wrong IP, or you edited your hosts file. Otherwise leave it alone.

Do I need admin rights to flush DNS?

Yes on Windows, macOS, and Linux. Windows requires an admin Command Prompt, and macOS and Linux need sudo. If you are on a managed work laptop without admin rights, restarting the machine clears the cache as a side effect. Browser-level flushing at chrome://net-internals/#dns needs no special permission.

Why does my site still show the old IP after flushing DNS?

Because you cleared only one of four caches. Your browser, router, and your ISP’s recursive resolver all hold copies. The resolver honors the record’s TTL, so it can serve the old address for hours after you flush locally. Clear browser and router too, then verify with dig @8.8.8.8 yourdomain.com to see what the outside world gets.

Is flushing the DNS cache safe?

Yes. It is one of the lowest-risk troubleshooting steps available. The worst outcome is that your next few page loads take a fraction of a second longer while the cache rebuilds. No configuration is changed and nothing is deleted permanently. Changing your DNS server addresses carries slightly more risk, so note the current values before you edit them.

How long does DNS propagation take?

Typically 5 to 30 minutes for most visitors, and up to 48 hours in the worst case. The actual time depends on the TTL on your records. A 300 second TTL propagates in minutes. An 86400 second TTL can take a full day. Lower the TTL to 300 a day before a planned migration, then raise it afterward.

Does a VPN affect my DNS settings?

Yes, heavily. Most VPN clients override your resolver and route lookups through their own servers. If the VPN’s DNS is slow or blocking a domain, you get errors even when your real DNS is fine. Disconnect the VPN, flush the cache, and retry. A crashed VPN can also leave broken settings behind, which is when the reset to automatic matters.

Will changing my DNS server hide my browsing from my ISP?

Only partially, and only with encryption enabled. Plain DNS queries travel unencrypted, so your ISP can read them even if you use Cloudflare. DNS over HTTPS or DNS over TLS encrypts the query itself. Your ISP still sees the destination IP addresses you connect to. A DNS change is a privacy improvement, not privacy protection.

What is the difference between flushing DNS and resetting network settings?

A flush clears cached lookups and changes nothing else. A network reset rebuilds the entire network configuration: adapters, saved Wi-Fi networks, Winsock catalog, and DNS settings together. Flush first, since it takes ten seconds and costs nothing. Reserve the network reset for cases where multiple network functions are broken at once.

Conclusion

That stale A record from the opening scenario has a straightforward path now. Flush the operating system cache, clear Chrome’s separate host cache, power cycle the router, then check with dig @8.8.8.8 to see whether the outside world agrees with you. If it does and your machine still does not, one of the four caches is still holding on. If it does not, the record has not propagated and no amount of local work will change that.

The habit worth building is checking before acting. Run ipconfig /displaydns or dig first, read what your machine actually believes, then decide whether you need a flush or a different resolver. Thirty seconds of reading saves the twenty minute loop of resetting the same cache repeatedly and wondering why nothing moved.

What is the longest a DNS change has ever taken to reach you, and did you ever find out which layer was holding the old record?

Leave a Reply

Your email address will not be published. Required fields are marked *

Share the article

Written By

Author Avatar

July 31, 2026

Hi there! I’m Ayesha Khan, a skilled content writer based in Pakistan with a strong background in computer science. I specialize in transforming complex ideas into clear, engaging, and easy-to-understand content. With 10 years of experience working across different industries, I focus on delivering content that not only informs but also connects with readers. I’m passionate about writing and take pride in creating high-quality work that helps clients communicate their message effectively.