Captive Portal Check
Since mid 2019 I provide a free Captive Portal Check: https://connectivitycheck.sp-codes.de/generate204 You are welcome to use it.
Setup in Android
To change the Captive Portal Check in Android, you need a terminal app or a connection via ADB to a computer.
http you can run the following commands with the respective method:
# settings put global captive_portal_use_https 0 # settings put global captive_portal_http_url "http://connectivitycheck.sp-codes.de/generate204"
https you can use the following two commands:
# settings put global captive_portal_use_https 1 # settings put global captive_portal_https_url "https://connectivitycheck.sp-codes.de/generate204"
Maybe you have to reboot your phone after updating the settings.
If you are using AFWall+ you need to give access to  Android-System and in some cases  CaptivePortalLogin to make it work.
Setup in Ubuntu
In Ubuntu, the file
/etc/NetworkManager/NetworkManager.conf must be changed. Add or change the following lines:
Restart the network-manager:
sudo service network-manager restart
Setup in Firefox
Type about:config in the Firefox address bar and search for
network.connectivity-service. Set the URL values to
https://connectivitycheck.sp-codes.de/generate204, the domain values to
connectivitycheck.sp-codes.de. That's it.