Windows 10: Change IPv4 and IPv6 DNS Server Address in Windows  

    Change IPv4 and IPv6 DNS Server Address in Windows

    Change IPv4 and IPv6 DNS Server Address in Windows

    How to Change IPv4 and IPv6 DNS Server Address in Windows
    Published by Category: Network & Sharing
    03 Oct 2018
    Designer Media Ltd

    Published by


    Brink's Avatar
    Administrator

    Posts: 33,070

    Show Printable Version 


    How to Change IPv4 and IPv6 DNS Server Address in Windows


    A DNS (Domain Name System) server is the service that makes it possible for you to open a web browser, type a domain name and load your favorite websites.

    When you subscribe to an Internet connection with an Internet Service Provider (ISP) (ex: Cox, Comcast, AT&T, etc...) in your area, you will use their DNS server by default. If you like, you can use third-party DNS servers (ex: OpenDNS or Google Public DNS) instead, which could offer a variety of features that your ISP may not.

    Sometimes the DNS servers are slow responding to requests, or they just are not reliable. Changing your default settings can improve your internet browsing experience.

    This tutorial will show you how to change the IPv4 and IPv6 DNS server address in Windows 7, Windows 8, and Windows 10.

    You must be signed in as an administrator to change the DNS server address.


     CONTENTS:

    • Option One: To Change DNS Server Address on Router
    • Option Two: To Change IPv4 and IPv6 DNS Server Address in Control Panel
    • Option Three: To Change IPv4 and IPv6 DNS Server Address in PowerShell
    • Option Four: To Change IPv4 and IPv6 DNS Server Address in Command Prompt
    • Option Five: To Change IPv4 and IPv6 DNS Server Address in Settings





    Change IPv4 and IPv6 DNS Server Address in Windows OPTION ONE Change IPv4 and IPv6 DNS Server Address in Windows
    To Change DNS Server Address on Router

    1. If you connect to the Internet via a router, then you may want to change the DNS address in your router settings instead so all devices that connect via the router will use this DNS address if the computer is set to Obtain DNS server address automatically.

    You'll need to read the manual for how to change the DNS settings for your router's model number.

    Name:  Linksys_DNS.jpg
Views: 6879
Size:  71.0 KB






    Change IPv4 and IPv6 DNS Server Address in Windows OPTION TWO Change IPv4 and IPv6 DNS Server Address in Windows
    To Change IPv4 and IPv6 DNS Server Address in Control Panel

    1. Open the Control Panel (icons view), and click/tap on the Network and Sharing Center icon.

    2. Click/tap on the Connections link (ex: "vEthernet (New Virtual Switch)") for your current network connection. (see screenshot below)

    Name:  Change_DNS-1.jpg
Views: 8040
Size:  53.3 KB

    3. Click/tap on the Properties button. (see screenshot below)

    Name:  Change_DNS-2.jpg
Views: 7860
Size:  35.6 KB

    4. In the Networking tab, select (highlight) Internet Protocol Version 4 (TCP/IPv4) or Internet Protocol Version 6 (TCP/IPv6) for which one you want to change, and click/tap on the Properties button. (see screenshot below)

    Name:  Change_DNS-3.jpg
Views: 7975
Size:  59.2 KB

    5. Do step 6 (Obtain DNS automatically) or step 7 (Use custom DNS) below for what you want to do.


     6. To Obtain DNS Server Address Automatically from ISP

    This is the default setting.

    A) In the General tab, select (dot) Obtain DNS server address automatically, click/tap on OK, and go to step 8 below. (see screenshots below)

    Name:  Change_DNS-4.jpg
Views: 8064
Size:  51.1 KB Name:  Change_IPv6_DNS-4.png
Views: 6124
Size:  25.6 KB


     7. To Use Custom or Third-party DNS Server Address

    A) In the General tab, select (dot) Use the following DNS server addresses. (see screenshots below)

    B) Enter the Preferred DNS server and Alternate DNS server addresses you want to use, click/tap on OK, and go to step 8 below.

    Third-party DNS servers Preferred IPv4 DNS server address Alternate IPv4 DNS server address Preferred IPv6 DNS server Alternate IPv6 DNS server address
    Google Public DNS 8.8.8.8 8.8.4.4 2001:4860:4860:8888
    OR
    2001:4860:4860:0:0:0:0:8888
    2001:4860:4860:8844
    OR
    2001:4860:4860:0:0:0:0:8844
    OpenDNS 208.67.222.222 208.67.220.220 2620:0:ccc::2 2620:0:ccd::2
    1.1.1.1 by Cloudflare 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001
    Quad 9.9.9.9 149.112.112.112 (secure)
    OR
    149.112.112.10 (unsecure)
    2620:fe::fe (secure)
    OR
    2620:fe::10 (unsecure)
    CleanBrowsing (Family filter) 185.228.168.168 185.228.168.169 2a0d:2a00:1:: 2a0d:2a00:2::
    CleanBrowsing (Adult filter) 185.228.168.10 185.228.168.11 2a0d:2a00:1::1 2a0d:2a00:2::1
    Name:  Change_DNS-5.jpg
