Skip to content
Follow
Windows 🟡 Intermediate

How to Clear DNS Cache and Fix Network Connection Issues in Windows 11

Richard
Written by
Richard
Updated 12 min read
How to Clear DNS Cache and Fix Network Connection Issues in Windows 11
How to Clear DNS Cache and Fix Network Connection Issues in Windows 11
Before you start
  • 70 steps
  • Needs administrator rights
  • Includes a restart or sign-out

Clearing the DNS cache in Windows 11 helps when web pages fail to load even though you are connected to the internet. The DNS (Domain Name System) cache works like an address book. It saves the IP addresses of websites you have visited so they load faster next time.

Advertisement

Over time, old or broken entries build up in this cache and cause loading errors and failed connections. Running ipconfig /flushdns in Windows Terminal or Command Prompt deletes those records. Windows then fetches fresh, working addresses the next time you visit a site. The cache rebuilds on its own, so nothing is lost and you do not need to restart.

⚡ Quick Answer

To clear the DNS cache in Windows 11, open Command Prompt as administrator, type ipconfig /flushdns and press Enter. You should see a message saying the DNS Resolver Cache was successfully flushed. Windows then looks up fresh addresses the next time you visit a site, so you do not need to restart.

Advertisement

How to Clear the DNS Cache in 🪟 Windows 11

This is the quickest fix to try first. You open Command Prompt as an administrator, run the flush command, and Windows forgets every saved website address. It looks each one up again from the internet when you next need it. You need an administrator account, because the command is refused in a normal window.

  1. Click the Start button on your taskbar .
  2. Type cmd into the search box. Command Prompt appears in the search results.
  3. Right-click Command Prompt and select Run as administrator.
  4. Click Yes if the User Account Control prompt asks whether to allow the app to make changes. A black window opens.
  5. Type the following text into the window exactly as shown:
    ⬛Command Prompt
    ipconfig /flushdns
  6. Press Enter. You should see a message saying the DNS Resolver Cache was successfully flushed.
  7. Close the window, open your web browser, and visit a website to see if the connection works now.

If you prefer Windows Terminal, right-click the Start button and choose the Terminal (Admin) entry. The command works the same way there. Expect the first visit to each site to be a fraction slower while the cache fills up again. There is nothing to undo.

Advertisement

Running the Built-In Network Troubleshooter

The built-in network troubleshooter checks your adapters and connection settings and tries to repair what it finds. It needs no technical knowledge. It will not fix everything, but it is a quick and safe thing to run before you try anything stronger.

  1. Click the Start button and open the Settings app (the gear icon).
  2. Click System on the left side of the window.
  3. Click Troubleshoot on the right side.
  4. Click Other troubleshooters. A list of troubleshooters appears.
  5. Find Network and Internet in the list.
  6. Click the Run button next to it.
  7. Follow any instructions that appear while Windows checks your connection. If it applies a fix, it tells you what it changed. If it finds nothing, move on to the next section.

Basic Steps to Fix Wi-Fi and Internet Connection Issues

If your internet stops working on Windows 11 version 23H2, a few basic checks often bring the connection back. Work through these 3 steps in order before you move on to the advanced fixes. They take only a minute or two.

Step 1Check Your Network Connection Status

Look at the network icon in the bottom-right corner of your screen, near the clock. If you see a globe with a small cross, a triangle with an exclamation mark, or a red X, Windows knows it is not connected to the internet.

Advertisement

A normal Wi-Fi or Ethernet icon with no warning mark means the link to your router is working. In that case the problem is more likely DNS or a setting, so the DNS flush earlier in this guide is a good next step.

Step 2Check Airplane Mode

Airplane mode turns off all wireless hardware at once, including Wi-Fi and Bluetooth. If it is on by accident, no wireless signal gets through, so this is worth checking early. It is a common cause on laptops, where a function key or a physical switch can turn it on without you noticing.

  1. Click the network, volume and battery icons at the right end of the taskbar to open the Quick Settings panel. You can also press the Win plus A.
  2. Look at the Airplane mode button. If it is highlighted, it is on.
  3. Click Airplane mode to turn it off. The Wi-Fi button should become available again.
  4. Click the Wi-Fi button if it is off, then select your network and wait for it to reconnect.

Step 3Forget and Reconnect to the Wi-Fi Network

⚠️WarningForgetting a Wi-Fi network removes its saved settings and password.

When you reconnect, Windows starts fresh. This fixes problems caused by corrupted connection settings or a password that changed on the router. Make sure you have the Wi-Fi password to hand before you start.

