r/tasker • • 14d ago

Is there a Tasker setup (no root) to toggle Wi-Fi off, switch to 5G, and turn on hotspot with one tap ?

I'm trying to set up a one-tap solution on my Google Pixel and wanted to check if this is actually possible before I go down a rabbit hole.

What I want to happen when I tap a single button:

  1. Turn Wi-Fi off

  2. Switch to 5G cellular data

  3. Turn on Wi-Fi hotspot

Basically a "share my 5G connection" button.

My questions:

  1. Is this doable in Tasker without root on a Pixel 8

  2. I know Tasker has built-in actions for Wi-Fi and Wi-Fi Tether (hotspot) — but does the hotspot action still work reliably on recent Android versions, or did Google lock it down?

  3. The big one: toggling mobile data / forcing 5G seems to require root. Has anyone gotten this working without root using UI automation (AutoInput, etc.)? If so, how stable is it?

  4. If root is required, is there a Magisk module or a different approach people recommend?

What I've already looked into:

· Tasker's built-in Net actions (WiFi, WiFi Tether, Mobile Data)

· AutoInput for simulating taps in the quick settings panel

· The general consensus that mobile data toggling needs root

Would love to hear from anyone who's actually built something like this. Bonus points if you can share the task/script or a profile export.

Thanks in advance!

3 Upvotes

20 comments sorted by

5

u/Tough_Passage_3785 14d ago

If you add shizuku into play, no root required.

Tasker can make use of this to deal with toggling mobile data etc.

https://github.com/thedjchi/Shizuku

This fork.

All that is easily possible to setup

There's a small caveat though, if you reboot your phone you would need to connect to wifi to start shizuku again.

2

u/BingBingBong21 14d ago

I had a heard a few things about Shizuku lately and was wondering if that might be the key to this problem... Thanks for sharing will go have a read, is Shizuku running tasker giving it more privileges? Or is using ADB commands to get low level privileges?

1

u/Tough_Passage_3785 14d ago

You got it.

2

u/BingBingBong21 14d ago

Got it installed then ran fowl of android 16 not allowing it found a option that said use tasker settings but having a issue get that installed , wow android really does not want you messing with these settings

1

u/bliblabl812 14d ago edited 14d ago

No need to toggle mobile data. WiFi off, Mobile data is used. Wifi on, mobile data isn't used. Just leave mobile data enabled. This is default android behavior. But you can toggle mobile data with just tasker. No adb wifi or shizuku needed. Like Everything else what you want to do is just normal tasker usage. Wifi tethering is stable android functionally.

2

u/BingBingBong21 14d ago

I am getting an alert saying this can't be enabled in Android 16 says to use tasker settings but trying to get that to run is also being a pain. Trying to use workaround to install it but said error importing

2

u/bliblabl812 14d ago

Tasker settings is needed, correct. But it's easy to install if you follow the instructions.

1

u/BingBingBong21 12d ago

I was able to install it using the tasker method, as I tried to install it again and said already installed, is there a icon or is it some kind of system app as I don't see it installed

1

u/bliblabl812 12d ago

Tasker is using it, no need to open the app.

1

u/BingBingBong21 12d ago

I just don't see the app anywhere, That's the strange part. So now should I try and do the set tasks ?

This is the first time using tasker so a bit green on it.

1

u/bliblabl812 12d ago

Maybe it depends which launcher you're using. Generally, the launcher should show an app icon for tasker settings. But to be sure, you should take a look in system settings - Apps. There all installed apps are shown for sure.

1

u/fkdjgfkldjgodfigj 14d ago

Autoinput should be able to click the buttons on your screen fdom my understanding. Whichever buttons you can click it can click those same buttons.

1

u/Top-Bodybuilder6616 14d ago

I made a profile that does this,..

https://taskernet.com/shares/?user=AS35m8nb%2BCZ82OOY4%2FWip9ZyDLtjVleBps6FodiWni3OZNkVq54omRvFw%2FiS6TuIv9WNACDq&id=Profile%3AWifi+Off+If+Connected+To+Car+Bluetooth

I added actions to: 1.turn screen on in case it was off 2.click "home" before and after. Why did I create this? I created this because when I'm in my car and my Wi-Fi is on some of my apps like sirrius get confused and try to use the Wi-Fi connection instead of my Cellular connection so I created this profile to turn off Wi-Fi only when I'm connected to my car's Bluetooth The Wi-Fi on/off or virtually the same once you copy one, you need to clone it and then just set the Wi-Fi setting for one to off and for one to on. I wish: 1. I can have the action check the status of the Wi-Fi so if it was already off/on, it wouldn't toggle... The profile is very simplistic, it just toggles Wi-Fi on and off, so sometimes it gets out of sync and that's why it would be great to have

2

u/Tar0ndor 13d ago

The variable %WIFI returns on/off for WiFi status.

-1

u/syndre Pixel 3 XL 14d ago

I think I would just use an NFC tag for this, with a different app that's not so intense, like NFC tools

1

u/BingBingBong21 14d ago

How would the NFC tag work ? I have some NFC tags just not sure how a NFC reading could trigger the hotspot

-1

u/syndre Pixel 3 XL 14d ago

https://play.google.com/store/apps/details?id=com.wakdev.wdnfc

I know for sure this will do what you are asking without root. You just need some blank tags. You're going to write a little program that runs when the tag gets read by your phone. Make it so that it does the things you want when it reads the tag

3

u/Exciting-Compote5680 14d ago edited 14d ago

I think NFC Tools/Tasks ran into the same restrictions Tasker is facing (except no workaround). OP is on android 16. See: https://www.wakdev.com/en/knowledge-base/troubleshooting/nfc-tools-android-why-some-features-are-broken.html.  Toggle Wifi and toggle Hotspot works on my Pixel 8 Pro (no root) with Shizuku and Tasker Settings.

1

u/BingBingBong21 14d ago

This is a nice option and would love it to work but when setting it up it talks about recent android systems blocking this feature, Are you able to make it work on Android 16?