Why Change Your DNS Server?
Your ISP provides a default DNS server, but switching to a third-party DNS can offer several benefits:
- Speed: Public DNS servers like Cloudflare (1.1.1.1) and Google (8.8.8.8) are often faster than ISP DNS, reducing page load times.
- Reliability: Major public DNS services have 100% uptime SLAs and global anycast networks. ISP DNS servers sometimes go down or become slow.
- Privacy: Some DNS providers (like Cloudflare) commit to not selling your DNS queries and purge logs within 24 hours. ISP DNS may log and sell your browsing data.
- Security: Services like Quad9 (9.9.9.9) automatically block known malicious domains. Cloudflare's 1.1.1.2 and 1.1.1.3 offer content filtering options.
- Access: Some ISP DNS servers have stale caches or fail to resolve certain domains. Switching to a public DNS can fix these issues.
Popular DNS Servers
| Provider | Primary | Secondary | Focus |
|---|---|---|---|
| Cloudflare | 1.1.1.1 | 1.0.0.1 | Speed and privacy |
| 8.8.8.8 | 8.8.4.4 | Reliability | |
| Quad9 | 9.9.9.9 | 149.112.112.112 | Security (blocks malware) |
| OpenDNS | 208.67.222.222 | 208.67.220.220 | Customizable filtering |
| Cloudflare Family | 1.1.1.3 | 1.0.0.3 | Blocks malware + adult content |
Which one to choose? Cloudflare (1.1.1.1) is typically the fastest. Google (8.8.8.8) has the longest track record. Quad9 is best if you want automatic malware blocking. OpenDNS is best for families who want content filtering with custom settings.
Change DNS on Windows 10/11
- Open Settings > Network & internet > Wi-Fi (or Ethernet).
- Click on your connected network.
- Click Edit next to DNS server assignment.
- Switch from "Automatic (DHCP)" to Manual.
- Toggle IPv4 on.
- Enter your preferred DNS server (e.g., 1.1.1.1) as Preferred DNS.
- Enter the secondary DNS (e.g., 1.0.0.1) as Alternate DNS.
- Optionally toggle IPv6 on and enter the IPv6 DNS addresses.
- Click Save.
Verify: Open Command Prompt and run nslookup google.com. The server shown should be your new DNS. Also check using LookMyIP's DNS Lookup tool to confirm queries are going through the expected resolver.
Change DNS on macOS
- Open System Settings (or System Preferences on older macOS).
- Click Network in the sidebar.
- Select your active connection (Wi-Fi or Ethernet).
- Click Details (or Advanced on older macOS).
- Click DNS in the sidebar.
- Click the + button to add DNS servers.
- Enter 1.1.1.1 and 1.0.0.1 (or your preferred DNS).
- Remove any existing DNS entries you don't want by selecting them and clicking -.
- Click OK, then Apply.
Flush DNS cache after changing: Open Terminal and run:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
Verify: Run nslookup google.com in Terminal to confirm the new DNS is being used.
Change DNS on Linux
Using NetworkManager (Ubuntu, Fedora, etc.):
- Open Settings > Network > click the gear icon on your connection.
- Go to the IPv4 tab.
- Turn off "Automatic" for DNS and enter your DNS servers.
- Apply and reconnect.
Using the terminal (systemd-resolved):
- Edit /etc/systemd/resolved.conf:
sudo nano /etc/systemd/resolved.conf
- Set:
DNS=1.1.1.1 1.0.0.1 - Restart the service:
sudo systemctl restart systemd-resolved
Change DNS at the router level (recommended): Changing DNS on your router applies to every device on your network:
- Log into your router's admin panel (usually 192.168.1.1 or 192.168.0.1).
- Find DNS settings (often under WAN, Internet, or DHCP settings).
- Replace the ISP DNS servers with your preferred DNS (e.g., 1.1.1.1 and 1.0.0.1).
- Save and reboot the router.
This is the best approach because it protects all devices, including smart home devices and IoT devices that you can't configure individually.
