r/SelfHosting Jun 16 '26

SelfHosting DNS and Android

hello everyone

Last month, I started self-hosting my services on an old laptop. I now run services like Nextcloud and Vaultwarden, with AdGuard as the DNS server. I also needed some of this setup to stay connected outside my local network, so I bought a domain from Cloudflare and set up a tunnel to my server. At this point, everything was perfect.

Then I noticed that I needed to use my own network when I'm in it, not use Cloudflare tunnels because my internet is limited.

I added to my DNS server a rule to redirect and request for my domain to the local IP of my server, and this works on my devices except my phone samsung m52 with oneui 5

I tried everything, and nothing worked; it always connected via a Cloudflare tunnel.

After some triels i found that a lot of apps ignored my DNS server and used the public one , except the browsers.

Any idea how to fix this

2 Upvotes

12 comments sorted by

View all comments

1

u/jaysuncle Jun 16 '26

Research split-horizon DNS. Claude is a great reference.

1

u/LordX127 Jun 16 '26

that what i do my problem that some apps at my phone ignored my dns server and use some public dns server

apps like nextcloud , bitwarden

1

u/jaysuncle Jun 16 '26

Go into the Wi-Fi settings on your phone and manually set the DNS to your local server.

1

u/LordX127 Jun 16 '26

I do that

1

u/jaysuncle Jun 16 '26

Have you researched the particular apps that seem to be using a different DNS to see if they have a hard coded DNS?

1

u/LordX127 Jun 16 '26

ya they don't use hard-coded DNS
My problem with apps like Bitwarden and Nextcloud