Flushing your DNS cache is one of the quickest ways to fix website loading issues, DNS errors, and problems after changing DNS records or switching DNS providers.
Whether you’re experiencing slow internet, trouble accessing websites, or simply want to ensure your device is using up-to-date internet records, learning how to flush your DNS cache (sometimes called flushDNS or DNS cache clear) is a quick and effective fix.
In this guide, you’ll discover what DNS cache is, why it sometimes causes issues, and step-by-step instructions to clear DNS cache on every major platform. By the end, you’ll know exactly which DNS flush command to use—plus a few pro tips to keep everything running smoothly.
What is DNS?
Domain Name System (DNS) is the core naming system of the internet that translates easy-to-remember domain names like example.com into numerical IP addresses that computers use to communicate with each other.
It works much like a digital phonebook: when you enter a website URL, your device contacts DNS servers to look up the correct IP address and then connects you to the right web server.
The results of these lookups are temporarily stored in a DNS cache on your device and applications, which speeds up repeat visits but can sometimes cause issues if the cached records become outdated or corrupted.
What is DNS Cache and Why Flush It?
The DNS cache is a small database stored on your computer, phone, or browser, remembering the IP addresses of websites you’ve recently visited. This makes browsing faster.
The DNS cache lets your device quickly retrieve websites without querying the main DNS server each time. However, sometimes these cached records become outdated, causing errors, loading the wrong site, or failing to connect at all.
Common reasons to flush DNS:
- Sites not loading correctly or showing errors
- Website IP address changed by the host or owner
- Changing your DNS provider (Google DNS, OpenDNS, Cloudflare, etc.)
- Privacy and security after malware or spoofing
- Clearing outdated local info for fresh connections
By regularly performing a DNS cache clear, you avoid most of these headaches and improve your browsing experience.
How to Flush DNS Cache on Windows
Flushing DNS cache in Windows is quick, and the command works on Windows 10, Windows 11, and most earlier versions.
Follow these steps:
- Click the Start button or search bar, then type “Command Prompt,” or just cmd.
- Right-click and select “Run as Administrator.”
- In the Command Prompt window, type:
ipconfig /flushDNS
- Hit Enter.
You’ll see a message: “Successfully flushed the DNS Resolver Cache.” This means your DNS flush worked and your system is now using fresh DNS data.
How to Flush DNS Cache on Mac
Mac users can flush their DNS cache via Terminal, though the command depends on your macOS version.
Follow these steps:
- Open Finder and search for “Terminal,” or find it in Applications > Utilities.
- Enter the relevant command (for most modern versions):
sudo killall -HUP mDNSResponder
- For older macOS versions, use:
sudo dscacheutil -flushcache
- Press Enter and provide your administrator password if needed.
You’ll get no message, but your cache is cleared. Flushing the DNS cache on Mac is essential after changing DNS settings, troubleshooting errors, or switching networks.
How to Flush DNS Cache on Linux
Linux users have a few ways to perform DNS flush commands depending on their system distribution and DNS service.
For Ubuntu or Debian with systemd-resolved:
- Open Terminal.
- Run: sudo systemd-resolve –flush-caches
For other distributions (with Name Server Cache Daemon):
- Open Terminal.
- Run: sudo /etc/init.d/nscd restart
Or, if running BIND: sudo rndc flush
After using any of these flushDNS commands, your DNS cache will be cleared.
How to Clear DNS Cache in Google Chrome
Browsers also store DNS records, so if your system-level DNS flush isn’t enough, you may want to clear DNS cache in Chrome. This is especially useful if you’re a heavy Chrome user and notice issues with specific sites.
Steps to clear DNS cache in Chrome:
- Open Chrome and type in your address bar: chrome://net-internals/#dns
- Press Enter.
- Click the “Clear host cache” button.
That’s it. Your browser’s DNS cache is now refreshed.
DNS Flush Pro Tips: When and Why to Flush
- If you switch internet providers or change DNS settings, always flush DNS cache to avoid using old IP records.
- After a malware scan or removal, clear your DNS cache for added security.
- Before troubleshooting network issues, perform a quick DNS flush to eliminate cached errors.
- For web developers or those running websites, flush DNS after website migrations, updates, or domain changes.
FAQs: Flushing DNS Cache
Q1. What does flush DNS actually do?
A flush DNS cache action deletes all stored DNS lookup entries on your device, so it must re-query DNS servers for fresh records, often fixing bad or outdated mappings.
Q2. Is it safe to clear DNS cache?
Yes, it is safe to clear DNS cache; the system automatically rebuilds it as you browse, and you won’t lose any personal files or app data by doing it.
Q3. How often should I use the DNS flush command?
Use the DNSflush command when you change DNS servers, update domain records, move hosting, or notice DNS-related errors, such as domains not resolving or loading slowly.
Q4. Does flushing DNS make the internet faster?
Flushing alone does not increase bandwidth, but it can remove broken entries that slow down lookups, which may make websites feel more responsive in some cases.
Conclusion: Why Flushing Your DNS Cache Matters
A regular DNS flush keeps your system running smoothly, protects your privacy, and helps you sidestep everyday browsing errors. Whether on Windows, Mac, Linux, or just using Chrome, knowing how to clear DNS cache is a simple tool to keep internet issues at bay. If you ever find sites loading the wrong way or want to ensure you’re not using old cached info, these quick commands will get your device back on track.
By following the clear steps above and including keywords such as flush DNS, clear DNS cache, DNS flush command, and flushDNS, you ensure both a positive user experience and SEO relevance—making your blog both valuable and easy to discover in search results and AI-powered answers.

