This action will ensure that Chrome fetches fresh DNS data from the websites you visit.
Table of Contents
How to Flush DNS on Different Operating Systems
How to Flush DNS on Windows 10 & 11
Clearing the DNS cache is safe and does not affect your saved passwords, browser history, or other personal data. It removes outdated DNS information, ensuring your computer can fetch up-to-date DNS records.
- Click on Start, then search for Command Prompt. Right-click it and select “Run as Administrator.”
- Once the Command Prompt is open, type
ipconfig /flushdns
and press Enter. - A message will appear confirming that the DNS Resolver Cache was flushed.
If you’re using a Linux distro such as Ubuntu, here’s how to flush the DNS cache:
How to Perform an IP Release, Renew, and DNS Flush on Windows
- Open Command Prompt with administrative privileges.
- Type
ipconfig /release
and press Enter to release the current IP address. - Next, type
ipconfig /renew
to obtain a new IP address. - Finally, type
ipconfig /flushdns
to clear the DNS cache.
How to Flush DNS on macOS
Do you regularly flush your DNS cache? Let us know if you have any tips or questions! Join the conversation below by leaving a comment! 💬
- Press cmd + space to open Spotlight Search.
- Type Terminal and open the application (you can also find it in the Other section in the Launchpad).
- Type the following command:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
. - Enter your administrator password when prompted. Once you do, you will receive confirmation that the DNS cache has been flushed.
There are several reasons why flushing the DNS cache periodically is important:
- Click on the Apple menu in the upper-left corner of your screen.
- Select About This Mac.
DNS cache is crucial in speeding up internet access and improving browsing experiences by storing recent domain name lookups and their corresponding IP addresses.
- Monterey, Big Sur, Catalina:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
- Mojave, High Sierra, Sierra, El Capitan, Mavericks, Mountain Lion, Lion:
sudo killall -HUP mDNSResponder
How to Flush DNS on Linux
RunCloud supports various web servers, PHP versions, databases, and frameworks. You can also monitor your server performance, back up your data, and automate your tasks with RunCloud. Whether you are a developer, a freelancer, or a business owner, RunCloud can help you run your websites faster and smoother.
- Open the terminal by pressing Ctrl + Alt + T or searching for “Terminal” in the Activities menu.
- Run the following command:
- If you are running Ubuntu 20.04 LTS or older, use:
sudo systemd-resolve --flush-caches
. - If you are running Ubuntu 22.04 LTS or newer, use:
sudo resolvectl flush-caches
.
- If you are running Ubuntu 20.04 LTS or older, use:
- Enter your administrator password when prompted, and the DNS cache will be flushed.
How to Flush DNS Cache in Google Chrome
After making changes to your DNS records, such as transferring a domain to a new hosting provider, DNS propagation can take time to fully update across the internet. Flushing your DNS cache ensures that your device picks up these changes more quickly, allowing you to see the updates sooner.
- Type
chrome://net-internals/#dns
in the address bar and press Enter. - Click the Clear Host Cache button to flush the browser’s DNS cache.
RunCloud is a powerful and easy-to-use platform that helps you manage your websites on any cloud server. With RunCloud, you don’t need to be a Linux expert to set up, secure, and optimize your web applications. You can do everything from a simple and intuitive dashboard, saving you time and hassle.
Why Should You Flush Your DNS Cache?
When you change DNS providers, such as switching to Google DNS or OpenDNS, it’s important to flush your DNS cache. This ensures that your system doesn’t use outdated data from the previous provider, helping to prevent connectivity issues.
Resolve DNS Errors
Clearing this cache periodically can enhance your browsing speed and resolve connectivity issues.
Speed Up DNS Propagation
After running the appropriate command to flush the DNS cache (such as ipconfig /flushdns
on Windows), your system usually displays a message confirming that the DNS Resolver Cache was successfully flushed.
Prevent DNS Spoofing
If you experience issues accessing websites on Google Chrome, your browser’s DNS cache may also need to be flushed. Here’s how to do it:
Avoiding 404 Errors
There’s no hard rule on how often you should flush the DNS cache, but it’s a good idea to do it when you experience connection issues or DNS errors or after making changes to your network configuration (such as switching DNS providers).
Remove Old DNS Data
Note: The command can vary depending on your macOS version. Here’s how to check your macOS version:
After Action Report – Flush Your DNS Cache Periodically
DNS spoofing (or poisoning) occurs when an attacker manipulates DNS cache entries to redirect users to fraudulent or malicious websites. Flushing your DNS cache helps mitigate this risk by clearing any potentially corrupted entries.Depending on your macOS version, use the appropriate command:
Wrapping Up
Modern operating systems generally cache DNS lookup results and IP addresses to process requests more quickly. Whenever you write a URL in your browser, it sends a request to the DNS servers to “locate” the site. But instead of sending that request every single time, the browser often caches the information. This way, the next time you type in that address, the browser looks it up through the DNS cache, allowing it to return the results much faster.What are you waiting for? Join RunCloud today and enjoy the best web hosting solution for your websites. It’s free for 7 days, no strings attached! Flushing the DNS cache on macOS involves using the Terminal app. Follow these steps: