How to Change DNS Settings on Any Device: Step-by-Step Guide
DNS is a system that gives names to other computers and devices connected to the internet. If you want to know how to change DNS settings on your device, you’ve come to the right place. DNS also works to identify computers on private networks. While most end users won’t know the more obscure functions that a DNS service performs, they will know that it helps them browse the internet.
DNS is basically a directory that matches names i.e. website domains to their IP addresses. You can use a public DNS service like that provided by Google, or you can let your ISP decide which DNS service to use.
Changing the DNS service that you use can often speed up browsing, which is why users will often configure a custom DNS on their desktops, and even their smartphones.
A fast DNS service can quickly look up a domain name, get its IP address, and fetch the website for you. You can use any DNS service if it is public and you know the server address for it.
Which DNS Server Should You Use?
Before you change your DNS settings, you need to know what to enter. There are several reliable public DNS providers to choose from, each with different strengths. You should always enter both a primary and a secondary DNS server so your connection has a fallback if the first one is unreachable.
Here are the most widely used options, with both IPv4 and IPv6 addresses:
- Cloudflare (1.1.1.1 / 1.0.0.1 | IPv6: 2606:4700:4700::1111 / 2606:4700:4700::1001) — Known for being one of the fastest public DNS resolvers available. Cloudflare also emphasizes privacy and does not sell your browsing data. A good all-around choice for speed and privacy.
- Google Public DNS (8.8.8.8 / 8.8.4.4 | IPv6: 2001:4860:4860::8888 / 2001:4860:4860::8844) — Highly reliable and fast, with a long track record of uptime. A solid default choice for most users.
- Quad9 (9.9.9.9 / 149.112.112.112 | IPv6: 2620:fe::fe / 2620:fe::9) — Focuses on security. Quad9 automatically blocks known malicious domains, making it a smart pick if you want built-in malware protection without extra software.
- OpenDNS (208.67.222.222 / 208.67.220.220 | IPv6: 2620:119:35::35 / 2620:119:53::53) — Offers both free and paid tiers. The free tier includes phishing protection, and the paid tier adds content filtering, making it popular for families and small businesses.
You can enter the IPv6 addresses in the same DNS settings panels covered below, alongside or instead of the IPv4 addresses, depending on your network setup. Note that some devices require the full expanded IPv6 notation rather than the shortened :: format — if a shortened address is not accepted, try entering the fully expanded version instead.
How to Change DNS Settings on Windows
DNS settings are configured per network adapter, so the change applies only to the specific connection you modify. This means you can set different DNS servers for your home Wi-Fi and your office Ethernet adapter independently. Before replacing any DNS values, take a moment to note down your current DNS entries — writing them down or taking a screenshot — so you can easily revert if anything goes wrong.
Windows 11 (Settings App)
On Windows 11, the easiest way to change DNS is through the modern Settings app. Open Settings and go to Network & internet. Select either Wi-Fi or Ethernet depending on your active connection. Click Hardware properties (for Wi-Fi) or the connection name (for Ethernet). Next to DNS server assignment, click Edit. Change the dropdown from Automatic (DHCP) to Manual. Toggle on IPv4 and/or IPv6 as needed, then enter your Preferred DNS and Alternate DNS addresses in the fields provided. Click Save when done.
Windows 10 (and Alternate Path for Windows 11): Control Panel
On Windows 10, you can access the Control Panel from Windows Search, or you can type Control Panel in the address bar in File Explorer. Go to Network and Internet > Network and Sharing Center. Click the active network adapter you want to modify — this may be your Wi-Fi connection or your Ethernet connection.
On the connection Status window, click the Properties button in the Activity section. On the properties window that opens, double-click Internet Protocol Version 4 (TCP/IPv4).
This will open Internet Protocol Version 4 (TCP/IPv4) properties window. Here, select the ‘Use the following DNS server address’ option. Enter the DNS server address you want to use, and click OK.
How to Change DNS Settings on Android and iPhone/iPad
Android
Modern Android versions offer a system-wide Private DNS feature that works with encrypted DNS providers that support a hostname (also called DNS-over-TLS). This is the recommended approach because it applies to your entire device, not just a single network. To use it, go to Settings > Network & Internet > Private DNS, select Private DNS provider hostname, and enter the hostname for your preferred provider — for example, dns.google for Google Public DNS or 1dot1dot1dot1.cloudflare-dns.com for Cloudflare. Tap Save.
If you want to enter specific DNS IP addresses for a particular Wi-Fi network instead, long-press a saved Wi-Fi network in your Wi-Fi settings, tap Modify network, expand Advanced options, change IP settings to Static, and scroll down to the DNS fields. Note that this method only applies to that specific network and requires you to also fill in an IP address, gateway, and subnet mask manually, so it is a more advanced option.
iPhone and iPad (iOS/iPadOS)
On iPhone and iPad, DNS settings are configured per Wi-Fi network rather than system-wide. To change DNS for your current network, go to Settings > Wi-Fi and tap the information icon (ⓘ) next to the network you are connected to. Scroll down and tap Configure DNS. Change the setting from Automatic to Manual. Tap the red minus icon to remove any existing DNS servers you want to replace, then tap Add Server and enter your preferred DNS address. Repeat to add an alternate DNS server. Tap Save in the top right when finished.
Keep in mind that this change only applies to the specific Wi-Fi network you modified. If you connect to a different network, you will need to repeat these steps for that network as well. There is currently no built-in system-wide custom DNS option on iOS/iPadOS without using a VPN or a DNS configuration profile.
How to Change DNS Settings on macOS
The steps to change DNS settings on macOS depend on which version you are running. If you are on macOS Ventura, Sonoma, or Sequoia, Apple replaced System Preferences with System Settings. If you are on macOS Monterey or earlier, the interface uses System Preferences instead.
macOS Ventura, Sonoma, and Sequoia: Click the Apple menu and open System Settings. Select Network from the sidebar. Choose your active connection — either Wi-Fi or Ethernet — and click Details. Go to the DNS tab. Click the plus sign to add a DNS server address, enter your preferred server, and click OK to save.
macOS Monterey and earlier: Open System Preferences and go to the Network group of preferences.
Select a network, Ethernet or WiFi, from the left column and click the Advanced button at the bottom right.
On the advanced settings panel, go to the DNS tab. Here, click the plus sign at the bottom of the column on the left. Enter the DNS server address for the DNS service you want to use. Click Ok, apply the change, and the DNS server will be changed.
macOS lets you configure several different DNS services, which means if one goes down, it will automatically use the second, or third one. Windows also natively supports a preferred and an alternate DNS server, and additional DNS entries can be managed through the adapter’s advanced settings; macOS simply presents multiple servers as an ordered list in one convenient panel.
How to Change DNS Settings on Your Router
Changing DNS at the router level is the most convenient option if you want every device on your home network — phones, tablets, smart TVs, and computers — to use the same DNS server without configuring each one individually.
The exact interface varies by router brand, but the general process is the same across most models:
- Open a browser and type your router’s admin IP address into the address bar. This is commonly 192.168.1.1 or 192.168.0.1, though it may differ. Check the label on the bottom of your router if you are unsure.
- Log in with your router’s admin username and password. If you have never changed these, the defaults are usually printed on the router itself.
- Look for a section labeled Internet, WAN, or DHCP Settings — the exact name depends on your router’s firmware.
- Find the Primary DNS and Secondary DNS fields and enter the addresses for the DNS provider you want to use.
- Save your changes. Some routers will apply the new settings immediately; others may require a reboot. If prompted, restart the router.
One important tradeoff to keep in mind: router-level DNS is convenient for whole-home coverage, but some ISP-supplied routers lock down the DNS fields or silently override custom entries. If you enter a DNS server and it does not appear to take effect, your ISP’s router may be blocking the change. In that case, knowing how to change DNS settings directly on each device — as described in the Windows and macOS sections above — is the more reliable approach. Additionally, changing your DNS settings can help you access blocked pages that may be restricted by your default DNS provider.
Flush DNS Cache and Verify the Change
After updating your DNS settings, your device may still use cached DNS results from the old server for a short time. Flushing the DNS cache forces your device to look up addresses fresh using the new server, and it is a good habit to do this right after making a change.
Windows:
Open Command Prompt as an administrator. Search for “cmd” in the Start menu, right-click it, and choose Run as administrator. Then run the following command to clear the cache:
ipconfig /flushdns
To confirm that your new DNS servers are active, run:
ipconfig /all
Look for the adapter you changed and check the DNS Servers line to verify the correct addresses appear. You can also use nslookup to test a domain lookup and confirm which server responds.
macOS:
Open Terminal and run the following command to flush the DNS cache:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
You will be prompted for your administrator password. To verify the change took effect, you can check the DNS tab in your Network settings (under Details or Advanced, depending on your macOS version) to confirm the correct servers are listed.
You can also run the following in Terminal to see the DNS configuration your system is actively using:
scutil --dns
On both platforms, if you are still seeing old results in your browser after flushing the cache, try closing and reopening the browser or disconnecting and reconnecting to your network. Browsers maintain their own short-lived DNS caches that can persist briefly after a system-level flush. Once you have confirmed the correct servers are listed, you have successfully completed how to change DNS settings on your device.
Troubleshooting Common DNS Change Issues
DNS changes usually take effect within seconds, but a few common problems can make it seem like nothing has changed — or break your connection entirely. Here is what to check and how to fix each issue quickly.
- Internet stops working after the change. This almost always means a typo in the DNS address. Double-check the numbers you entered against the provider’s published addresses, correct any errors, and save again. If in doubt, revert to Automatic (DHCP) DNS to restore your connection immediately.
- The router or ISP is overriding your custom DNS. Some ISP-supplied routers silently force their own DNS regardless of what you enter. If
ipconfig /all(Windows) orscutil --dns(macOS) still shows your ISP’s servers, set DNS directly on each device rather than at the router level, or consider switching to an ISP-compatible router. - The change does not appear to apply yet. DNS settings sometimes require a reconnect or a full reboot before they take effect. Disconnect from the network and reconnect, or restart your device. On Windows, also run
ipconfig /flushdnsin an elevated Command Prompt to clear the local DNS cache. - Your browser is using its own Secure DNS setting. Chrome, Firefox, and Edge all have a built-in DNS-over-HTTPS (DoH) feature that can override your system DNS. Check your browser’s privacy or security settings and either disable Secure DNS or point it to the same provider you configured at the system level.
- A VPN or app-specific DNS is taking precedence. Active VPNs route DNS through their own servers by design. If you are using a VPN, check its settings for a DNS leak protection option or a custom DNS field, and enter your preferred DNS there. You can verify which DNS server is actually being used by running a DNS leak test at a site such as dnsleaktest.com.
If you have worked through all of the above and the new DNS is still not taking effect, run ipconfig /all on Windows or scutil --dns on macOS one more time to confirm the active server. These commands show you exactly what your system is using at that moment, which takes the guesswork out of diagnosing the problem.
“Change DNS Server – Windows You must be connected to a WiFi network.” This sort of implies you cannot change the DNS for an ethernet connection. I changed mine long ago, it works just fine.