Views: 7846
Size:  66.5 KB Name:  Change_IPv6_DNS-5.png
Views: 6203
Size:  33.7 KB


    8. Click/tap on Close. (see screenshot below)

    Name:  Change_DNS-6.jpg
Views: 8048
Size:  52.9 KB

    9. Click/tap on Close. (see screenshot below step 3)

    10. You can now close the Network and Sharing Center if you like. (see screenshot below step 2)

    11. If you like or needed, you can flush the DNS resolver cache to make sure the new DNS server is applied.






    Change IPv4 and IPv6 DNS Server Address in Windows OPTION THREE Change IPv4 and IPv6 DNS Server Address in Windows
    To Change IPv4 and IPv6 DNS Server Address in PowerShell

    1. Open an elevated PowerShell.

    2. Enter the command below into the elevated PowerShell, press Enter, and make note of the Interface Alias (ex: "Ethernet") you want to change the IPv4 or IPv6 DNS server address for. (see screenshot below)

    Get-DnsClientServerAddress

    You will also be able to see the current IPv4 and IPv6 DNS server addresses for network connections (InterfaceAlias).

    Name:  Get-DnsClientServerAddress.png
Views: 5881
Size:  39.9 KB


    3. Do step 4 (Obtain DNS automatically), step 5 (Change IPv4 DNS), or step 6 (Change IPv6 DNS) below for what you want to do.


     4. To Obtain IPv4 and IPv6 DNS Server Addresses Automatically from ISP

    This is the default setting.

    A) Enter the command below you want to use into the elevated command prompt, press Enter, and go to step 7 below. (see screenshot below)

    Set-DNSClientServerAddress "Interface Alias" -ResetServerAddresses

    Substitute Interface Alias in the command above with the actual Interface Alias (ex: "Ethernet") from step 2 above.

    Name:  Set-DNSClientServerAddress_default.png
Views: 5832
Size:  17.7 KB


     5. To Change IPv4 DNS Server Address

    A) Enter the command below you want to use into the elevated PowerShell, press Enter, and go to step 7 below. (see screenshot below)

    Set-DNSClientServerAddress "Interface Alias" –ServerAddresses ("Preferred DNS address", "Alternate DNS address")

    Substitute Interface Alias in the command above with the actual Interface Alias (ex: "Ethernet") from step 2 above.

    Substitute Preferred DNS address in the command above with the actual preferred IPv4 DNS server address (see table below) you want to use for this network connection.

    Substitute Alternate DNS address in the command above with the actual alternate IPv4 DNS server address (see table below) you want to use for this network connection.

    For example: Set-DNSClientServerAddress "Ethernet" –ServerAddresses (“1.1.1.1”,”1.0.0.1”)

    Third-party DNS servers Preferred IPv4 DNS server address Alternate IPv4 DNS server address
    Google Public DNS 8.8.8.8 8.8.4.4
    OpenDNS 208.67.222.222 208.67.220.220
    1.1.1.1 by Cloudflare 1.1.1.1 1.0.0.1
    Quad 9.9.9.9 149.112.112.112 (secure)
    OR
    149.112.112.10 (unsecure)
    CleanBrowsing (Family filter) 185.228.168.168 185.228.168.169
    CleanBrowsing (Adult filter) 185.228.168.10 185.228.168.11

    Name:  Change_IPv4_DNS_address_PowerShell.png
Views: 5831
Size:  20.2 KB


     6. To Change IPv6 DNS Server Address

    A) Enter the command below you want to use into the elevated PowerShell, press Enter, and go to step 7 below. (see screenshot below)

    Set-DNSClientServerAddress "Interface Alias" –ServerAddresses ("Preferred DNS address", "Alternate DNS address")

    Substitute Interface Alias in the command above with the actual Interface Alias (ex: "Ethernet") from step 2 above.

    Substitute Preferred DNS address in the command above with the actual preferred IPv6 DNS server address (see table below) you want to use for this network connection.

    Substitute Alternate DNS address in the command above with the actual alternate IPv6 DNS server address (see table below) you want to use for this network connection.

    For example: Set-DNSClientServerAddress "Ethernet" –ServerAddresses (“2606:4700:4700::1111”,”2606:4700:4700::1001”)

    Third-party DNS servers Preferred IPv6 DNS server Alternate IPv6 DNS server address
    Google Public DNS 2001:4860:4860:0:0:0:0:8888 2001:4860:4860:0:0:0:0:8844
    OpenDNS 2620:0:ccc::2 2620:0:ccd::2
    1.1.1.1 by Cloudflare 2606:4700:4700::1111 2606:4700:4700::1001
    Quad 2620:fe::fe (secure)
    OR
    2620:fe::10 (unsecure)
    CleanBrowsing (Family filter) 2a0d:2a00:1:: 2a0d:2a00:2::
    CleanBrowsing (Adult filter) 2a0d:2a00:1::1 2a0d:2a00:2::1

    Name:  Change_IPv6_DNS_address_PowerShell.jpg
Views: 5822
Size:  19.5 KB

    7. If you like or needed, you can flush the DNS resolver cache to make sure the new DNS server is applied.

    8. You can now close the elevated PowerShell if you like.






    Change IPv4 and IPv6 DNS Server Address in Windows OPTION FOUR Change IPv4 and IPv6 DNS Server Address in Windows
    To Change IPv4 and IPv6 DNS Server Address in Command Prompt

    1. Open an elevated command prompt.

    2. Enter the command below into the elevated command prompt, press Enter, and make note of the Interface Name (ex: "Ethernet") you want to change the IPv4 or IPv6 DNS server address for. (see screenshot below)

    netsh interface show interface

    Name:  netsh_interface-.png
Views: 5999
Size:  23.3 KB


    3. Do step 4 (Obtain DNS automatically) or step 5 (Use custom DNS) below for what you want to do.


     4. To Obtain DNS Server Address Automatically from ISP

    This is the default setting.

    A) Enter the command below you want to use into the elevated command prompt, press Enter, and go to step 6 below. (see screenshot below)

    (IPv4 DNS)
    netsh interface ipv4 set dnsservers "Connection Name" dhcp

    OR

    (IPv6 DNS)
    netsh interface ipv6 set dnsservers "Connection Name" dhcp

    Substitute Connection Name in the command above with the connection name (ex: "vEthernet (New Virtual Switch)") from step 2 above.

    Name:  netsh_interface_IPv6_dhcp.png
Views: 5961
Size:  18.5 KB


     5. To Use Custom or Third-party DNS Server Address

    A) Enter the command below you want to use into the elevated command prompt, and press Enter. (see screenshot below)

    (IPv4 DNS)
    netsh interface ipv4 set dnsservers "Connection Name" static Preferred DNS address primary

    OR

    (IPv6 DNS)
    netsh interface ipv6 set dnsservers "Connection Name" static Preferred DNS address primary

    Substitute Connection Name in the command above with the connection name (ex: "Ethernet") from step 2 above.

    Substitute Preferred DNS address in the command above with the actual preferred IPv4 or IPv6 DNS server address (see table below) you want to use for this network connection.

    Third-party DNS servers Preferred IPv4 DNS server address Preferred IPv6 DNS server address
    Google Public DNS 8.8.8.8 2001:4860:4860:0:0:0:0:8888
    OpenDNS 208.67.222.222 2620:0:ccc::2
    1.1.1.1 by Cloudflare 1.1.1.1 2606:4700:4700::1111
    Quad9 9.9.9.9 2620:fe::fe (secure)
    OR
    2620:fe::10 (unsecure)
    CleanBrowsing (Family filter) 185.228.168.168 2a0d:2a00:1::
    CleanBrowsing (Adult filter) 185.228.168.10 2a0d:2a00:1::1

    For example: netsh interface ipv6 set dnsservers "Ethernet" static 2001:4860:4860:0:0:0:0:8888 primary

    Name:  netsh_interface_IPv6_primary.jpg
Views: 5972
Size:  23.7 KB


    B) Enter the command below into the elevated command prompt, press Enter, and go to step 6 below. (see screenshot below)

    (IPv4 DNS)
    netsh interface ipv4 add dnsservers "Connection Name" Alternate DNS address index=2

    OR

    (IPv6 DNS)
    netsh interface ipv6 add dnsservers "Connection Name" Alternate DNS address index=2

    Substitute Connection Name in the command above with the connection name (ex: "Ethernet") from step 2 above.

    Substitute Alternate DNS address in the command above with the actual alternate IPv4 or IPv6 DNS server address (see table below) you want to use for this network connection.

    Third-party DNS servers Alternate IPv4 DNS server address Alternate IPv6 DNS server address
    Google Public DNS 8.8.4.4 2001:4860:4860:0:0:0:0:8844
    OpenDNS 208.67.220.220 2620:0:ccd::2
    1.1.1.1 by Cloudflare 1.0.0.1 2606:4700:4700::1001
    Quad9 149.112.112.112 (secure)
    OR
    149.112.112.10 (unsecure)
    CleanBrowsing (Family filter) 185.228.168.169 2a0d:2a00:2::
    CleanBrowsing (Adult filter) 185.228.168.11 2a0d:2a00:2::1

    For example: netsh interface ipv6 add dnsservers "Ethernet" 2001:4860:4860:0:0:0:0:8844 index=2

    Name:  netsh_interface_IPv6_alternate.jpg
Views: 5964
Size:  26.5 KB


    6. If you like or needed, you can flush the DNS resolver cache to make sure the new DNS server is applied.

    7. You can now close the elevated command prompt if you like.






    Change IPv4 and IPv6 DNS Server Address in Windows OPTION FIVE Change IPv4 and IPv6 DNS Server Address in Windows
    To Change IPv4 and IPv6 DNS Server Address in Settings


    This option is only available starting with Windows 10 build 18252.

    1. Open Settings, and click/tap on the Network & Internet icon.

    2. Perform the action below you want to do depending on if you want to change the IPv4 and/or IPv6 DNS address for an Ethernet or Wi-Fi connection. (see screenshots below)

    (Ethernet)
    A) Click/tap on Ethernet on the left side, and click/tap on the connection (ex: "Brink-Router2") on the right side you want to edit the DNS address settings for.

    OR

    (Wi-Fi)
    B) Click/tap on Wi-Fi on the left side, and click/tap on the connection (ex: "Brink-Router2") on the right side you want to edit the DNS address for.

    Name:  Ethernet_IP_settings-1.jpg
Views: 796
Size:  54.9 KB Name:  Wi-Fi_IP_settings-1.jpg
Views: 796
Size:  66.1 KB

    3. Do step 4 (Obtain DNS automatically) or step 5 (Change DNS) below for what you want to do.


     4. To Obtain IPv4 and IPv6 DNS Server Address Automatically from ISP

    This is the default setting.

    A) Select Automatic (DHCP) in the Edit IP settings drop menu, click/tap on Save, and go to step 6 below. (see screenshot below)

    Name:  Network_IP_settings-1.jpg
Views: 793
Size:  20.0 KB


     5. To Use Custom or Third-party IPv4 and/or IPv6 DNS Server Address

    A) Select Manual in the Edit IP settings drop menu. (see screenshots below)

    B) Turn on IPv4, and enter the Preferred DNS and Alternate DNS addresses you want to use.

    If you turn off IPv4, its DNS address will be obtained automatically instead of using a custom DNS.

    Third-party DNS servers Preferred IPv4 DNS server address Alternate IPv4 DNS server address
    Google Public DNS 8.8.8.8 8.8.4.4
    OpenDNS 208.67.222.222 208.67.220.220
    1.1.1.1 by Cloudflare 1.1.1.1 1.0.0.1
    Quad 9.9.9.9 149.112.112.112 (secure)
    OR
    149.112.112.10 (unsecure)
    CleanBrowsing (Family filter) 185.228.168.168 185.228.168.169
    CleanBrowsing (Adult filter) 185.228.168.10 185.228.168.11

    C) Turn on IPv6, and enter the Preferred DNS and Alternate DNS addresses you want to use.

    If you turn off IPv6, its DNS address will be obtained automatically instead of using a custom DNS.

    Third-party DNS servers Preferred IPv6 DNS server Alternate IPv6 DNS server address
    Google Public DNS 2001:4860:4860:0:0:0:0:8888 2001:4860:4860:0:0:0:0:8844
    OpenDNS 2620:0:ccc::2 2620:0:ccd::2
    1.1.1.1 by Cloudflare 2606:4700:4700::1111 2606:4700:4700::1001
    Quad 2620:fe::fe (secure)
    OR
    2620:fe::10 (unsecure)
    CleanBrowsing (Family filter) 2a0d:2a00:1:: 2a0d:2a00:2::
    CleanBrowsing (Adult filter) 2a0d:2a00:1::1 2a0d:2a00:2::1

    D) When finished, click/tap on Save, and go to step 6 below.

    Name:  Network_IP_settings-2.jpg
