In this article, we will see how to change the DNS server in Windows 10. It is one of the important network parameters which allows you to browse the Internet and resolve remote computer names. Today, we will learn what DNS is and why you might want to change the DNS configuration.
DNS stands for Domain Name System. Windows comes with an option which stores the specified DNS server address and makes the TCP/IP stack use that IP address. It refers to this user-specified DNS service or gateway-specified service to resolve the domain name of a website to its IP address and load it in your web browser.
In most cases, your Internet Service Provider (ISP) provides their own DNS server which does its work. This DNS server is usually specified in your router or automatically fetched from the ISP. But in some cases, you may have a reason to switch to an external DNS server. It may update its cache faster (this can be a reason for web developers) and can have some features that your default DNS doesn't have. For example, a third-party DNS service can have a built-in ad blocker. In some cases, the ISP's DNS server can make you run into an issue where sites do not load fast enough or do not load at all. Other DNS services can provide extra security.
In the place where I live, we have such an ISP whose DNS server is just awful. This is a good reason to change the DNS server address to some alternative one like Google's public DNS. Google's IPv4 DNS servers have the address 188.8.131.52 and 184.108.40.206. Another popular one is OpenDNS (220.127.116.11 and 18.104.22.168). Here is how you can specify Windows to use these.
Ensure that you are signed in as an administrator before proceeding, otherwise you won't be able to change your DNS settings.
To change the DNS Server in Windows 10, do the following.
- Open Settings.
- Go to Network & Internet.
- If you are connected to the Internet with a wired connection, click Ethernet on the left side.
- If you are connected to the Internet with a wireless connection, click Wi-Fi on the left side.
- In the Related settings section, click on the link "Change adapter options".
- The following window will appear on the screen. Double-click your network connection.
- In the dialog window, click the Properties button with the yellow-blue security shield. Confirm the UAC prompt if you are shown one.
- Now, on the Networking tab, select the row Internet Protocol Version 4 (TCP/IPv4), and then click on the button "Properties".
- The dialog window "Internet Protocol Version 4 (TCP/IPv4) Properties" will be opened. To use a custom DNS Server address, select the option "Use the following DNS server addresses:" on the General tab. Enter the desired DNS server address or modify the existing values if required. You can use the servers mentioned above. For example, I will use Google's public DNS servers (see the screenshot below).
- Click OK and Close buttons in every opened window to apply the change.
Alternatively, you can change the DNS server address using the console tool "netsh". First of all, you need to know the name of your connection. You can see it in the Settings app as described above, or you can retrieve it directly in the command prompt.
Open an elevated command prompt and type
See the name of your connection (see the example below).
Now, type the following commands to set an alternative address for DNS servers (I am using Google's DNS servers again for this example):
netsh interface ip set dnsservers "Your Connection Name" static 22.214.171.124 primary netsh interface ip add dnsservers "Your Connection Name" 126.96.36.199 index=2
Use the required IP addresses and the correct connection name to change the configuration.
With netsh, you can also enable automatic DNS server configuration provided by DHCP. The command looks as follows:
netsh interface ip set dnsservers "Your Connection Name" dhcp
If you have an IPv6 internet connection, follow the same instructions as above, only change it for Internet Protocol Version 6 (TCP/IPv6). Google's IPv6 DNS addresses are: 2001:4860:4860::8888 and 2001:4860:4860::8844.