Updated June 2026

How to Change DNS on Windows 10 and 11

Four methods to change your DNS server: Settings app, Control Panel, PowerShell, and Command Prompt. Takes under five minutes.

Why Change DNS on Windows

Windows picks a DNS server for you automatically through your internet provider. That default server works, but it is almost never the fastest option your computer can use. ISP DNS servers handle traffic for thousands of subscribers at once. During peak hours, that shared load means slower lookups, occasional timeouts, and sometimes hijacked failed lookups that redirect you to ad pages.

Switching to a dedicated public DNS provider gives you two immediate benefits. First, faster domain resolution. Every website you visit triggers multiple DNS lookups — not just the main site, but also the CDN hosting images, font services, analytics scripts, and advertising networks. A modern page loads resources from 30 to 50 different domains. If your DNS adds 40 milliseconds to each lookup, that is 1.5 to 2 seconds of pure waiting before anything renders. A faster resolver cuts that down significantly.

Second, privacy. Most ISP DNS servers log every domain you visit and keep those logs for months. Some inject tracking into failed lookups. Providers like Cloudflare, Google, and Quad9 either purge logs within 24 hours or do not log personal data at all. The tradeoff is nothing — these services are free and do not require an account.

Changing DNS on Windows is also completely reversible. If the new server does not perform well, you can revert the setting in the same menu within seconds. There is no risk, no cost, and no software to install.

What You Need Before Starting

Decide which DNS server you want to use first. If you are not sure, here are three solid choices that work well for most people:

  • Cloudflare 1.1.1.1 — fastest global resolver, privacy-focused. Primary: 1.1.1.1, Secondary: 1.0.0.1
  • Google Public DNS — reliable, massive infrastructure. Primary: 8.8.8.8, Secondary: 8.8.4.4
  • Quad9 — blocks known malicious domains. Primary: 9.9.9.9, Secondary: 149.112.112.112

You only need to enter the primary address if you want to keep it simple. The secondary address acts as a backup if the primary is unreachable. Most systems try them in order.

For the most accurate pick, run our DNS speed test first. It measures real response times from your location across 17+ public resolvers. That way you are choosing based on data, not reputation.

Also worth noting: changing DNS on a single Windows device only affects that device. Every other device on your network keeps using the old DNS. If you want to update DNS for every device at once, do it at the router level instead.

Method 1: Windows Settings App

The Settings app is the most straightforward way to change DNS on Windows 10 and 11. It works on both versions with minor differences in menu names.

Windows 11

  1. Open Settings. Press Windows + I or click the Start menu and select the gear icon.
  2. Click Network & Internet in the left sidebar.
  3. Click Wi-Fi if you are wireless, or Ethernet if you use a wired connection.
  4. Click Hardware properties near the bottom of the page.
  5. Scroll to DNS server assignment and click Edit.
  6. In the dropdown, change Automatic (DHCP) to Manual.
  7. Toggle on IPv4.
  8. Enter your DNS addresses:
    • Preferred DNS: 1.1.1.1
    • Alternate DNS: 1.0.0.1
  9. If you want DNS over HTTPS, toggle that on and select On (automatic template). Windows will detect the provider's DoH template automatically.
  10. Click Save.

Windows 10

  1. Open Settings with Windows + I.
  2. Click Network & Internet.
  3. Click Status on the left, then click Change adapter options on the right.
  4. Right-click your active connection (Wi-Fi or Ethernet) and select Properties.
  5. Select Internet Protocol Version 4 (TCP/IPv4) and click Properties.
  6. Select Use the following DNS server addresses.
  7. Enter 1.1.1.1 as Preferred DNS and 1.0.0.1 as Alternate DNS.
  8. Click OK, then Close.

IPv6 (Optional)

If your connection supports IPv6, go back to the properties window and select Internet Protocol Version 6 (TCP/IPv6). Click Properties and enter:

  • Preferred DNS: 2606:4700:4700::1111
  • Alternate DNS: 2606:4700:4700::1001

These are Cloudflare's IPv6 addresses. Google's IPv6 equivalents are 2001:4860:4860::8888 and 2001:4860:4860::8844.

The Settings app method is the best choice for most people. It gives you the option to enable DNS over HTTPS directly, which encrypts your DNS queries so your ISP cannot see which domains you visit.

Method 2: Control Panel

