DNS cache stores website addresses on your device so it doesn’t have to look them up every time. Clearing it is simple: use your system settings or run a single command. Most people need to do this when a website won’t load properly, after switching to a new internet provider, or following a domain change. The process takes under two minutes.
What Is DNS Cache and Why It Matters
Your device has a memory system that saves website addresses. When you type a website name like google.com, your computer doesn’t search the entire internet. It checks its own DNS cache first. If the address is there, the site loads instantly.
Sometimes this cache gets outdated. A website might move to a new address, but your device still points to the old one. This causes loading errors or shows old versions of websites. Clearing the DNS cache forces your device to fetch fresh, current information.
Think of it like your phone’s contact list. If a friend changes their phone number but you don’t update it, you’ll reach the wrong number. Clearing DNS cache is like refreshing that contact information.
Common Reasons to Clear DNS Cache
Your website won’t load even though other people can access it. You see an old website version after an update. You switched internet providers. You’re troubleshooting network connection problems. A domain recently changed servers. You’re experiencing slow browsing despite good internet speed.
How to Clear DNS Cache on Windows

Windows 10 and Windows 11
Open Command Prompt as an administrator. Press the Windows key and type “cmd” without quotes. Right-click on Command Prompt and select “Run as administrator.”
Copy and paste this command:
ipconfig /flushdns
Press Enter. You’ll see a message saying “Windows IP configuration has been flushed successfully.”
That’s it. Your DNS cache is now cleared.
Alternative Method for Windows
Some people prefer using the graphical interface. Open Settings. Go to System, then Network and Internet. Scroll down and click “Advanced network settings.” Select “More network options.” Click “Network settings” or “Change adapter options.” Right-click your active network connection and select Properties. This doesn’t directly clear DNS but ensures your connection refreshes properly.
For most situations, the Command Prompt method works faster and more completely.
How to Clear DNS Cache on macOS
Mac Using Terminal
Open Terminal. You can find it in Applications > Utilities or press Command + Space and type “terminal.”
For macOS Monterey and newer versions, paste this command:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
For older Mac versions (Big Sur and earlier), use:
sudo dscacheutil -flushcache
Press Enter. You’ll be asked for your password. Type it and press Enter again. The cache clears silently without confirmation.
Your DNS cache is now cleared.
What If You See an Error
If you see a “command not found” error, try this alternative command:
sudo killall -HUP mDNSResponder
This accomplishes the same goal using a different approach. Both commands work equally well.
How to Clear DNS Cache on Linux
Linux users have several methods depending on their system type.
Using systemd-resolve (Modern Linux Systems)
Open Terminal and paste:
sudo systemd-resolve --flush-caches
Press Enter. Enter your password when prompted.
Using BIND (Older Systems)
Some systems use BIND as their DNS resolver. Use this command:
sudo rndc flush
Using Nscd
If your system uses Nscd, try:
sudo systemctl restart nscd
Different Linux distributions use different DNS systems. If you’re unsure which one you have, contact your system administrator or check your Linux distribution’s documentation.
How to Clear DNS Cache on iPhone and iPad
iOS devices handle DNS caching differently. The easiest method is resetting your network settings.
Go to Settings. Select General. Tap Reset. Choose “Reset Network Settings.” Enter your device passcode when prompted. Tap “Reset Network Settings” again to confirm.
Your device restarts and clears all network settings, including DNS cache.
Warning: This also removes saved WiFi networks and passwords. You’ll need to reconnect to WiFi afterward by entering passwords again.
Faster Alternative
If you don’t want to reset all network settings, simply toggle Airplane Mode on and off. Go to Settings and tap the Airplane Mode toggle. Wait five seconds. Tap it again to turn it off. This refreshes your DNS connection without clearing stored networks.
How to Clear DNS Cache on Android
Android devices don’t store DNS cache the same way as computers. The main method is restarting your phone.
Power off your device completely. Wait ten seconds. Power it back on. This clears temporary DNS data.
Alternative Method
Go to Settings. Select Apps or Application Manager. Find Chrome (or your web browser). Tap Storage. Select “Clear Cache.” This clears the browser’s DNS cache specifically.
For network-level clearing, some Android phones let you change DNS settings manually:
Go to Settings. Select WiFi. Long-press your WiFi network. Choose Modify Network. Switch to Advanced Options. Find DNS and set it to 8.8.8.8 (Google DNS) or 1.1.1.1 (Cloudflare DNS). Save the changes. This forces your device to use fresh DNS lookups.
How to Clear DNS Cache on Chromebook
Chromebooks handle DNS caching through Chrome itself.
Open Chrome. Press Ctrl + Shift + Delete to open your browsing data window. Select “All time” in the time range dropdown. Check “Cookies and other site data.” Uncheck everything else. Click “Clear data.”
Alternatively, open a New Tab. Type chrome://net-internals/#dns in the address bar. Click “Clear host cache.” This specifically clears DNS records from Chrome.
Clear DNS Cache in Your Web Browser
Your browser stores its own DNS cache separately from your operating system.
Chrome
Open Chrome settings. Click Privacy and Security. Choose “Clear browsing data.” Set the time range to “All time.” Check “Cookies and other site data.” Uncheck other options. Click “Clear data.”
Firefox
Click the hamburger menu (three lines). Select History. Click “Clear Recent History.” Set time range to “Everything.” Check “Cookies” and “Active Logins.” Click “Clear Now.”
Safari
Click Safari in the menu. Select “Preferences.” Go to the Privacy tab. Click “Manage Website Data.” Select all websites and click “Remove.” This clears Safari’s DNS and site data cache.
Edge
Click the three-dot menu. Select “Settings.” Go to “Privacy, search, and services.” Under “Clear browsing data,” click “Choose what to clear.” Set time to “All time.” Check “Cookies and other site data.” Click “Clear now.”
Clearing browser-level DNS helps when websites specifically aren’t loading properly in that browser.
When to Clear DNS Cache at the Router Level
Your router also maintains DNS cache. This affects all devices connected to it.
Restart Your Router
Unplug your router’s power cable. Wait 30 seconds. Plug it back in. Wait for all lights to stabilize, usually two to three minutes. All connected devices will now use fresh DNS lookups.
This is the most effective method for clearing DNS network-wide.
Access Router Settings
Some routers let you manually clear DNS without restarting.
Open a web browser. Type 192.168.1.1 or 192.168.0.1 in the address bar. Log in with your router’s admin username and password. Find the DNS settings section. Look for options like “Flush DNS” or “Clear Cache.” Click to clear.
Different router models use different menus. Check your router’s manual for exact steps.
DNS Cache Clearing Timing and Best Practices
Clear your DNS cache during low-activity periods if possible. Early morning or late evening works best. Avoid clearing during important work or streaming.
After clearing DNS cache, expect slight slowness for the first few website visits. Your device needs to fetch fresh DNS information. This takes seconds to minutes. Performance returns to normal quickly.
Clear your cache regularly if you work with many websites or do frequent testing. Monthly clearing maintains optimal performance. Clear immediately after website migrations or domain changes.
Document when you clear DNS cache, especially in business environments. This helps troubleshoot issues later. A simple note of the date and time suffices.
DNS Cache Clearing Methods by Device
| Device Type | Method | Time | Difficulty | Clears Router Cache |
|---|---|---|---|---|
| Windows | Command Prompt | 1 minute | Very Easy | No |
| macOS | Terminal | 1 minute | Very Easy | No |
| Linux | Terminal Command | 2 minutes | Easy | No |
| iPhone | Network Reset | 3 minutes | Easy | No |
| Android | Restart Phone | 1 minute | Very Easy | No |
| Router | Power Reset | 3 minutes | Very Easy | Yes |
| Chrome | Built-in Tool | 1 minute | Very Easy | No |
| Firefox | Built-in Tool | 1 minute | Very Easy | No |
Verification: How to Know If DNS Cache Was Cleared
After clearing, test by opening a website you haven’t visited recently. If it loads properly, the cache cleared successfully.
For technical verification on Windows, open Command Prompt and type:
ipconfig /displaydns
The list should be much shorter than before, showing fewer cached entries.
On macOS, open Terminal and check the DNS resolver status:
dns-sd -G v4 localhost.
This shows the current DNS configuration state.
These commands confirm the cache clearing worked at the system level.
Troubleshooting: What If DNS Cache Won’t Clear
If you run the clear command but websites still won’t load, try these steps.
Restart your device completely. Sometimes background processes prevent the cache from fully clearing. Full restart ensures all services reinitialize.
Clear your browser cache separately. System-level and browser-level caches are different. Both need clearing for complete results.
Check your DNS server settings. Go to your network settings and verify you’re using a reliable DNS server like Google (8.8.8.8) or Cloudflare (1.1.1.1). Corrupted DNS server settings prevent proper cache clearing.
Temporarily disable your VPN or proxy if you use one. These tools can interfere with DNS cache operations. Disable them, clear cache, then re-enable if needed.
Restart your router if the problem persists across all devices. Router-level DNS caching might be the culprit.
If none of these work, contact your internet service provider. They can check server-side DNS issues that client-side clearing won’t fix.
Advanced: Understanding DNS Propagation After Clearing Cache
When websites change servers, new DNS information spreads across the internet over time. This is called DNS propagation.
Clearing your cache makes your device fetch the new information immediately. However, other parts of the internet might still have old information. This is completely normal.
DNS propagation typically completes within 24 to 48 hours. Some changes propagate in minutes. Others take the full 48 hours.
If you’re waiting for a domain transfer or website migration, clearing DNS cache speeds up your access to the new location. Other users might still see the old location temporarily. This is expected behavior.
You can check DNS propagation status at https://dnschecker.org. Enter your domain name and see which DNS servers worldwide have received the new information. This shows the propagation progress.
Summary
Clearing DNS cache is a simple troubleshooting step that fixes many internet issues. Most devices can clear it in under two minutes using built-in tools.
Windows users use Command Prompt with ipconfig /flushdns. Mac users use Terminal with the dscacheutil command. Linux users use systemd-resolve commands depending on their system.
Mobile devices require either network resets or app-specific clearing. Routers need power restarts for network-wide DNS cache clearing.
Browser-specific DNS caches require separate clearing through each browser’s settings. Router-level caching affects all connected devices and clears when you restart the router.
After clearing DNS cache, reload your websites to verify the fix. Expect slight slowness initially as your device fetches fresh information. Normal speeds return within minutes.
Most internet loading issues resolve completely after clearing DNS cache. If problems persist, contact your internet service provider for further assistance.
Regularly clearing DNS cache every few months maintains network health. This becomes especially important for people who work with multiple websites or frequently test domain changes.
Frequently Asked Questions
Will clearing DNS cache delete my passwords or files?
No. DNS cache only stores website addresses, not passwords or personal files. Clearing it doesn’t affect stored data. It’s one of the safest troubleshooting steps you can perform.
How often should I clear DNS cache?
For typical users, clearing once every month to three months is sufficient. Heavy website workers or developers should clear monthly or even weekly. Most people don’t need to clear more than a few times yearly.
What’s the difference between DNS cache and browser cache?
DNS cache stores website addresses. Browser cache stores images, scripts, and page content. Both can cause loading issues but require different clearing methods. Clear both for complete results.
Can clearing DNS cache slow down my internet?
Temporarily, yes. For the first few minutes after clearing, your device needs to fetch fresh DNS information. This causes slight slowness on first visits to websites. Speed returns to normal quickly, usually within minutes.
Will clearing DNS cache fix all website loading problems?
No, but it fixes many common issues. If websites still won’t load after clearing DNS cache, the problem might be your internet connection, your ISP, or the website’s server itself. Try restarting your router or contacting your ISP if the issue persists.
