Automating WiFi login

Thd WiFi hotspot where I work always asks for a password, and the IT Dept forces us to use long passwords. We cannot save the password, unfortunately, so I’ve stopped using WiFi and use cellular during the workday. Is it possible to write a iOS shortcut or script to
turn on WiFi, select a specific hotspot, and enter my login credentials? Please post some examples.


That isn’t possible currently on IOS.

1 Like

Thanks, it’s too bad they’re are such limitations

Well, I think there’s actually a good challenge there for the approach being taken by your employer.

I’m not exactly sure how they might enforce some sort of policy on your device whereby you cannot store a WiFi password. I’ve come across capture portals which you get daily access codes for, but those kick in only after you have a WiFi connection and require gateway access - almost always to go out to the Internet. I’ve certainly never seen it implemented at any of the client sites I’ve worked at over the years, and I haven’t been able to turn up anything in a quick bit of Googling.

As a result I’m not sure I’d go so far as to say it is an iOS “limitation” as much as it might be a “lack of support for an edge case”.

I don’t know if it helps you, but iOS has a built in connection feature when scanning QR codes for sharing your WiFi.

And of course there is a shortcut to generate this QR code, so you can print it out and scan it, when you arrive at work. It only connects to the network. Additional input can’t be passed… And remember to keep the QR code save, like a password!

1 Like

Does this mean I don’t need to enter my password each time I connect to WiFi ? Is the password stored in the qr code?

If so, this might be the solution I’m looking for

I don’t know why we can’t save the wifi password. I only know ww have to enter if each time we want to use WiFi

Yes, the password is stored in the QR code. Just run the shortcut the next time you are connected and it should ask you for the password. But I haven’t tried that myself yet.

1 Like

the link doesn’t seem to work

Works for me and I don’t know why it shouldn’t work… :man_shrugging:

If the iCloud link in the reddit post opens in the discourse app, it probably won’t work. You need to open it in either Safari app or a Safari in-app web view (no custom web view). Also the default browser in the reddit app doesn’t work.

It definitely sounds like you’re talking about a WiFi network where anybody is allowed to connect (i.e. it’s not WEP or WPA protected at all), and then some kind of captive portal (that on iOS slides up in a safari web view after you’ve connected) requires your specific user account / password before you’re actually allowed access to anything. The QR code method can’t bypass that - I don’t think anything automated can.

Not exactly. We don’t log in with a web browser, it’s juts the WiFi password for the access point

Ok, pasting the reddit link into chrome enabled me to download it.

Oh right, that policy of not letting you save it is very odd then. I would expect them to have some way of remotely wiping the device if it got lost…

I’m one step closer now. I’ve turned on cellular for shortcuts and I’m absolutely signed into iCloud. When I tried running the shortcut, this is displayed…image

Here’s a barebones version to create a QR code.

1 Like

Maybe you’ve thought of this, but couldn’t you store your password as a text expansion snippet and then use that to input the full password?

1 Like

That may work until I can get The QR thing going

I’m not sure iOS will expand text snippets inside password fields?

I don’t know and haven’t tried in a password field. But it woks elsewhere, so I thought it worth mentioning. I guess 1password is doing it differently.

1 Like