The Control Panel method has been around since Windows XP. It still works on Windows 10 and 11, and some people prefer it because it opens the network adapter properties directly without navigating through multiple settings screens.

  1. Press Windows + R to open the Run dialog.
  2. Type ncpa.cpl and press Enter. This opens the Network Connections window, skipping several menu layers.
  3. Right-click your active connection — it will say "Wi-Fi" or "Ethernet" depending on what you use — and select Properties.
  4. In the list, find and select Internet Protocol Version 4 (TCP/IPv4).
  5. Click Properties.
  6. Select Use the following DNS server addresses.
  7. Enter your preferred and alternate DNS addresses.
  8. Click OK on the IPv4 properties window.
  9. If you also want to set IPv6, select Internet Protocol Version 6 (TCP/IPv6), click Properties, and enter the IPv6 addresses.
  10. Click Close on the connection properties window.

The ncpa.cpl shortcut is worth remembering. It works on every version of Windows and puts you directly at the adapter list without clicking through Settings or Control Panel menus.

One thing to watch out for: make sure you are editing the properties of the correct adapter. If you have both Wi-Fi and Ethernet, only one is active at a time. The inactive one will not affect your internet until you switch to it.

Method 3: PowerShell

PowerShell gives you a command-line way to change DNS without clicking through any menus. This is useful for scripting, remote management, or if you just prefer the terminal.

Set DNS Using NetAdapter

Open PowerShell as Administrator. Right-click the Start button and select Windows Terminal (Admin) or PowerShell (Admin). Then run these commands:

# Find your adapter name
Get-NetAdapter | Where-Object {$_.Status -eq "Up"} | Select-Object Name, InterfaceDescription

This lists all active network adapters. Look for the one that says "Wi-Fi" or "Ethernet" in the name or description. You need the exact adapter name for the next step.

# Set DNS servers
Set-DnsClientServerAddress -InterfaceAlias "Wi-Fi" -ServerAddresses ("1.1.1.1","1.0.0.1")

Replace "Wi-Fi" with your adapter name. If your adapter is named "Ethernet", use that instead. The command accepts multiple DNS addresses as a comma-separated list.

Revert to Automatic DNS

If you want to switch back to automatic DNS (DHCP-assigned), run:

Set-DnsClientServerAddress -InterfaceAlias "Wi-Fi" -ResetServerAddresses

Using netsh (Legacy)

The older netsh command also works, though Microsoft considers it legacy. Open Command Prompt or PowerShell as Administrator:

netsh interface ip set dns "Wi-Fi" static 1.1.1.1
netsh interface ip add dns "Wi-Fi" 1.0.0.1 index=2

The first command sets the primary DNS. The second adds a secondary DNS at index position 2. Replace "Wi-Fi" with your connection name. You can check your connection names with netsh interface show interface.

PowerShell commands require administrator privileges. If you get an "access denied" error, make sure you opened the terminal as Administrator.

Method 4: Command Prompt (ipconfig)

The Command Prompt offers a few DNS-related commands, but there is an important distinction: ipconfig can view and flush DNS, but it cannot directly change your DNS server addresses. For changing DNS via command line, use the PowerShell or netsh methods above. Here is what Command Prompt can do.

View Current DNS Settings

ipconfig /all

Scroll through the output and look for your active connection. Under the DNS Servers line, you will see the IP addresses your system is currently using. This is useful for checking whether your DNS change actually took effect.

Flush DNS Cache

ipconfig /flushdns

This clears the local DNS resolver cache. You need to do this after changing DNS servers so your system starts using the new resolver immediately instead of serving stale cached results. You will see the message "Successfully flushed the DNS Resolver Cache."

Register DNS

ipconfig /registerdns

This forces your computer to re-register its DNS names with the DNS server. It is mostly relevant for domain-joined machines in corporate environments. For home users, it rarely makes a difference.

Display DNS Cache

ipconfig /displaydns

This dumps every cached DNS entry to the console. You will see domain names, IP addresses, and TTL values. It is a long output — useful for troubleshooting but not for day-to-day use.

For actually changing DNS server addresses, stick with the Settings app, Control Panel, or PowerShell methods. Command Prompt is best for verification and cache management.

Verify Your DNS Change

After changing your DNS, confirm it is actually in use. Windows does not always apply the change to active connections immediately — you may need to disconnect and reconnect to your Wi-Fi network, or disable and re-enable your Ethernet adapter.

Check with Command Prompt

Open Command Prompt and run:

nslookup example.com

The response will show which DNS server answered the query. If it shows your new DNS provider's IP address (like 1.1.1.1), the change worked. If it still shows your ISP's addresses, the change has not taken effect yet.

You can also run ipconfig /all and check the DNS Servers line under your active adapter. It should list the addresses you entered.

Visit Your DNS Provider's Verification Page

Most major DNS providers have a web page that confirms you are using their service:

  • Cloudflare: open https://1.1.1.1 — it confirms Cloudflare DNS is active
  • Google: open https://dns.google — it shows your current DNS provider
  • Quad9: open https://quad9.net — confirms Quad9 is resolving your queries

