DEV Community

Creto Si
Creto Si

Posted on Originally published at dubydex-blog.wasmer.app

Why Private DNS Keeps Turning Off on Android (and How to Keep It On)

Private DNS keeps turning off on Android phones for a handful of ordinary reasons — and each one has a different fix.

You set Private DNS to your chosen provider, everything works — and a day later you open Settings and it is back on Off, or back on Automatic. It feels like the phone is undoing your choice. In most cases it is not one single bug. It is one of a handful of ordinary causes, and each one has a different fix. This guide walks through them in order, so you can find yours in about two minutes.

Quick answer: the safest way to keep Private DNS on

Open Settings > Network & internet > Private DNS (on Samsung: Settings > Connections > More connection settings > Private DNS). If a VPN app is running, turn it off first — a VPN usually takes over DNS while it is connected. Choose Private DNS provider hostname, type the hostname exactly as your provider publishes it, and tap Save. Then restart the phone and check the setting again: if it reverted after the restart, the cause is your phone's software, not the network. If it only changes on one Wi-Fi network, that network is the cause. Keep Automatic as your safe fallback — it is the option to return to whenever a hostname breaks your connection. Never copy a hostname from a random comment or video; only use one published on the provider's own site.

What is Private DNS?

Private DNS is Android's built-in setting for encrypted DNS, available on Android 9 and later. DNS is the lookup that turns a website name into the address your phone connects to. Without encryption, that lookup travels in plain text and can be read by whoever runs the network. Private DNS sends it over an encrypted connection (DNS-over-TLS) to a resolver you choose, so the lookup itself is harder to read or change on the way. Google's own help page puts the scope plainly: "Private DNS helps secure only DNS questions and answers. It can't protect anything else."

What Private DNS can and cannot do

It can encrypt your DNS lookups on Wi-Fi and mobile data, system-wide, without installing an app. It cannot hide your IP address, encrypt the content of your browsing, block every tracker, or act as a VPN. It also cannot force a network to accept encrypted DNS: if a network blocks it, Android either falls back or the connection fails. Knowing that limit matters here, because several "it turned itself off" cases are really the setting doing exactly what it was designed to do.

Before you start

Note your current setting before you change anything: open Private DNS and write down which option is selected — Off, Automatic, or a provider hostname — and the exact hostname if one is entered. That note is your way back. If anything in this guide makes your connection worse, return to Automatic first; it is the safe fallback Google recommends keeping on. If your phone is a work or school device, check with whoever manages it before changing network settings — an administrator policy may control this setting, and changing it may not be allowed.

Why Private DNS keeps turning off

There is rarely one reason. Work through this list and check which one matches what you see.

1. It was on Automatic all along — and Automatic never engaged

This is the most common confusion. Automatic only encrypts your lookups when the network's own resolver supports it. On most home routers and public Wi-Fi networks it does not, so Android quietly falls back to plain DNS without showing any warning. The setting still says Automatic, but nothing is encrypted — which looks exactly like Private DNS being off. If you want encryption on every network, you need the provider-hostname option, not Automatic.

2. A VPN or DNS app took over

A VPN app that runs its own DNS usually takes over DNS lookups while it is connected. Some ad-blocker and DNS-changer apps do the same. That is expected behaviour, not a fault: only one DNS path can be in charge at a time. If your Private DNS hostname seems to stop working whenever a VPN is on, the VPN is the cause. Turn the VPN off, check Private DNS, and it should behave normally again.

3. Your phone's software reset it after a restart or update

Some phone software reverts the setting on its own. This has been reported on some Xiaomi phones running MIUI or HyperOS, where Private DNS can reset to Automatic after a reboot or a network change, silently dropping a custom provider. A system update can also reset network settings. If your setting changes after a restart but is fine the rest of the time, the phone software is the likely cause — and there is no user-facing lock for it. The honest fix is to check the setting after updates and restarts, or accept Automatic as the setting that survives them.

4. A work or school policy controls it

On a managed device, an administrator policy can hide the Private DNS control or lock it to a particular value. If the option is greyed out, missing, or changes back no matter what you enter, check whether the phone is managed — look for a work profile or a device-admin app in Settings. On a managed phone this is policy, not a bug, and only the administrator can change it.

5. The hostname failed, so you switched it off yourself

If the hostname you entered is mistyped, unreachable, or does not support encrypted DNS, Android shows an error such as "couldn't connect to private DNS server" — and the connection may stop working entirely. At that point most people switch the setting back to Off or Automatic to get the internet back. The setting did not turn itself off; a bad hostname forced the change. Re-check the hostname character by character against the provider's own site before trying again, and never enter an IP address in this field — it takes a hostname only.

6. Someone else switched it off

Anyone holding the phone can change this setting in a few taps — there is no lock on it. On a shared or family phone, another user may have turned it off to fix a connection problem, or a child may have changed it while exploring Settings. If the setting changes without you touching it, ask who else uses the phone.

7. You turned it off for a Wi-Fi login page and forgot to turn it back on

Hotel, airport and cafe Wi-Fi login pages hijack DNS to show the login screen, and encrypted DNS can break that. The correct move is to switch Private DNS off, sign in, then switch it back on — and the second half is the part people forget. If your Private DNS is off after a trip, this is almost certainly why.

How to find your cause in two minutes

Run these checks in order. Stop at the first one that explains what you see.

  • Open Private DNS and read the setting. Note exactly which option is selected — Off, Automatic, or a hostname. If it says Automatic, the "off" feeling is probably cause 1 above.
  • Turn off any VPN, ad-blocker or DNS app. Check the setting again. If it now holds, the app was taking over.
  • Restart the phone and check again. If the setting reverted after the restart, the phone's software is the cause.
  • Test on mobile data, then on Wi-Fi. If it only fails on one Wi-Fi network, that network blocks encrypted DNS.
  • Check whether the phone is managed. A work profile or device-admin app means a policy may be in charge.

