How to Change Your DNS in Windows
Every computer communicates with a Domain Name System (DNS) server that is responsible for translating actual web addresses (i.e. - Google.com) into website names (22.214.171.124), which is an essential part of the way your browser functions. Of course, if we all had to remember a website's IP address to visit their home page then the web wouldn't be very user-friendly.
If there's a delay or communication problem between your computer/network and then DNS server, the result can be decreased loading times and other connectivity problems. Although your operating system comes with default DNS settings and your Internet Service Provider (ISP) will usually set your router to use one of their proprietary DNS servers, many people find that switching to other free or public DNS servers results in improved performance - have a look at our list of Top 10 Public DNS Servers while you're here.
Thus, changing your DNS server settings is one way to try resolving slow browsing and connectivity issues and is a step that should therefore be included in any comprehensive troubleshooting process. In a recent guide, we explained how to find the best DNS servers using Namebench and DNS Benchmark. In the following guide, we'll show you how to change your DNS server to a new server of your choice within Windows 10:
(Note: although this exact process is for Windows 10, it will be similar in all versions of Windows. Locate the adapter settings module for the adapter you're using to connect to the internet and you'll be on the right track. You can also use the command prompt method at the bottom of this guide and it should work in any version of Windows.)
1. Open the Network and Sharing Center. There are multiple ways to do this, but the fastest and easiest method is to simply type “network and sharing center” into the Cortana search bar and then select the option at the top next to the Networking icon:
2. Select Change adapter settings from the left navigational pane
3. Right-click on the adapter your computer is using to connect to the internet, and then select Properties.
4. Scroll down and select the Internet Protocol Version 4 (TCP/IPv4). Then click the Properties button.
5. Under the General tab, click the bubble next to Use the following IP address
6. Now you can leave the IP address, subnet mask, and default gateway blank to keep those settings the same, and at the bottom you'll have the option to input your preferred primary and secondary DNS servers under the Use following DNS server addresses. In this example, I'm using the Google Public DNS addresses:
7. Click OK and then Close to apply the settings. You don't need to restart – your PC will begin using the new settings immediately.
Using the Command Prompt Method
Alternatively, you can change DNS settings in Windows 10 within the command prompt utility by following these steps:
1. Open the Command Prompt. Type “CMD” into the Start menu search box, right-click on the Command Prompt option and select Run as Administrator.
2. To reveal the names of your network adapters, input the following command and press Enter:
wmic nic get NetConnectionID
3. To begin changing network settings, input the following command and press Enter:
4. To set the primary DNS address, input the following command and press Enter:
interface ip set dns name="ADAPTER NAME" source="static" address="0.0.0.0"
Replace “ADAPTER NAME” with the name of the network adapter you're using, which was queried in step 2. Replace “0.0.0.0” with the DNS IP address of your choice.
5. To add a secondary DNS IP address, input the following command and press enter:
interface ip add dns name="ADAPTER NAME" addr="0.0.0.0" index=2
Again, replace ADAPTER NAME with the name o the adapter queried in step 2 and replace “0.0.0.0” with the secondary DNS IP address of your choice.
6. If you'd like to add another alternate DNS IP address, you can do so by adding the line of code above and increasing the index number by one with each new address. So the next DNS IP would be followed by “index=3” and so on. For example:
interface ip add dns name="ADAPTER NAME" addr="0.0.0.0" index=3
The new DNS should start being used immediately after you input the above commands. There's no need to restart the computer or perform any other steps.