How do I flush DNS cache on my computer?
This HostMySite Support Article provides information on how to flush DNS cache on a computer running Microsoft Windows OS or Mac OS.
DNS is an acronym for Domain Name System (also referred to as Domain Name Service).
When a computer visits a website for the first time, it stores the website’s DNS information in its computer memory cache which includes:
The website’s hostname, the public-facing website name entered or linked to from your web browser
The IP Address, which is a numerical label assigned to the hostname or website. This IP format includes 4 sets of numbers, separated by dots or periods. Some examples of IP addresses would be 172.16.254.1 or 127.0.0.1
So, the next time your computer visits the website, it looks in its memory cache to see if the website’s DNS information is still referenced for use. This can cause problems if the website’s DNS information has changed since the computer’s last visit. Flushing the cache removes all the stored information, forcing the computer to find the new or latest DNS information for the website.
To flush DNS for a computer running Microsoft Windows, follow these steps:
- On your local PC, open a command prompt.
In Windows this may be done by entering “CMD” in the Start Menu’s Search Field. - Within the prompt, type ipconfig /flushdns as shown in the graphic below:
Result: You should see the following message:
“Windows IP Configuration
Successully flushed the DNS Resolver Cache.”
To flush DNS for a computer running Mac OS, please follow these steps:
- On your Mac computer, open a terminal window by navigating to the Applications folder, then Utilities, then open the Terminal application.
- Within the prompt, type lookupd -flushcache.