How to keep Private DNS on

Once you know why Private DNS keeps turning off, these are the steps that actually hold:

  1. Turn off any VPN, ad-blocker or DNS-changer app.
  2. Open Settings > Network & internet > Private DNS (Samsung: Settings > Connections > More connection settings > Private DNS; on any phone, searching Settings for "Private DNS" works too).
  3. Choose Private DNS provider hostname.
  4. Enter the hostname exactly as published on your provider's own site. Google's public resolver uses dns.google; Cloudflare's uses one.one.one.one. Do not type an IP address, a web address starting with https://, or a hostname copied from a comment.
  5. Tap Save and wait a few seconds. If Android reports that it cannot connect, stop — the hostname is wrong or the network blocks it.
  6. Test a few websites and one app. If they load, the setting is working.
  7. Restart the phone, then check the setting once more. If it held, you are done. If it reverted, your phone's software is resetting it — re-enter it and expect to check again after future updates.

Choosing a provider responsibly

Your DNS provider sees every domain you look up, so the choice matters more than the setting itself. Before entering any hostname, read the provider's privacy policy: what it logs, how long it keeps logs, and who owns it. Prefer large, well-documented public resolvers — Google and Cloudflare publish their hostnames and policies openly — over a hostname you found in a forum.

How to test whether it is staying on

  • With Private DNS on your chosen hostname, open three websites you use regularly and one app that needs the internet. Note whether they load.
  • Open a DNS leak test page in your browser and note which provider it reports. It should name your chosen provider, not your internet provider.
  • Switch to mobile data and repeat the test. Private DNS should apply there too.
  • Restart the phone, then repeat the leak test once more. If the provider name changed back to your internet provider, the setting did not survive the restart.

Troubleshooting

  • Websites stop loading after you enter a hostname: the hostname is wrong or the network blocks encrypted DNS. Return to Automatic first, then re-check the spelling on the provider's official site.
  • It works on mobile data but not on Wi-Fi: the Wi-Fi network probably blocks encrypted DNS (port 853). Try another network; if it works there, the first network is the cause.
  • It works on Wi-Fi but not on mobile data: some carriers block or intercept encrypted DNS. Contact your carrier to ask, or keep Automatic while on mobile data.
  • A hotel or airport login page will not load: switch Private DNS to Off, sign in to the network, then switch it back on.
  • The option is missing entirely: your phone may run an Android version older than 9, or the manufacturer hid the menu. Search Settings for "Private DNS"; if it is still absent, a system update may add it, and a VPN-based DNS app is the only workaround.
  • It keeps reverting on a Xiaomi phone: re-enter the hostname under Settings > Connection & sharing > Private DNS and confirm it responds before locking the screen. Some MIUI builds revert it after a network change or reboot.

Does turning Private DNS off make my phone unsafe?

Not directly. Turning it off only affects DNS lookups — the part where your phone asks for a website's address. Your connections to actual websites are still encrypted by HTTPS, so the content of what you read and send stays protected. What you lose is privacy at the lookup stage: without Private DNS, your internet provider or the Wi-Fi operator can see which domains you look up. That is a real privacy loss, but it is not the same as your phone being open to attack. Google's advice is to keep Private DNS on; Automatic is the safer default when a hostname causes trouble, and Off should be temporary — for a login page or a diagnosis — rather than permanent.

Private DNS compared with a VPN

Private DNS and a VPN solve different problems. Private DNS encrypts only the DNS lookup; a VPN encrypts all of your traffic and hides your IP address from the sites you visit. A VPN is the stronger tool, but it costs battery, can slow your connection, and usually needs a subscription or an app you trust. Private DNS is free, built in, and light — but it only covers lookups. If you already use a VPN you trust, its own DNS usually takes over, and that is fine; you do not need both at once.

Frequently asked questions

Why does my Private DNS keep turning off on Android?

Usually one of these: it was on Automatic and never engaged on your network; a VPN or DNS app took over; your phone's software reset it after a restart or update; a work policy controls it; or you switched it off for a Wi-Fi login page and forgot to switch it back on.

Why does Private DNS keep resetting to Automatic?

Some phone software — reported on certain Xiaomi phones running MIUI or HyperOS — reverts the setting to Automatic after a reboot or a network change. A system update can do the same. Re-enter the hostname after restarts and updates, or accept Automatic as the setting that survives them.

Does a VPN turn off Private DNS?

A VPN does not change the setting, but while it is connected it usually takes over DNS lookups with its own resolver, so your Private DNS hostname stops having any effect. That is expected. Turn the VPN off and Private DNS should work normally again.

Is it safe to leave Private DNS on Automatic?

Yes — Google recommends keeping Private DNS on, and Automatic is its safe default. Automatic encrypts your lookups whenever the network supports it and falls back to plain DNS when it does not.

Can someone else turn off my Private DNS?

Yes. Anyone holding the phone can change the setting in a few taps; there is no lock on it.

Should I use a provider hostname or Automatic?

Use a provider hostname if you want encryption on every network and you trust the provider — check its privacy policy first. Use Automatic if you want the safe default that never breaks your connection.

Final takeaway

Private DNS rarely turns itself off for no reason. Most of the time it was never really on — Automatic quietly fell back on an unsupported network — or something else took over: a VPN, the phone's own software after a restart, a work policy, or a forgotten switch-off at a hotel login page. Find which one it is with the two-minute checks, fix that cause, and check the setting once after every restart and system update. And when a hostname breaks your connection, Automatic is always there as the safe way back.


Originally published on Dubydex Blog: https://dubydex-blog.wasmer.app/private-dns-keeps-turning-off-android/

Top comments (0)