How to change DNS settings in Windows 11

We recently wrote a guide on how to edit the Hosts file in Windows 11 if you want to block certain websites on your PC. However, if you want to improve your privacy on Windows 11, changing your DNS settings is also a must. It will protect the Internet communication on your computer, whether it is opening a website or an application trying to connect to its server in the background. If you are new to this domain, learn how to change DNS settings in Windows 11 in this detailed guide.

Change DNS settings in Windows 11 (2022)

In this guide, we have included five ways to change DNS settings in Windows 11. Along with that, we have explained what DNS is and why you should change DNS settings on your PC. Expand the table below to read the explanation, or jump directly to the desired method.

What is DNS in Windows 11?

The DNS or Domain Name System is like the phone book of the Internet. When you open a website, your computer connects to a DNS server to find the website's IP address. That's how it finds the address and connects you to the website. A DNS server is needed so that you don't have to remember complicated website IP addresses.

There are many DNS servers, from ISPs to those offered by Google, Cloudflare, OpenDNS, etc. Each DNS server claims to be able to get information faster than the other. Some offer built-in protection like DNS-over-TLS and some offer lower latency. It depends on which one you want to use on your Windows 11 PC.

However, the reason I suggest users to change the default DNS server in Windows 11 is because ISPs are increasingly logging DNS requests, which is bad for your privacy. This means that your ISP can find out which website you have visited through the DNS log. So to be on the safe side, use well-known custom DNS servers that don't log your queries, provide reliable performance, and protect against phishing and malicious attacks.

Now, with that cleared up, let's go ahead and learn about some of the popular DNS servers for Windows 11.

Free DNS Servers for Windows 11

Here are some free and popular DNS servers that you can use on your Windows 11 PC. We have added both preferred (also called primary) and alternate (also called secondary) DNS addresses of popular services.

1. Cloud Flash

Preferred DNS: 1.1.1.1 Alternate DNS: 1.0.0.1

2. Google

Preferred DNS: 8.8.8.8 Alternate DNS: 8.8.4.4

3. OpenDNS

Preferred DNS: 208.67.222.222 Alternate DNS: 208.67.220.220

4. Comodo Secure DNS

Preferred DNS: 8.26.56.26 Alternate DNS: 8.20.247.20

5. Quad9 DNS

Preferred DNS: 9.9.9.9 Alternate DNS: 149.112.112.112

Change DNS Server Using the Settings App in Windows 11

The easiest way to change the DNS server in Windows 11 is in the settings. It allows you to define DNS with IPv4 and IPv6 protocols. Here's how to go through this process:

1. Press the Windows 11 keyboard shortcut "Windows + I" to open the Settings app. Here, go to the "Network and Internet" settings menu from the left sidebar and click on "Wi-Fi" on the right panel. If you have a wired Ethernet connection, click Ethernet.

2. Then scroll down and find Hardware Properties. Open it.

3. Now click "Change" next to "DNS Server Assignment". It will be set to "Automatic (DHCP)", which means that Windows 11 uses the DNS server chosen by your ISP. This is what we need to change.

4. On the next page, select "Manual" from the drop-down menu and turn on the "IPv4" radio button.

5. After that, in the "Preferred" and "Alternative" DNS fields, enter the custom DNS server address that you want to use. You can find the best DNS servers from our linked article. I usually use Google's DNS server which looks like this:

  • Preferred DNS: 8.8.8.8
  • Alternate DNS: 8.8.4.4

6. When you are done, click Save and you have successfully changed the DNS server in Windows 11. If you also want to know how to enable DNS-over-HTTPS in Windows 11, which will make all DNS requests encrypted. , go to the next step.

7. Click the drop-down menu under "Preferred" and "Alternative" DNS encryption and change the encryption type to "Encryption only (DNS over HTTPS)".

8. Now click "Save" and you're done. Along with a custom DNS server in Windows 11, you have also enabled encryption for all your DNS requests, which will make the network connection on your PC more secure.

Change DNS Server from Control Panel in Windows 11

If you're old school like me and want to change the DNS server in Windows 11 from the Control Panel, follow our guide below.

1. Use the keyboard shortcut "Windows + R" to open the "Run" window. Here, type ncpa.cpl and press Enter.

2. The "Network and Internet" window will open directly in the Control Panel. You can also manually open the Control Panel in Windows 11 and go to "Network and Sharing Center".

