3 Ways To Flush DNS in Windows (Easily)

It’s quite common that you sometimes get redirected to a different website when trying to open a specific site or get an error 404 while opening a site. Most often you can fix all of these with a simple fix.

How to Flush DNS In Windows

How to flush DNS in Windows

In this, I am going to talk about DNS cache and why it is recommended to flush DNS regularly. 

What Is DNS Cache

DNS cache is basically a temporary database, containing details like your recent browsing history, attempts to visit any site, and a few other internet activities. This enables your computer to quickly refer to it and figure out what to load on the website. Sometimes you would have noticed you come back to the exact same page of a website when you open it again, that’s because of the DNS cache. 

Why Flushing DNS Is Important

DNS flushing is important to solve technical problems, for security and data privacy. You will prevent DNS spoofing, which has become a common practice. You can solve technical problems like a 404 error, or anything which prevents you from visiting a site. 

You’ll also save yourself from possible data breaching and theft. Overall, it’s always recommended to flush DNS regularly. 

1. Flush DNS Using Windows Command

DNS flush uisng run

This is the simplest method to perform DNS flushing. Here’s how you can do it. 

  • Press Windows key and “R” together to open the Run dialog box.
  • Type “ipconfig /flushdns” and hit Enter 
  • A command box will flash for a fraction of a second on the screen and the DNS cache will be cleared. 

2. Using Command Prompt 

DNS flush uisng command prompt

This method is very similar to the first one, but we’ll use Command Prompt for it. To perform, follow the below steps. 

  • Click on the start menu and type “CMD”.
  • Right click on the command prompt application and choose “Run as administrator”.
  • Type “ipconfig /flushdns” and hit Enter.
  • You’ll see the message “Successfully flushed the DNS Resolver Cache”.

3. Using Powershell 

DNS flush uisng powershell

Just like the CMD method, we are going to use a command here to flush DNS. Let’s see the steps. 

  • Type “Powershell” in the windows search option. 
  • RIght click on the Powershell app and select “Run as administrator”. 
  • Type the command “Clear-DnsClientCache” and hit Enter. 
  • If you don’t get any error then DNS has been flushed successfully. 

Also Read: Ways To Uninstall Windows Updates

FAQs

What does flushing the DNS do?

DNS flushing will clear all your DNS cache which stores your browsing history on specific sites, your entries, and all the data which helps the computer identify and find websites.

Does the DNS cache clear on reboot?

No, by default DNS cache doesn’t clear on reboot. 

Is it safe to flush DNS?

Yes. It is completely safe and recommended to flush DNS. 

Default image
Satish Shah
Member of Team TJ - Tech Enthusiast, and Programmer

Leave a Reply