These pages check your DNS from the server side, so they give you a definitive answer regardless of what your local configuration says.

Run a Speed Test

Once you confirm the new DNS is active, measure the improvement. Run our DNS speed test and compare the response times against what you had before. Run it two or three times at different times of day for consistent numbers. See also our fastest DNS comparison for a broader picture.

Flush DNS Cache After Changing

Flushing the DNS cache is an important step that many guides skip. When you change DNS servers, your Windows system may still hold cached results from the old resolver. Those cached entries will continue to be served until their TTL expires, which could be hours. Flushing forces a clean start with the new server.

Flush from Command Prompt

  1. Open the Start menu and type cmd.
  2. Right-click Command Prompt and select Run as administrator.
  3. Run: ipconfig /flushdns
  4. You will see "Successfully flushed the DNS Resolver Cache."

Windows requires administrator privileges to flush the DNS cache. If you run the command without admin rights, it will appear to succeed but the cache will not actually clear.

Flush from PowerShell

Clear-DnsClientCache

This does the same thing as ipconfig /flushdns. It does not require elevated privileges, which is one advantage over the Command Prompt method.

Restart Your Network Adapter

As an alternative to flushing, you can disconnect and reconnect your network adapter. Open Settings, go to Network & Internet, click your connection, and toggle it off and back on. On Wi-Fi, you can also forget the network and reconnect. This clears the DNS cache along with re-establishing the connection.

For a full guide covering every platform, see our complete DNS cache flush guide. For Windows-specific instructions, see how to flush DNS on Windows.

Recommended DNS Servers

Here is a reference table of the best public DNS servers you can use with Windows. Pick based on what matters most to you — speed, security, privacy, or content filtering.

Provider Primary Secondary Best For Key Feature
Cloudflare 1.1.1.1 1.0.0.1 Speed Fastest resolver, logs purged in 24h
Google 8.8.8.8 8.8.4.4 Reliability Near-100% uptime, massive infrastructure
Quad9 9.9.9.9 149.112.112.112 Security Blocks malicious domains, DNSSEC enforced
OpenDNS 208.67.222.222 208.67.220.220 Family filtering Content filtering, phishing protection
Cloudflare Family 1.1.1.3 1.0.0.3 Families Blocks adult content and malware
AdGuard DNS 94.140.14.14 94.140.15.15 Ad blocking Built-in ad and tracker blocking
NextDNS Custom Custom Customization Analytics, DoH/DoT, per-device rules

Run our DNS speed test to see which of these is actually fastest from your location. Global averages do not account for your specific network routing. Check our complete DNS server list for more options.

Frequently Asked Questions

Will changing DNS make my internet faster?

Changing DNS does not increase your download or upload bandwidth. What it improves is how quickly domain names resolve into IP addresses. Faster resolution means pages start loading sooner. The difference is most noticeable on sites that pull resources from many domains — which is most modern websites. You will not see a difference in raw download speed, but page load times can improve by hundreds of milliseconds across multiple DNS lookups.

Is it safe to change DNS on Windows?

Yes. Changing DNS only affects how your computer translates domain names to IP addresses. It does not touch your files, installed programs, or any other system setting. Public DNS servers from Cloudflare, Google, and Quad9 are used by hundreds of millions of people. The change is completely reversible — switch back to automatic DNS in the same menu whenever you want.

Do I need to flush DNS cache after changing?

You should, yes. After changing DNS servers, your system may still serve cached results from the old resolver. Flushing clears that cache so every new lookup goes through the new server. Open Command Prompt as Administrator and run ipconfig /flushdns. Without flushing, old cached entries will stick around until their TTL expires naturally, which could be hours.

Can I change DNS for just one network on Windows?

Yes. Windows stores DNS settings per network adapter. If you set DNS on your Wi-Fi adapter, it only affects Wi-Fi connections. Your Ethernet adapter keeps its own DNS settings. You can also configure different DNS servers for different Wi-Fi networks — Windows remembers DNS settings per saved network. Set DNS while connected to a specific network, and those settings apply only to that network.

Why does nslookup show a different DNS than what I set?

A few things could be happening. First, disconnect and reconnect your Wi-Fi or disable and re-enable your Ethernet adapter — Windows does not always apply DNS changes to active connections immediately. Second, check if your VPN is active — many VPNs override DNS settings. Third, make sure you saved the settings in the correct adapter properties. Run ipconfig /all to see what DNS addresses your adapter is actually using.

Run a DNS Speed Test Now

See which DNS server is fastest from your location. Takes 10 seconds.