14

I'm associating a Nexus 5x running MarshMallow 6.0 to a Wi-Fi hotspot that has no Internet access. Android keeps dropping the connection every second and then won't even try to reconnect stating that there is no Internet access.

How can I force Android to keep this Wi-Fi connection even without Internet access?

1
  • 2
    On my Nexus 5X, when I connect to hotspot with no internet access, after a few seconds I get a notification asking if I want to stay connected to it. When I answer Yes, it stays connected. If I anser no, hotspot gets disconnected. Commented Dec 11, 2015 at 12:10

3 Answers 3

10

This shell command works on marshmallow: type su to enter superuser mode. Then type the following command: settings put global captive_portal_detection_enabled 0

^^ it disables the "drop wifi if no internet connection" functionality.

5
  • This is actually a very good answer. My problem was a mistake of gateway but I'm getting the message. To disable the message, this setting is efficient. It only needs root access to be persistent across reboot. Commented Jun 15, 2016 at 19:51
  • This is perfect! Couldn't connect to my quad's wifi network consistently because Android kept handing it off despite checking the "ignore" box.
    – Allison
    Commented Jan 28, 2017 at 21:25
  • 2
    This doesn't appear to work on Nougat.
    – seagull
    Commented Feb 23, 2017 at 11:29
  • Please note: I had to manually delete the network configs and add them manually, to get the issue fixed with the command (Samsung Galaxy Tab A T585). My Galaxy S8 Android N (25) provides a solid connection out of the box. Commented May 28, 2017 at 14:46
  • @MartinPfeffer did you find a way to add it programmatically to the network config (as in developer.android.com/training/articles/security-config) ?
    – Gabor
    Commented Apr 27, 2018 at 20:28
0

My gateway was not correct. False problem. It's true that Android offers a message as stated in the question comment by Juozas.

-1

To disable automatically disconnecting from a "poor" WiFi network, you will want to toggle the Avoid poor Wi-Fi connections setting.

This can usually be found in Settings > Wi-Fi > [menu] > Advanced > Avoid poor Wi-Fi connections.

1
  • 1
    "bad Wi-Fi" is certainly not a Google wording... Here support.google.com/nexus/answer/2819519#advanced, they mention "Avoid poor connections". I don't have that option on Nexus7 2013 5.1, nor on Nexus 5x 6.0. And I don't think that it would even answer my question. No Internet access is different from poor connection. Commented Dec 10, 2015 at 4:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .