Tech News Today
  • Hardware
    • Motherboards
    • CPUs
    • Graphic Cards
    • RAM
    • SSDs
    • Computer Cases
    • Monitors
    • Peripherals
    • Power Supply Unit
    • PC Builds
    • Computer Tips
  • Software
  • Operating System
    • Windows
    • Mac
    • Linux
  • Gaming
  • Mobile
  • Console
  • More
    • Internet
    • Networking
    • Security
    • Buyer’s Guide
    • Gadgets
    • Laptops
    • Reviews
    • How To
    • News
Facebook Twitter Instagram
Tech News Today
  • Hardware
    • Motherboards
    • CPUs
    • Graphic Cards
    • RAM
    • SSDs
    • Computer Cases
    • Monitors
    • Peripherals
    • Power Supply Unit
    • PC Builds
    • Computer Tips
  • Software
  • Operating System
    • Windows
    • Mac
    • Linux
  • Gaming
  • Mobile
  • Console
  • More
    • Internet
    • Networking
    • Security
    • Buyer’s Guide
    • Gadgets
    • Laptops
    • Reviews
    • How To
    • News
Tech News Today
Home » Networking

How to Change Your DNS Server (Complete Guide)

Abhishek SilwalBy Abhishek SilwalJune 21, 2023
How to Change Your DNS Server

All the resources or web servers on the internet have unique addresses assigned to them, which are the IP addresses. The Domain Name System (DNS) is basically a phonebook for the internet that translates or resolves the domain name or URL you type on web browsers to these IP addresses so that you can access the resources. 

Normally, your ISP automatically designates the DNS servers you need for the domain name resolution. However, these servers may come with certain restrictions. So, you may want to change the DNS for faster internet browsing as well as to access more resources on the internet.

Caution:

Using random DNS servers can invite various DNS problems. These issues range from less severe ones like high latency to major attacks like DNS cache poisoning, Denial of Service (DOS), and so on.

If you don’t have an appropriate DNS server in mind, we recommend using public DNS servers as manual DNS addresses. Many public DNS are available for your use, such as:

Google
  • IPv4: 8.8.8.8 and 8.8.4.4
  • IPv6: 2001:4860:4860::8888 and 2001:4860:4860::8844
  • Cloudflare
  • IPv4: 1.1.1.1 and 1.0.0.1
  • IPv6: 2606:4700:4700::1111 and 2606:4700:4700::1001
  • OpenDNS
  • IPv4: 208.67.222.222 and 208.67.220.220
  • IPv6: 2620:119:35::35 and 2620:119:53::53

  • You can use the first address in the Preferred DNS address and the second one under Alternate DNS Addresses.

    Table of Contents

    • Change DNS Server on Windows
      • Through Windows Settings
      • From Control Panel
      • Using Command Prompt
      • With PowerShell
    • Change DNS Server on Mac
    • Change DNS Server on Android
    • Change DNS Server on iPhone
    • Change DNS Server on Router

    Change DNS Server on Windows

    There are many methods to set up or change the DNS server on Windows. You can use all of them to change the DNS address for the IPv4 address, or the IPv6 address, or both depending on your need. 

    If you don’t know which one to change, go for IPv4, as it is the default internet protocol for almost all web servers.

    Note: If you can’t access certain websites after changing the DNS, it’s better to flush the DNS cache by entering the ipconfig /flushdns command on Command Prompt.
    If you want more information, I recommend checking out my other article to reset an internet connection on Windows.

    Through Windows Settings

    Windows Settings is the default application you can use to change all your system settings, including the manual DNS server address. It also allows you to easily encrypt your DNS for more security.

    1. Press Windows key + I to open Windows Settings.
    2. Go to Network & internet and select your network type (Ethernet or WiFi).
    3. Click on Edit under DNS server assignment.
      edit-dns-server-assignment-ethernet-network-settings
    4. Set the drop-down box to Manual.
    5. Toggle On the IPv4 or IPv6 switch depending on which protocol’s DNS address you want to modify. 
    6. Enter the Preferred and Alternate DNS addresses per your preference.
    7. You can also modify the Preferred and Alternate DNS encryption drop-down boxes to set up encryption.
    8. Select Save after you are done.
      edit-dns-seattings-manual-ipv4-preferred-and-alternate-dns-save

    From Control Panel

    You can also change all relevant network settings, including the DNS address, using the Command Prompt.

    1. Open Run by pressing Windows + R.
    2. Type ncpa.cpl and press Enter to open Control Panel’s Network Connections options.
    3. Right-click on your Ethernet or WiFi connection (depending on which one you are using) and select Properties.
      network-connections-ncpa-ethernet-properties
    4. Double-click on Internet Protocol Version 4 (TCP/IPv4) or Internet Protocol Version 6 (TCP/IPv6) depending on your need.
      ethernet-properties-internet-protocol-version-4
    5. Check Use the following DNS server addresses.
    6. Enter the Preferred DNS server and the Alternate DNS server addresses. Click OK.
      internet-protocol-version-4-use-the-following-dns-server-addresses

    Using Command Prompt

    It is also possible to change the DNS server address for both IPv4 and IPv6 using the Command Prompt.

    However, the command to set up the primary (or preferred) and the alternate DNS server addresses are somewhat different. So go through the following steps carefully before carrying them out.

    1. Open Run.
    2. Type cmd and press Ctrl + Shift + Enter to open the Elevated Command Prompt.
    3. Type netsh interface show interface and press Enter to check all available network interfaces on your computer.
    4. Then, type the command netsh interface <ipv4/ipv6> set dnsservers <Interface Name> static <Preferred DNS address> primary while replacing all the values in the angled brackets appropriately and press Enter.
      • <ipv4/ipv6> – You can use either ipv4 or ipv6
      • <Interface Name> – Use the proper Interface Name that you saw from the netsh interface show interface command.
      • <Preferred DNS address> – The Preferred or primary DNS server address you want to set up.
    5. Now, use the command netsh interface <ipv4/ipv6> add dnsservers <Interface Name> static <Alternate DNS address> index=2 to set up the Alternate DNS address.
    6. For instance, if you want to set IPv4 DNS addresses for Ethernet as 1.1.1.1 and 1.0.0.1, you need to enter the following commands:
      • netsh interface ipv4 set dnsservers “Ethernet” static 1.1.1.1 primary
      • netsh interface ipv4 add dnsservers “Ethernet” 1.0.0.1 index=2
        netsh-interface-show-interface-ipv4-set-add-dnsservers

    With PowerShell

    You can also use the Set-DNSClientServerAddress cmdlet on PowerShell to change the DNS server address. 

    You can actually use the same cmdlet with the same attributes for both IPv4 and IPv6. Your system will automatically change the setting for the relevant protocol depending on the address.

    1. Open Run.
    2. Type powershell and press Ctrl + Shift + Enter to open the Elevated Windows PowerShell.
    3. Type Get-DnsClientServerAddress and press Enter to list out all the available network interface names or aliases.
    4. Then, type Set-DNSClientServerAddress “Interface Alias” -ServerAddresses (“Preferred DNS address”, “Alternate DNS address”) and press Enter. Make sure to replace “Interface Alias”, “Preferred DNS address” and “Alternate DNS address” with the proper values.
    5. For example, if you want to set Cloudflare’s IPv4 DNS addresses for Ethernet, you can use the cmdlet Set-DNSClientServerAddress “Ethernet” -ServerAddresses (“1.1.1.1”, “1.0.0.1”)
    6. Similarly, you can use Set-DNSClientServerAddress “Ethernet” -ServerAddresses ("2606:4700:4700::1111", "2606:4700:4700::1111") to set the Cloudflare public DNS for IPv6.
      powershell-get-set-dnsclientserveraddress-ethernet-ipv4-and-ipv6

    Change DNS Server on Mac

    Mac also offers an easy way to change the DNS server address through its Network Preferences. 

    You can also set up a search domain in the same setting window which you can use to easily go through the website you visit most frequently.

    1. Click on the Apple icon and go to System Preferences > Network.
      system-preferences-network-mac
    2. Select a network from the list and choose Advanced > DNS.
    3. Click the lock and enter your credentials.
    4. Select the + sign below the list of DNS Servers.
    5. Type the address and press Enter.
      network-advanced-dns-add-server
    6. You can use a similar method to add a search domain on its list depending on your need
    7. Click OK and then Apply.

    Change DNS Server on Android

    You can easily change the DNS server on Android phones by enabling Static IP settings for a particular Wi-Fi network. Unlike other devices, you can only set up manual DNS address if the IP address is also static.

    Android phones show different settings and interfaces depending on the Original Equipment Manufacturer (OEM), so the steps below may not work on your device. But the general process should be the same, so you should be able to figure out what you need to do after exploring the WiFi settings for some time.

    1. Open Settings and go to Connections > Wi-Fi.
    2. Tap on the gear icon next to your network.
      android-wifi-settings-gear-icon
    3. Select View more or Advanced.
    4. Tap on IP settings and set it to Static.
    5. Enter the DNS addresses in DNS 1 and DNS 2. You don’t need to change the IP and Gateway addresses.
      android-manual-dns-addresses

    You can also change the secure DNS on certain web browsers like Google Chrome. In fact, they automatically provide options to use public DNS like Google’s, Cloudflare’s and so on.

    1. Open the Google Chrome app.
    2. Tap on the triple-dot icon and select Settings.
      android-chrome-settings
    3. Go to Privacy and security > Use secure DNS.
    4. Check Choose another provider.
    5. Tap on the downward arrow icon and select a public DNS.
      chrome-use-secure-dns-choose-another-provider

    Change DNS Server on iPhone

    Similar to Android, you will need to get to the settings for a particular Wi-Fi network and enable manual DNS to change the address.

    Also, keep in mind that the steps may also differ depending on the iPhone version and software. But since the steps should be relatively similar, you can look around for the proper options on your own. If you encounter any issues, I recommend seeking help from official sources.

    1. Go to Settings and select Wi-Fi.
    2. Tap on the i icon next to your network.
      iphone-wifi-setting-i-icon
    3. Select Configure DNS and then check Manual.
    4. Tap on Add Server.
      iphone-configure-dns-manual-add-server
    5. Set the DNS server per your wish and click on Save.

    Change DNS Server on Router

    Apart from your main devices, you can also change the DNS server on your router’s configuration. You will need to access the router’s portal to change this setting.

    Different routers (and their different models) have different portal interfaces and configurations. So you need to visit official sources to get detailed information on how you can change the DNS server. Here, I have used a TP-Link router to give you an example.

    1. Enter the router’s Gateway IP into your web browser’s address bar. For TP-Link, the address is 192.168.0.1 or 192.168.1.1
      The router should usually have stickers that show the gateway address. If not, you can use the following commands on the default command-line interface of your device to get this info:
      • Windows – WMIC NICConfig where IPEnabled="True" get DefaultIPGateway
      • Mac – netstat -rn | grep default | awk '{print $2}'
    2. Enter your username and password to log in to this portal.
    3. On the TP-Link router’s portal, go to the Advanced tab.
    4. Expand Network and select Internet.
    5. Check the value of the IP Address, Subnet Mask and the Default Gateway.
      tplink-router-portal-advanced-network-internet-ip-address-subnet-mask-default-gateway
    6. Set the Internet Connection Type to Static IP.
    7. Enter the IP Address, Subnet Mask and the Default Gateway that you noted previously.
    8. Set the Primary DNS and Secondary DNS depending on your wish.
    9. Click Save.
      tplink-router-static-ip-primary-and-secondary-dns
    how-to
    Abhishek Silwal
    • LinkedIn

    Abhishek Silwal is an Electronics Engineer and a technical writer at TechNewsToday. He specializes in troubleshooting a wide range of computer-related issues. His educational background in Electronics Engineering has given him a solid foundation in understanding of computers. He is also proficient in several programming languages and has worked on various robotics projects. Even in his early days, he used to tinker with various computer components, both hardware, and software, to satiate his curiosity. This experience has given him a breadth of experience that goes beyond his educational qualification. Abhishek has been writing articles on dealing with varieties of technical issues and performing specific tasks, especially on a Windows machine. He strives to create comprehensive guides on fixing many system and hardware issues and help others solve their problems. You can contact him at abhisheksilwal@technewtoday.com

    Related Posts

    intel wireless ac 9560 not working

    Intel Wireless AC 9560 Not Working? Try these Fixes

    September 16, 2023
    does your ip address change when you move

    Does Your IP Address Change When You Move?

    July 16, 2023
    locate wifi access point

    How to Locate a Wi-Fi Access Point

    July 6, 2023
    lease time dhcp

    What is DHCP Lease time? Can You Change It?

    July 2, 2023
    Failed to obtain IP address 1

    5 Ways to Fix “Failed to Obtain IP Address”

    June 30, 2023
    How to Forget a Network

    How to Forget a Network on Windows

    June 27, 2023
    Add A Comment

    Leave A Reply Cancel Reply

    Latest Posts
    how to turn off hardware acceleration

    How to Turn Off Hardware Acceleration

    September 22, 2023
    motherboard chipset

    Understanding Motherboard Chipset and Its Importance

    September 20, 2023
    Naval-Warfare-Games

    Best Naval Warfare Games

    September 18, 2023
    You may also like
    printer-not-printing

    How to Fix a Printer That’s Not Printing

    September 20, 2023
    Share Location With Friends and Family

    Share Location With Friends and Family (iPhone and Android)

    September 18, 2023
    how-to-print-without-a-printer

    How to Print Without a Printer

    September 18, 2023
    Recommended
    Cookie Clicker Garden Guide

    Cookie Clicker Garden Guide to Unlocking Every Seed

    September 26, 2021
    monitor no signal

    Computer Turns On But Monitor Says No Signal (9 Ways To Fix)

    November 10, 2022
    Facebook Twitter Pinterest
    • Home
    • About Us
    • Our Team
    • Editorial Guidelines
    • Privacy Policy
    • Affiliate Disclosure
    © 2023 TechNewsToday, editor@technewstoday.com | Tech Central Pvt. Ltd.

    Type above and press Enter to search. Press Esc to cancel.