If you're tired of ads interrupting you inside apps, games, and even the browser, there's a solution already built into your phone's settings since Android 9 that most people have never heard of: Private DNS. With a single option you change the "phone book" your phone asks for website addresses, so ad and tracker domains get blocked before they ever reach your device. This method needs no root, no installed apps, and it's completely free — here's how to enable it step by step, plus an honest look at what it does and doesn't block.
The idea in simple terms: how does it block ads?
Any app that wants to show you an ad has to contact an ad company's server (like googlesyndication or doubleclick). That connection starts with a DNS question: "what's this domain's address?" Blocking-focused DNS servers like AdGuard DNS keep a huge database of ad and tracking domains, and when a query for an ad domain arrives, they answer that it doesn't exist — so the app simply can't load the ad. All of this happens at the system level: it works across every app, not just the browser, without installing anything.
Setup steps on stock Android and most skins
Open your phone's Settings.
Go to Network & Internet.
Tap Private DNS — sometimes it's under "More" or "Advanced" options.
Choose Private DNS provider hostname.
Type exactly: dns.adguard-dns.com
Tap Save. If the option now shows the address you typed instead of "Off", it's working.
No restart, no extra steps — blocking starts immediately on both Wi-Fi and mobile data.
The path on Samsung and Xiaomi
Samsung (One UI): Settings → Connections → More connection settings → Private DNS → choose "Private DNS provider hostname", enter the address, save.
Xiaomi (MIUI / HyperOS): Settings → Connection & sharing → Private DNS → same steps.
Huawei / Honor: Settings → Wireless networks or More connections → Private DNS.
How to confirm it's working
Open any site that used to drown you in ads and notice the difference, or launch a game with a banner ad at the bottom — it should disappear or stay blank. You can also revisit the Private DNS setting anytime: if your hostname is still there and selected, blocking is active.
The method's real limits (honestly)
Private DNS does not block everything. Ads inside the official YouTube app won't be affected, because YouTube serves ads from the same domains as its videos — blocking them would break the app itself. Ads in Facebook, Instagram, and TikTok that come from the same servers as content also won't be blocked as effectively. Think of it as a big, noticeable reduction of ads across most apps and websites, not the deletion of every ad on earth.
If you use a VPN: most VPN apps override the Private DNS setting and use their own resolver, so blocking won't work while the VPN is on unless the VPN app has its own ad-blocking feature.
Public Wi-Fi networks: some networks (cafes, airports) require a sign-in page, and Private DNS can prevent it from appearing. If a network won't connect, switch the option to "Automatic" temporarily, sign in, then re-enable it.
A site or app breaks: rarely, the blocking server may block a domain a legitimate app needs. The fix is simple: switch back to "Automatic" in the same setting and everything returns to normal instantly — there's no permanent modification to your system.
Alternatives from the same provider for different needs
Hostname | Purpose |
|---|---|
Block ads and trackers (the main choice) | |
Same blocking plus adult-content filtering — good for kids' phones | |
Encrypted DNS with no blocking — privacy only |
All of these are free official AdGuard servers, and they encrypt your queries (DNS-over-TLS), so even your ISP can't see the sites you visit as easily — an extra privacy win. And if you want to take isolation and privacy further, check our guide on Shelter, which isolates apps in a separate work profile.
If you want stronger blocking
Private DNS is the best balance of ease and safety because it's an official system feature. If you need finer control (custom rules, per-app whitelists), dedicated apps like AdGuard for Android create a local VPN on the device, but they request broader permissions and are downloaded from outside the Play Store — in that case, apply the checks from our APK verification guide. Our advice: start with Private DNS, and if it's enough — and it usually is — you're done.
The bottom line: Settings → Network & Internet → Private DNS → type dns.adguard-dns.com and save. Exactly two minutes, and you'll notice a clear drop in ads. Remember its limits with YouTube and VPNs, and if anything breaks, switch back to "Automatic" — as if you never changed a thing.





