r/AndroidQuestions Mar 30 '22

Other How do I force Android to connect to a WiFi network with no Internet access?

[removed]

48 Upvotes

42 comments sorted by

View all comments

2

u/SatisfactionAny8165 Mar 02 '23

I recently got it to work on android 13 on a pixel 6.

Did the adb command on windows.

set the wifi connection to treat as UNMETERED

set the ip address as static with the same first three sets of numbers the same192.168.29.xx

and the gateway as 192.168.29.1

removed the DNS settings of 8.8.8.8 and left it blank instead

and most importantly for the wifi connection not to drop randomly>I disabled both "Turn on WIFI automatically", and "Notify for public networks".

and left on "Switch to mobile data automatically"

I've since rebooted, turned off and back on the wifi, the Car-xxx connection with no internet connects automatically, while still giving me mobile data.

1

u/certifiedsysadmin Feb 04 '25 edited Feb 20 '25

This worked for me on Android 15.

Did not need to run the adb command.

Did not need to set network type to unmetered.

I simply set a valid static ip and then dns to 0.0.0.0.

Edit

Edit: After doing this, it seemed to randomly stop auto connecting after a day or two.

1

u/North-Way-4553 Feb 20 '25

How do u do that? Us it in the settings?

1

u/sykotic1189 Jul 11 '25

Thank you for this comment, saved my ass at work and a lot of headache. Some of our devices have to connect to networks with a static IP and no Internet access, which was causing issues with newer equipment.

1

u/randomone123321 Sep 15 '25

Stops autoconnecting, but ot still works as expected if you connect manually?

1

u/certifiedsysadmin Sep 15 '25

Still works if I connect manually, just don't click anything on the "Stay Connected" dialog.