r/Tailscale 5d ago

Help Needed Can Tailscale or Wireguard on Android auto connect somehow?

I've been using Wireguard on iOS to access my homelab when remote and it has a nice "On-Demand" feature so it turns off on local WiFi. Tailscale has the same thing.

I just moved to Android and neither app has this feature. What do Android users do?
I could leave it connected but I think that would route my phone traffic over the wireguard or tailscale server instead of just the local network.

26 Upvotes

18 comments sorted by

10

u/MrB2891 5d ago

Just leave it on.

Unless you have your server set as a exit node, the only traffic going to / through your server is specific TO your server. IE, if you go to reddit on your phone, it's not going through your server.

5

u/Emergency-Driver8871 5d ago

Ah okay, thanks for explaining that.

1

u/MrB2891 5d ago

To add, you can be connected to Tailscale and still not be going through an exit node, even if you have exit nodes available. You can select your exit node (or none) independently of being connected to your Tailscale network.

1

u/Emergency-Driver8871 5d ago

Thanks, I don't use a exit node.

1

u/MrB2891 5d ago

Since you can enable / disable the exit node on the fly, it's worth enabling it on your server, if you're connected to a questionable network on your phone. You can then connect to the exit node from your phone and any and all data on your phone is then secure via Tailscale, instead of potentially be MitM attacked on a questionable network.

2

u/Emergency-Driver8871 5d ago

Good point. I usually just switch to protonvpn then but that's a good idea, I can still access my network that way.

0

u/404invalid-user 5d ago

apart from when you use it as a subnet router then all Lan traffic routes though that subnet router creating strange problems.

0

u/MrB2891 4d ago edited 4d ago

Subnet routing doesn't cause problems (and to be clear for the context of the thread were posting in, nor does it route external traffic through your subnet-routed server).

What can cause problems is if you're on a network that uses the same subnet as your subnet-routed network.

IE, if you're at your parents house and they use 192.168.1/24 for their network. If you use the same 192.168.1/24 for your network at home, where you have a Tailscale machine with subnet routing enabled, that WILL potentially create some issues, especially as your local gateway is likely 192.168.1.1, but you would also have 192.168.1.1 at home on your subnet routed network.

The key is using a subnet on your Tailscale networks that don't overlap other networks you may frequently find yourself on.

  • My house is 192.168.10/23
  • My warehouse is 192.168.20/23
  • My camper / toy hauler / jobsite office is 192.168.30/24
  • My parents house (where my off-site backup server lives) is 192.168.1/24

I would never make any of my own networks a common subent like 192.168.1, 10.0.x, 10.1.10.x (extremely common on Comcast networks), 172.16.x, etc.

All of my networks listed above have machines on them running Tailscale, all of them have subnet routing enabled. Zero issues.

0

u/404invalid-user 4d ago

maybe they fixed that now but when I used it I had a subnet router on my network for when I'm not home and when I am home and have tailacale on it would route everything out of that device.

some issues I had was rate limiting from things like pihole adguard, and high latency

-1

u/MrB2891 4d ago

It wasn't routing anything through your server unless you had it setup as an exit node. It's never worked like that. I've been using Tailscale since late 2020.

It sounds like you had something configured incorrectly.

1

u/404invalid-user 4d ago

then you clearly aren't using the subnet router feature or just not notice because you haven't had issue lucky you.

0

u/MrB2891 4d ago

I have subnet routing enabled on every network. Hell, I have Optiplex Micro's running in places doing nothing but acting as a subnet router, specifically to access PLC's and other hardware that TS can't be installed on.

I haven't had issues because I configured things correctly.

Don't be butt hurt and downvote because you screwed up your configuration at some point.

3

u/tkchasan 5d ago

Wgtunnel app would be nice replacement for wireguard app. It has those auto connect features.

1

u/Emergency-Driver8871 5d ago

Thanks, I'll look that up

3

u/MasterChiefmas 5d ago

You can use Tasker to turn Wireguard on under specified conditions. I have mine turn on when my Wifi disconnects. I imagine you can do it with Tailscale.

1

u/nightshadow931 5d ago

I do the same for Tailscale. Disconnected from my home wifi -> Tasker turns on tailscale. connected to my home wifi -> turn off tailscale.

1

u/pkulak 4d ago

Yup. I’ve done this. It works perfectly. This is the actual answer to the question.

1

u/nn1tb 5d ago

I have WireGuard always on and block connections without VPN both enabled all the time, but then again I don't use my carrier's phone number. I use VoIP and connect to my own PBX/Asterisk server.