Views: 800
Size:  49.9 KB Name:  Network_IP_settings-3.jpg
Views: 800
Size:  47.9 KB

    6. You can now close Settings if you like.


    That's it,
    Shawn


  1. TairikuOkami's Avatar
    Posts : 3,415
    10.6 Home 1809 x64
       18 Mar 2017 #1

    To change DNS on DHCP enabled network (without the need to enter the name):
    Code:
    wmic nicconfig where DHCPEnabled=TRUE call SetDNSServerSearchOrder ("208.67.222.222","208.67.220.220")

    To change DNS based on MAC address:
    Code:
    wmic nicconfig where macaddress="D0:25:C2:D0:30:DC" call SetDNSServerSearchOrder ("208.67.222.222","208.67.220.220")
      My ComputerSystem Spec

  2. Brink's Avatar
    Posts : 33,070
    64-bit Windows 10 Pro build 18262
    Thread Starter
       01 Apr 2018 #2

    Tutorial updated for IPv6, and added more free DNS servers. :)
      My ComputersSystem Spec

  3.    11 Apr 2018 #3

    TairikuOkami said: View Post
    To change DNS on DHCP enabled network (without the need to enter the name):
    Code:
    wmic nicconfig where DHCPEnabled=TRUE call SetDNSServerSearchOrder ("208.67.222.222","208.67.220.220")
    That is pretty neat - it is nice to be able to run a command without having to find interface name manually - but SetDNSServerSearchOrder doesn't seem to work for IPv6 - I get error 70 invalid IP address.

    In Powershell you do both IPv4 and IPv6 at once for all valid adapters.
    Code:
    Get-NetAdapter | `
      Where-Object {$_.InterfaceIndex -in $(Get-DnsClientServerAddress).InterfaceIndex} | `
      Set-DnsClientServerAddress -Addresses ('1.1.1.1','1.0.0.1','2606:4700:4700::1111','2606:4700:4700::1001')
    Set-DnsClientServerAddress is worse than SetDNSServerSearchOrder in that it fails if it finds an invalid network adapter (such as a network bridge) - that is why you need the Where-Object bit. Conversely SetDNSServerSearchOrder just carries on and reports its failed attempts.

    Pros and cons I suppose but in section 3 of the tutorial steps 5 and 6 could be combined - no need to do them separately if you don't want to.
      My ComputerSystem Spec

  4. Brink's Avatar
    Posts : 33,070
    64-bit Windows 10 Pro build 18262
    Thread Starter
       11 Apr 2018 #4

    Thank you for the addition. :)
      My ComputersSystem Spec

  5. TairikuOkami's Avatar
    Posts : 3,415
    10.6 Home 1809 x64
       12 Apr 2018 #5

    Brink said: View Post
    added more free DNS servers. :)
    How about making a tutorial for Family friendly DNS?

    Sorted by effectiveness: CleanBrowsing / UltraDNS / NortonDNS / OpenDNS

    There also those 2, but they are questionable, though Adguard has a nice landing page.

    Yandex (servers mostly for Russia ) / Adguard (blocks ADs and thus break some webpages)
      My ComputerSystem Spec

  6. Brink's Avatar
    Posts : 33,070
    64-bit Windows 10 Pro build 18262
    Thread Starter
       12 Apr 2018 #6

    Thank you for the additional DNS servers. :)
      My ComputersSystem Spec

  7. Brink's Avatar
    Posts : 33,070
    64-bit Windows 10 Pro build 18262
    Thread Starter
       1 Week Ago #7

    Tutorial updated to add Option 5 to change DNS address in Settings.
      My ComputersSystem Spec


 

Tutorial Categories

Change IPv4 and IPv6 DNS Server Address in Windows Tutorial Index Network & Sharing Instalation and Upgrade Browsers and Email General Tips Gaming Customization Apps and Features Virtualization BSOD System Security User Accounts Hardware and Drivers Updates and Activation Backup and Restore Performance and Maintenance Xbox Windows Phone


Related Threads
Each time I switch on my W10 PC, I get an Error 1002 "Address configuration status event" show up in event viewer, and its error description is - The IP address lease 192.168.1.2 for the Network Card with network address 0x00..snip has been...
Hey guys, How to change MAC Address via reg file ? Regards.
Mail Server Address in Browsers and Email
I am trying to add a new email address to my Outlook email server. I tried to install it automatically but it keeps asking for my mail server. How do I find out what my mail server is. I have Windows 10, Office 365, Outlook 2016. any help...
For several weeks I have been using W10 with two Linux servers, B767 and B777. Until an hour ago, Windows Explorer saw both of them just fine and everything worked as expected. After a brief hiatus, I came back to the computer and it showed big...

Tags for this Thread

Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 14:01.
Find Us