Advertisement
  1. Open Settings and click Network & internet.
  2. Click Wi-Fi .
  3. Click Manage known networks. A list of saved networks appears.
  4. Find your home network in the list and click the Forget button next to it.
  5. Go back to your Wi-Fi settings and select your network.
  6. Type your password again and click Connect.

Step 4Restart Your Modem and Wireless Router

Restarting your modem and router clears temporary hardware glitches and makes the modem reconnect to your service provider. Routers run for weeks without a break and can get stuck, so this fixes more problems than you would expect. If you have a separate modem and router, do both.

  1. Unplug the power cable from the back of your modem and your router.
  2. Wait at least 30 seconds. This gives the devices time to fully drain and reset.
  3. Plug the power cables back in. If you have two devices, plug in the modem first, then the router.
  4. Wait a few minutes for the lights on the devices to turn solid green or blue.
  5. Check your computer to see whether the connection is back.

Step 5Adjust Wi-Fi Channel and Frequency

Wi-Fi drops can come from interference. Neighbouring networks, cordless phones, microwaves and other household devices can crowd the same radio channels your router uses. Modern routers let you move between the crowded 2.4 GHz band and the faster 5 GHz band, and you can also change the channel.

Advertisement

To do this, log in to your router settings from a web browser. The router address and login are usually printed on a label on the router. The menus differ by brand, so look for the wireless or Wi-Fi settings page. As a rule, 5 GHz is faster and less crowded but does not reach as far through walls. 2.4 GHz reaches further but is slower and more prone to interference. If your PC loses signal only in one room, try the other band.

Step 6Try to Connect to the Same Network on a Different Device

This test tells you whether the problem is your PC or your internet service. Connect a smartphone or another computer to the same Wi-Fi network and try to open a website.

If other devices also cannot get online, the issue is likely your router or your internet service provider, not your Windows 11 PC. In that case, restart the router as described above, or contact your provider. If the other devices work fine, the fault is on your PC, and the Windows fixes below are the right path.

Step 7Run Advanced Network Commands

These commands reset parts of the Windows network stack and release your current IP address so Windows can request a new one. Use them when the basic fixes have not helped. You need to run Command Prompt as an administrator.

Advertisement
  1. Open Command Prompt as an administrator (refer to the steps earlier in this guide). (Admin privileges required)
  2. Type the following command and press Enter:
    ⬛Command Prompt
    ipconfig /release
  3. Next, type this command and press Enter:
    ⬛Command Prompt
    ipconfig /renew
  4. Finally, type this command to reset your internet protocol settings and press Enter:
    💻Code
    netsh int ip reset
  5. Restart your computer. The reset does not fully take effect until you do.

You may briefly lose your connection while the commands run. That is normal. It should return after the restart.

Step 8Uninstall the Network Adapter Driver and Restart

A corrupted network adapter driver can stop your PC from talking to Wi-Fi or Ethernet at all. Uninstalling the driver removes the bad copy. Windows normally installs a fresh, working one when the PC restarts. Do this when other fixes fail.

  1. Right-click the Start button and select Device Manager. (Admin privileges required)
  2. Click the arrow next to Network adapters to expand the list.
  3. Find your wireless or Ethernet network adapter in the list.
  4. Right-click it and choose Uninstall device. A confirmation window opens.
  5. Check the box that attempts to remove the driver for this device, then click Uninstall.
  6. Restart your computer. Windows should reinstall a fresh, working driver when it boots back up.
Advertisement

If the adapter does not come back after the restart, open Device Manager again and use Action Scan for hardware changes. If it still does not appear, download the driver from your PC or adapter maker on another device and install it from there. It helps to know this before you start, since you may have no connection on the affected PC.

Step 9Use the Ping Test to Check Router Connection

A ping test shows whether your computer can talk to your router over the local network. It sends a few small packets and reports whether replies come back. You do not need administrator rights for this one.

  1. Open Command Prompt normally.
  2. Type ping 192.0.2.1 (or your specific router gateway address) and press Enter.
  3. Read the result. If you see replies coming back, your computer is successfully talking to your router. If you see request timed out messages, there is a physical communication block between your computer and your router.

Steady replies with no lost packets are what you want. If packets are lost on some lines, the connection is unreliable. Check the Wi-Fi signal and the cables, and try the router restart again.

Step 10Disable Power Saving for the Wi-Fi Adapter