3. Once here, right-click on the "Wi-Fi" adapter and select "Properties". If you are using a wired Ethernet connection, right-click "Ethernet" and select "Properties".

4. Then scroll down and double click "Internet Protocol Version 4 (TCP/IPv4)".

5. Now a new pop-up window will open where you need to select "Use the following DNS server addresses". Here we are going to set up our own DNS server.

6. Now enter your preferred and alternate DNS servers in the appropriate fields. For example, here I am using the Cloudflare DNS servers that are mentioned below. You are free to choose for yourself.

  • Preferred DNS: 1.1.1.1
  • Alternate DNS: 1.0.0.1

7. Finally, click "OK" and that's it. You have set up your own DNS server on your Windows 11 PC.

Changing DNS Settings Using Command Prompt (CMD)

In addition to Windows settings and the Control Panel, you can also change your DNS settings using the command line. You just need to use a few commands and you're done. Here are the steps you need to follow:

1. Press the Windows key and type "cmd" in the search bar. Now click "Run as administrator" in the right pane. If you always want to run apps with administrative privileges on Windows 11, check out our linked guide.

2. Then run the below command in the CMD window. Be sure to replace Preferred with your server's primary DNS. For example, I used 1.1.1.1, which is Cloudflare's preferred DNS server. Also, if you are using Ethernet, replace Wi-Fi with Ethernet in the command below.

netsh interface ipv4 set dnsservers Wi-Fi Static preferred primary

3. To install an alternate DNS server using the command line, run the following command. Here, replace Alternative with Secondary DNS Server. I installed Cloudflare 1.0.0.1 as an alternative DNS.

netsh interface ipv4 add dnsservers Wi-Fi Alternative index=2

4. Done. Open the Settings app and you will find that the custom DNS servers have been updated.

6. If you want to reset DNS settings to automatic (DHCP), run the below command in CMD on Windows 11 PC.

netsh interface ip set dns "Local Area Connection" dhcp

Change DNS settings using PowerShell in Windows 11

1. Press the Windows key and type "powershell". Now click "Run as administrator".

2. Then run the following command in PowerShell to write down the InterfaceIndex of your Wi-Fi or Ethernet adapter. For example, I am connected to a wireless network and my InterfaceIndex is 18.

Get-NetAdapter | Select-Object InterfaceAlias , InterfaceIndex

3. Now run the command below. Be sure to replace N with the InterfaceIndex value (Wi-Fi or Ethernet) displayed on your PC. After that, replace the preferred and alternate DNS servers of your choice.

set-DnsClientServerAddress -InterfaceIndex N -ServerAddresses ("preferred","alternative")

Change DNS Server in Windows 11 Using DNS Jumper

If you are looking for a third party app to change DNS settings in Windows 11, DNS Jumper is one of the best programs. It's free and offers a long list of DNS servers that you can apply with the click of a button. Here's how it works:

1. Follow this link and download the DNS Jumper ZIP file. Now unzip the file in Windows 11 and navigate to the DnsJumper folder. Here, double click "DnsJumper.exe".

2. Now select your DNS server from the drop down menu and click Apply DNS. That's all.

3. If you want to install your own DNS server, check the box and enter the primary and secondary server addresses in the fields below. After that click "Apply DNS".

Frequently Asked Questions (FAQ)

What is DNS Server in Windows 11?

The DNS server allows your Windows 11 PC to find the IP addresses of websites. Basically, it's a phone book that contains an IP address and you're connected to a website.

What is the best DNS server for Windows 11?

Both Cloudflare and Google's DNS servers are great for Windows 11 in my opinion.

Which DNS server offers the lowest latency on Windows 11?

If you need high performance from your DNS server on Windows 11, I recommend Cloudflare.

Can we change the DNS server from the control panel in Windows 11?

Yes, you can still change the DNS server from the Control Panel in Windows 11. Follow our guide for more details.

Set up a custom DNS server in Windows 11

So, these are five easy ways to set up your own DNS server in Windows 11. I highly recommend changing the DNS server on the Windows settings page. Along with custom DNS, you can also enable DNS-over-HTTPS from there. However, this is all from us. If you're having internet problems and Wi-Fi keeps dropping out on your Windows 11 PC, follow our linked guide to fix it easily. In addition, to resolve the "Network discovery is disabled" error in Windows 11, we have a handy guide for you. Finally, if you have any questions, please let us know in the comments section below.

Related posts