Your computer caches DNS results locally to avoid repeating the same lookup every time you visit a site. When DNS records change, a new server IP, updated nameservers, a fixed A record, your local cache may still serve the old answer for hours. Flushing the DNS cache forces your system to discard stored records and fetch fresh ones on the next request.
You should flush your DNS cache when:
Note: flushing your local cache only removes your machine's stored records. If your ISP's resolver still has an old record cached, you'll get the old answer again from that resolver. Querying a public resolver like 8.8.8.8 directly is a useful way to test what the wider internet sees.
Open Command Prompt as Administrator. Search for "cmd" in the Start menu, right-click, and select "Run as administrator".
ipconfig /flushdns
You should see: Successfully flushed the DNS Resolver Cache.
On Windows 10 and 11 you can also flush from PowerShell (no admin required for PowerShell method):
Clear-DnsClientCache
To view what's currently in your Windows DNS cache before flushing (useful for debugging):
ipconfig /displaydns
To reset all network-related caches (including Winsock, which can sometimes interfere with DNS resolution):
netsh winsock reset netsh int ip reset ipconfig /flushdns ipconfig /release ipconfig /renew
Open Terminal (Applications > Utilities > Terminal) and run the appropriate command for your macOS version.
macOS Monterey, Ventura, Sonoma (and most versions since High Sierra):
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
You'll be prompted for your password. No output message means it worked successfully. Some older macOS versions require a slightly different command:
# macOS Sierra and earlier sudo killall -HUP mDNSResponder # macOS Yosemite sudo discoveryutil mdnsflushcache
To verify mDNSResponder is the active DNS service on your Mac:
sudo lsof -i :53
Linux DNS caching depends on which service is running. Most modern distributions use systemd-resolved.
Check which DNS service is running:
systemctl status systemd-resolved
If systemd-resolved is active:
sudo systemd-resolve --flush-caches
Verify the flush worked:
sudo systemd-resolve --statistics
If you're using nscd (Name Service Cache Daemon):
sudo service nscd restart
If you're running dnsmasq:
sudo service dnsmasq restart
On some minimal Linux setups with no local DNS caching service, there's nothing to flush, DNS queries go directly to the configured resolver each time.
Chrome maintains its own DNS cache independently of the operating system. Even after flushing the system cache, Chrome may still serve old records until its internal cache is cleared. This is a common source of confusion, you flush the system cache, but Chrome still shows the old site.
chrome://net-internals/#dnsFirefox also caches DNS. To clear it: type about:networking#dns in the address bar and click Clear DNS Cache.
Once your local cache is flushed, your next DNS query goes to your configured resolver (usually your ISP's, or a service like 8.8.8.8 or 1.1.1.1). That resolver then checks its own cache. If the change hasn't propagated to your resolver yet, you'll still see the old record, but this time it's the resolver's cache holding things up, not yours.
To test independently of your resolver's cache, query a public resolver directly:
nslookup yourdomain.com 8.8.8.8
If this returns the new IP, Google's resolver has updated. If your browser still shows the old site after flushing your system cache, try also clearing Chrome's internal DNS cache and restarting the browser.
Register your domain directly with HostBible and it connects to your hosting automatically. No DNS propagation headaches, no manual configuration needed.
Register a Domain