To save battery, Windows can switch off your Wi-Fi adapter when it thinks it is idle. On some hardware this causes sudden disconnects or a connection that will not wake up. Turning this option off stops it. The cost is slightly more battery use on a laptop.

  1. Open Device Manager from the Start menu. (Admin privileges required)
  2. Expand Network adapters.
  3. Right-click your wireless network adapter and select Properties.
  4. Click the Power Management tab at the top of the window. If you do not see this tab, your adapter does not support the setting.
  5. Uncheck the box that says Allow the computer to turn off this device to save power.
  6. Click OK.

To undo this, follow the same steps and tick the box again.

Step 11Check for Windows Updates

Microsoft frequently releases updates that fix known software bugs, including network connection problems. Updates can also bring newer network drivers.

  1. Open Settings.
  2. Click Windows Update.
  3. Click Check for updates. Windows searches for and downloads anything available.
  4. Restart your PC if Windows asks you to.

If you have no connection at all, you may need to run the check from another network, such as a phone hotspot. Under Advanced options Optional updates, you may also find a network driver update.

Step 12Restart Your PC

It sounds simple, but restarting your computer clears out temporary working memory and stops background tasks that might be interfering with your network connection. Choose Restart from the power button in the Start menu rather than Shut down. A normal shutdown with Fast Startup enabled does not fully reset Windows, but a restart does.

Step 13Use Network Reset

⚠️WarningNetwork reset puts all your network settings back to their original state and reinstalls your network adapters.

Use it as a last resort, because it removes saved Wi-Fi networks and may remove VPN adapters or virtual switches you set up. Have your Wi-Fi password ready and save your work first.

  1. Open Settings and go to Network & internet.
  2. Click Advanced network settings.
  3. Click Network reset.
  4. Click the Reset now button, then confirm your choice when asked.
  5. Wait for your computer to restart. Windows warns you that it will restart shortly, and it does so automatically.
  6. After it restarts, reconnect to your Wi-Fi and type your password again.

Unique Expert Tips: Fixing Hidden DNS Leaks and Browser Interference

If standard fixes have not worked, look at what sits between your apps and the network. Persistent problems often come from active VPN software or from internal browser caches that bypass your main Windows settings. The next two checks cover both.

Checking for Virtual Private Network (VPN) and Proxy Interference

VPN and proxy software can leave behind settings that block normal web traffic, even after you close the app. This is common after a VPN crashes or is uninstalled badly. Check them in this order:

  1. Open your VPN application and make sure it is completely closed or signed out.
  2. Open Windows Settings and click Network & internet.
  3. Click VPN and make sure no active connections are running.
  4. Go back and click Proxy. Make sure manual proxy setup is turned off unless your workplace specifically requires it.
  5. Try a website again.

Clearing Web Browser DNS Cache Separately

Google Chrome and Microsoft Edge keep their own DNS cache, separate from the one in Windows. That means a site can still fail to load after you flush the Windows cache. You clear the browser cache from a hidden internal page.

To clear the internal DNS cache in Google Chrome or Microsoft Edge:

  1. Open your web browser.
  2. Type chrome://net-internals/#dns (for Chrome) or edge://net-internals/#dns (for Edge) into the address bar and press Enter.
  3. Click the Clear host cache button.
  4. Click Sockets on the left side menu.
  5. Click Flush socket pools.
  6. Reload the website that was failing.

This ensures that both your operating system and your web browser are free of old, broken website addresses.

Summary

Most internet and network problems on Windows 11 start with clearing the DNS cache from Command Prompt. If that does not work, run the built-in troubleshooter, restart your modem and router, adjust your Wi-Fi settings, or reset your network entirely. Work from the simple fixes towards the more drastic ones, and use the network reset only when the rest have failed.

Have a question about this guide?

Answered by AI from this guide. Good questions may be added to this page — please don't include personal details.

Tags: #Windows 11

Did this guide fix your problem?

Richard

About the Author

Richard

Tech Writer, IT Professional

Richard is a writer at Geek Rewind who turns complex IT tasks into clear, step-by-step guides. He draws on years of hands-on experience in system administration and enterprise IT operations, focusing on Windows, Linux and WordPress: the problems people actually run into, and the fixes that work. His server and WordPress guides come from systems he runs himself. Richard builds and maintains the platform behind Geek Rewind, from its Ubuntu servers and Nginx configuration to its custom WordPress plugins. Many new tutorials start with readers' questions, and he's always glad to answer them in the comments.

Advertisement

No comments yet — be the first to share your thoughts!

Leave a Comment

Your email address will not be published. Required fields are marked *