Best DNS Servers for Privacy and Security
Whoever runs your DNS server sees every site you look up. Your ISP's default is rarely the most private choice. Here is how the common options compare.
Last updated November 21, 2026 · By Harbor Privacy
The Best DNS Servers at a Glance
Short answer: for privacy plus malware protection, use Quad9. For speed with a strong privacy record, use Cloudflare. To block ads and trackers too, use AdGuard DNS or Harbor Adblock. Skip your ISP's default, and skip Google if privacy is the goal.
- Best for privacy and malware blocking: Quad9 (9.9.9.9)
- Best for speed: Cloudflare (1.1.1.1)
- Best for blocking ads and trackers: AdGuard DNS (94.140.14.14), or Harbor Adblock for every device with no logs
- Best for no filtering and no logs: Mullvad (encrypted DNS only, host dns.mullvad.net)
| Provider | IPv4 (primary, secondary) | IPv6 | DoH / DoT host | Notes |
|---|---|---|---|---|
| Quad9 | 9.9.9.9 149.112.112.112 | 2620:fe::fe 2620:fe::9 | dns.quad9.net | Blocks known malicious domains. Non-profit, Switzerland. |
| Cloudflare | 1.1.1.1 1.0.0.1 | 2606:4700:4700::1111 2606:4700:4700::1001 | cloudflare-dns.com | Fast, audited privacy commitment. 1.1.1.2 adds malware blocking. |
| 8.8.8.8 8.8.4.4 | 2001:4860:4860::8888 2001:4860:4860::8844 | dns.google | Fast and reliable, but run by an ad company and logs some data. | |
| AdGuard DNS | 94.140.14.14 94.140.15.15 | 2a10:50c0::ad1:ff 2a10:50c0::ad2:ff | dns.adguard-dns.com | Blocks ads, trackers and malware by default. |
| Mullvad | Encrypted DNS only (DoH or DoT) | Use the hostname | dns.mullvad.net | From a no-logs VPN company. No filtering on the base server. Plain DNS to its address is refused outside the Mullvad VPN, so use DoH or DoT. |
Addresses were tested on the date above (IPv4 plain DNS for Quad9, Cloudflare, Google and AdGuard; Mullvad over DoT). Check the provider's own page if one stops working.
Primary and Secondary DNS: What to Enter
Most devices ask for a primary and a secondary server. The secondary is the backup used if the first does not answer. Use the two addresses from the same provider, such as 9.9.9.9 and 149.112.112.112 for Quad9. Mixing providers works, but your lookups then split across two companies, which spreads your data around instead of protecting it.
To set it, see Change your router DNS to cover your whole home, or Private DNS on iPhone and Android for a phone. Then confirm it took effect with the DNS checker.
Run Your Own: AdGuard Home or Pi-hole
If you do not want to trust any public resolver, run your own filtering server at home. Both AdGuard Home and Pi-hole do this. See AdGuard Home vs Pi-hole to choose, and AdGuard Home on a Raspberry Pi to set it up. Your own server still sends its upstream lookups to someone, so pick a no-logs upstream like Quad9 or Mullvad.
Why Your DNS Server Matters
Every lookup reveals a site you are about to visit. The resolver you use can log those lookups, filter them, or sell them. Choosing one is a privacy decision. See DNS privacy for how it works.
Common Options
- Your ISP's DNS. The default. Convenient, but your provider sees and may keep your lookups.
- Quad9 (9.9.9.9). A non-profit based in Switzerland that blocks known malicious domains and publishes a privacy policy.
- Cloudflare (1.1.1.1). Fast, with a stated privacy commitment and external audits of its claims.
- Google (8.8.8.8). Fast and reliable, but run by an ad company and subject to its logging practices.
- AdGuard DNS and similar. Block ads and trackers as well as malware.
- A private resolver you run or subscribe to. The most control. Harbor Adblock provides filtered DNS for every device.
What to Look For
Filtering Without Handing Data to a Big Company
Harbor Adblock gives every device filtered DNS with encrypted transport and no logs. See Harbor Adblock, or compare it with a VPN in DNS ad blocker vs VPN.
Related guides: DNS privacy, Private DNS on iPhone and Android, DNS leaks, DoH vs DoT, Change your router DNS.
Common Questions
Harbor Adblock blocks ads, trackers, and malware for every device. See Harbor Adblock.