Battery and background capture
HTTPGlass runs capture as a foreground service with a persistent notification, which is the correct, Android-sanctioned way to keep a VPN service alive while you use other apps. Stock Android (including Pixel) generally leaves it alone. Some manufacturers’ battery management is more aggressive than stock Android and can still kill a background VPN service to save power — Samsung, Xiaomi (and Redmi, POCO), Huawei (and Honor), OnePlus (and Oppo, Realme), and Vivo (and iQOO) each have their own extra toggle on top of the standard Android one.
Symptoms
Section titled “Symptoms”Capture stops on its own after the screen is off for a while, or after switching away from HTTPGlass for an extended period, with no error shown.
What to do
Section titled “What to do”- Exempt HTTPGlass from battery optimisation. In HTTPGlass, open the Battery guide, which detects your phone’s manufacturer and shows the right steps. On stock Android and Pixel this is Settings › Apps › HTTPGlass › App battery usage › Unrestricted. Manufacturer skins add their own extra toggle on top of that: Autostart on Xiaomi, App launch on Huawei, Autostart again on Oppo/Realme/OnePlus, or Background power consumption management and Autostart on Vivo. The Battery guide in the app spells out the exact menu names for your phone, since they drift a little between OS versions.
- Turn on Always-on VPN, if you want capture to persist more aggressively: Android Settings › Network & internet › VPN › HTTPGlass, then the Always-on VPN toggle next to it.
What HTTPGlass can and can’t do about this
Section titled “What HTTPGlass can and can’t do about this”HTTPGlass asks for the battery exemption and uses a foreground service so Android itself treats it as a visible, user-initiated task rather than background noise. It can’t override a manufacturer’s own background-kill logic beyond that; the battery exemption is the fix.
