Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By John Mark
#87510 Hello everyone.

I'm having problems with the captive portal.

When I have the captive portal open and call the wifi.begin () function, sometimes the captive portal closes on its own.

how to keep the captive portal always open after wifi.begin ()
User avatar
#87715 Hi John,

The 'captive portal' is nothing you 'open' and 'close'. It simply tries to resolve all entered names (like '') to the IP address of your device, so that whatever you type in, the request 'lands' on your chip. If that stops working (assuming your code is still running like it did before) the problem is not the ESP itself.

If your ESP is the access point 'WiFi.softAP(...);' and you connect to that AP (e.g. with your mobile phone) and the captive portal will stop working, the problem is the mobile phone (I never have experienced that).
If your ESP is just a client that connects to another AP (like your router) using 'WiFi.begin(...);' your ESP needs to register itself as an DNS to your router, so that the router will ask your ESP, what IP this or that URL has. On many routers or WiFi access points that won't work at all and on many other it won't run stable (especially if you have to restart your ESP multiple times while developing your code).