Ever clicked on a website and it refuses to load even though your internet is working fine? Or maybe a site shows an outdated version even after it has been updated?
These issues often come from something called DNS cache.
Windows stores temporary DNS records to help websites load faster, but sometimes this saved data becomes outdated or corrupted. When that happens, clearing it—also known as flushing DNS cache—can instantly fix browsing problems.
In this guide, you’ll learn how to flush DNS cache using CMD on Windows, why it matters, and when you should do it.
What Is DNS Cache?
DNS stands for Domain Name System.
Think of it as the internet’s phonebook:
- Websites like
google.comare translated into IP addresses - Your PC stores these translations in a temporary memory called DNS cache
This helps:
- Load websites faster
- Reduce repeated DNS lookups
- Improve browsing efficiency
But over time, this cache can:
- Become outdated
- Store incorrect IP addresses
- Cause connection errors
That’s when flushing DNS becomes useful.
Why You Should Flush DNS Cache
Flushing DNS cache can help fix:
- Websites not loading
- “Server not found” errors
- Slow internet browsing
- Changed website not showing updates
- Network connection issues after switching Wi-Fi
It’s a safe and quick troubleshooting step that often resolves issues instantly.
How to Flush DNS Cache Using CMD
Follow these simple steps carefully.
Step 1: Open Command Prompt (CMD)
You need administrator access.
Method 1:
- Click Start Menu
- Type
cmd - Right-click Command Prompt
- Select Run as Administrator
Method 2:
- Press Windows + R
-
Type:
cmd - Press Ctrl + Shift + Enter
Step 2: Run the DNS Flush Command
Type the following command:
ipconfig /flushdns
Step 3: Press Enter
After pressing Enter, Windows will clear your DNS cache.
Step 4: Confirm the Result
You should see a message like:
Windows IP Configuration
Successfully flushed the DNS Resolver Cache.
This confirms the process was successful.
What Happens After Flushing DNS?
Once you flush DNS cache:
- Your system removes old website IP records
- Fresh DNS data is fetched when you visit websites again
- Websites may load slightly slower the first time afterward
- Internet issues caused by bad cache are usually fixed
Real-World Example
Imagine this scenario:
You recently changed your website hosting, but your computer still shows the old version.
Problem:
- Old DNS record stored in cache
- Browser keeps loading outdated server
Solution:
Run:
ipconfig /flushdns
Now your PC fetches the updated version of the website.
When Should You Flush DNS Cache?
You don’t need to do it daily. Instead, use it when:
- Websites suddenly stop opening
- Internet behaves strangely after switching networks
- You cannot access a site that others can
- You recently changed DNS settings
- You suspect network glitches
Bonus: View Current DNS Cache
Before flushing, you can view stored entries:
ipconfig /displaydns
This shows a list of cached domains stored on your system.
Pros and Cons of Flushing DNS
Pros
- Fixes browsing issues quickly
- Improves network troubleshooting
- Safe and reversible
- Helps load updated website content
Cons
- First website load may be slightly slower afterward
- Does not fix deeper network or ISP issues
- No permanent performance boost
Common Mistakes to Avoid
- Running CMD without admin rights
- Typing the command incorrectly
- Expecting speed improvement instead of troubleshooting fix
- Flushing DNS too frequently without reason
Frequently Asked Questions (FAQ)
1. Is flushing DNS safe?
Yes, it is completely safe and does not harm your system.
2. How often should I flush DNS?
Only when you experience network or browsing issues.
3. Does it improve internet speed?
Not directly. It mainly fixes errors, not speed.
4. Do I need internet to flush DNS?
No, the command works offline.
5. Will it delete my browsing history?
No, it only clears DNS records, not browser data.
Final Thoughts
Flushing DNS cache using CMD is one of the simplest yet most effective troubleshooting tricks in Windows. With just a single command—ipconfig /flushdns—you can resolve many common internet issues without installing any software or changing complex settings.
It’s a small command, but it can make a big difference when your internet starts acting up.
If you often troubleshoot network issues, this is one CMD skill worth remembering.