How to Change DNS Servers in Windows

What there is to know

  • Select Control Panel > Network and Internet > Network and Sharing Centerr > Change adaptation settings. Open a connection to edit.
  • Select Properties. In the This connection uses the following section, choose Internet Protocol Version 4 Where Variant 6.
  • Select Properties. In the Internet Protocol Properties window, select Use the following DNS server addresses and enter them.

This article explains how to change DNS servers in Windows 11, Windows 10, Windows 8, and Windows 7. It also includes information on how to change DNS servers with Command Prompt.

How to Change Windows DNS Servers

Most computers and devices connect to a local network using DHCP and DNS servers that are automatically configured in Windows. DNS servers are sometimes the cause of certain types of Internet problems, and changing them can help fix the problem.

Below are the steps required to change the DNS servers used by Windows. However, the procedure differs somewhat depending on the version of Windows.

  1. Open Control Panel.

    In Windows 8.1, select Network connections in the Power User menu, then go to step 5.

  2. Select Network and Internet.

    Network and Internet does not appear if the control panel displays large or small icons. Choose instead Network and Sharing Centerthen go to step 4.

  3. In the Network and Internet window, select Network and Sharing Center to open this applet.

  4. In the Network and Sharing Center window, select Change adaptation settings.

  5. The Network connections window lists connections to the computer. Wired connections are labeled as ethernet Where Local Area Connectionwhile the wireless ones are labeled as Wireless.

    If you don’t see the correct connection, change the view to Detailsgo to Connectivity column, and use the connection that lists Internet access.

  6. Open the network connection whose DNS servers you want to change by double-clicking or double-tapping its icon.

  7. In the Status window, select Properties.

    In some versions of Windows, provide the administrator password if you are not logged into an administrator account.

  8. In the Properties window, go to This connection uses the following section and select Internet Protocol Version 4 (TCP/IPv4) Where Internet Protocol (TCP/IP) to select the IPv4 option, or select Internet Protocol Version 6 (TCP/IPv6) to change IPv6 DNS server settings.

  9. Select Properties.

  10. In the Internet Protocol Properties window, choose Use the following DNS server addresses.

    If Windows has configured custom DNS servers, replace the existing DNS server IP addresses with new ones.

  11. Enter the IP address of the Preferred DNS server and for the Alternate DNS server.

    You can also enter just one preferred DNS server, change one provider’s preferred DNS server to another’s secondary DNS server, or enter more than two DNS servers using the fields on the DNS tab (select Advanced to enter multiple DNS servers).

  12. Select OKAY to make changes to the DNS server.

  13. Close Control Panel.

  14. Verify that the new DNS servers are working properly on Windows. Visit multiple websites in your favorite web browser. If web pages are displayed as quickly as before, the new DNS servers are working properly.

How to Change DNS Servers with Command Prompt

The preferred DNS server in Windows can be changed through the command prompt. Use this method if you are comfortable entering commands on the command line.

  1. Open an elevated command prompt.

  2. Type Netsh and press Walk in.

  3. At netsh> prompt, type interface ip show configthen press Walk in.

  4. Locate the network connection for which you want to change the DNS server.

  5. Walk in interface ip set dns “Ethernet0” static and press Walk in. Replace ethernet0 with the name of your connection and with the DNS server you want to use.

    Use the command line, in the command prompt or a BAT file, to force the connection to use DHCP. Replace the static section of the command with DHCP.

  6. When the order is complete, the netsh> the prompt appears.

  7. Close the command prompt.

DNS server settings are device specific

Configuring custom DNS servers for your computer only applies to that computer, not to other devices on the network. For example, you can set up a Windows laptop with one set of DNS servers and use an entirely different set on a desktop, phone, or tablet.

DNS settings apply to the nearest device on which they are configured. For example, if you use a set of DNS servers on the router, your laptop and phone will use those DNS servers when they connect to Wi-Fi. However, if the router has its own set of servers and the laptop has its own separate set, the laptop will use a different DNS server than the phone and other devices that use the router. The same is true if the phone uses a custom set.

DNS settings only affect a network if each device is configured to use the router’s DNS settings and not their own. This means that if four devices are on a network, for example, all four could use separate DNS servers.

See our list of free and public DNS servers for the full list of publicly available DNS servers which may be more comprehensive than the list provided by your ISP.


  • What is a DNS server?

    A DNS server is a computer server that contains a database of public IP addresses and their associated host names. It works to translate those names to IP addresses as requested. Once the IP address is returned, the website you want to visit is displayed in your web browser.

  • What is a DNS error and how to fix it?

    These errors usually indicate “DNS server not responding” and mean that your device will not be able to connect to the internet. Common causes include: a misbehaving ISP; malfunction of TCP/IP or DHCP services; overly aggressive antivirus software; or a faulty router or modem.

  • How to Change DNS Settings on Android Phone?

    To change DNS settings on phones with Android 9 or later, tap Settings (equipment) > Network & Internet > Advanced > Private DNS > Private DNS provides hostname. Enter the Cloudflare DNS address ( or a CleanBrowing URLs.

Previous Are organizations giving more than they should?
Next What does the acceptance of all domain names look like in open source software in 2021?