Flush DNS in Windows
The following methods allow you to remove old and inaccurate DNS information that may result in 404 or other errors.
Windows 8, 8.1 and 10
- On your keyboard, press Win+X to open the WinX Menu.
- Right-click Command Prompt and select Run as Administrator.
- Enter your password if prompted.
- Run the following command at the command prompt
ipconfig /flushdns
Windows 7
- Click Start.
- Enter cmd in the Start menu search text box.
- Right-click Command Prompt and select Run as Administrator.
- Enter your password if prompted.
- Run the following command:
ipconfig /flushdns
Windows XP, 2000, or Vista©
- Click Start.
- On the Start menu, click Run....
- If you do not see the Run command in Vista, enter run in the Search bar.
- Run the following command:
ipconfig /flushdns
The above command will completely flush the DNS, deleting any incorrect entries too. You can also use the command ipconfig /displaydns
to view the DNS resolver cache.
Flush DNS in Mac OSX
To clear your DNS cache if you use MacOS X, start by opening Terminal by performing the following steps:
- Click Applications.
- Click Utilities.
- Double-click Terminal.
- Run the applicable below command:
OS X 10.10 Yosemite
sudo discoveryutil mdnsflushcache;sudo discoveryutil udnsflushcaches;say flushed
OS X 10.9 Mavericks
sudo dscacheutil -flushcache;sudo killall -HUP mDNSResponder
OS X 10.7 Lion and 10.8 Mountain Lion
sudo killall -HUP mDNSResponder
OS X 10.5 Leopard and 10.6 Snow Leopard
sudo dscacheutil -flushcache
OS X 10.3 Panther and 10.4 Tiger
sudo lookupd -flushcache
Flush DNS in Linux
In Linux, the nscd daemon manages the DNS cache. To flush the DNS cache, restart the nscd daemon.
sudo /etc/init.d/nscd restart