This guide is for Android users dealing with v2rayNG battery drain while idle, frequent background disconnects, or a warm device. The goal is not to disable background controls immediately, but to separate core runtime, app traffic, weak-network reconnects, and reporting differences before adjusting battery limits, foreground service settings, per-app proxying, and logs.
First determine whether v2rayNG or proxied apps are using the battery
The battery usage shown by Android does not necessarily represent all the power consumed by the app itself. When v2rayNG runs in VPN mode, it creates a local virtual network interface through which other apps send their traffic. Some systems attribute part of that network activity, VPN service runtime, or mobile-network wakeups to v2rayNG. A high position in the battery ranking is therefore a clue, not proof that the proxy core is malfunctioning.
Start with one complete observation period. Charge the battery above 80%, note the start time, and use the device normally for 4 to 6 hours. Check foreground time, background time, and battery percentage under Settings → Battery → Battery usage. Also note screen-on time, mobile signal strength, hotspot use, and whether long audio playback is active. If v2rayNG runs in the background for 5 hours and uses about 2% to 4% without sustained heat, that is usually normal overhead from maintaining an encrypted connection and forwarding traffic. A drop of more than 8% during 2 hours of standby warrants further investigation.
Any part of this chain can increase wakeups. Short videos, cloud synchronization, messaging, and system backups generate ongoing traffic; large routing tables add some matching overhead; packet loss triggers retransmissions; and weak mobile signals make the radio use more power. By contrast, the persistent foreground-service notification mainly tells Android that the service is still running. The notification itself is not usually the main source of battery drain.
Judge the battery percentage alongside how the device is being used. Persistent warmth while the screen is off, the device is idle, and the network is stable points more toward reconnect loops, excessive log writes, or an app making heavy background requests. Higher drain only during video playback, downloads, or large synchronizations is usually the normal result of transferring more data.
| Observed result | More likely cause | Next step |
|---|---|---|
| Stable on standby, drops quickly while using video apps | Traffic and screen use are consuming power together | Check per-app proxying and video quality |
| Stays warm after the screen is locked despite little traffic | Weak-network reconnects, excessive logging, or an unstable node | Switch to a stable node and review the logs |
| Other apps also use noticeably less power when v2rayNG is stopped | Background apps remain active through the proxy | Narrow the list of proxied apps |
| The battery percentage is high, but total battery loss is only 1% | The measurement base is too small | Compare again after at least 4 hours |
Bottom line: compare total battery change over the same period first
Do not rely only on the percentage ranking in the battery list. Keep brightness, network conditions, and usage time similar, then compare two 4-hour periods with v2rayNG enabled and disabled. The difference is more useful than a one-time ranking.
Battery optimization exemptions keep the service alive; they do not directly save power
Android battery optimization restricts background tasks and network access after the device has been idle. Adding v2rayNG to an “Unrestricted” or “Not optimized” list can prevent the VPN service from being suspended and repeatedly relaunched, but it also allows the service to run continuously. The purpose of an exemption is connection stability, not lower core activity. If the connection is already stable, granting unrestricted background access will not automatically reduce battery use.
A sensible setup is to allow v2rayNG to run in the background, keep the foreground-service notification visible, and disable automatic freezing or deep sleep for this app—without granting unrestricted background access to every proxied app. Menu names vary across Android versions and manufacturers, but these controls are usually in the app's battery settings.
Open the app details
Long-press the v2rayNG icon, open App info, then select Battery or App battery usage.
Adjust battery restrictions
Set v2rayNG to Unrestricted or Allow background activity. If the only choices are Optimized and Not optimized, select Not optimized.
Keep the foreground notification
Open Notifications → Notification categories and make sure the VPN or foreground-service category can appear. Do not hide connection status by disabling all notifications for the app.
Check auto-start
If the system offers Auto-start management, enable only the necessary auto-start permission for v2rayNG instead of allowing it for every regular app.
Restart the connection for testing
Return to v2rayNG, stop the current connection, wait 10 seconds, and start it again. Then lock the screen and watch for 30 minutes to see whether it disconnects or reconnects repeatedly.
If you mainly browse for short periods rather than keeping a connection all day, stop v2rayNG manually when finished. Stopping it should remove both the VPN icon and the foreground-service notification. Swiping the app away from Recents does not necessarily stop the VPN service: some systems keep the foreground service running, while others terminate it. Behavior is not consistent.
If battery use increases noticeably after selecting Unrestricted, first check whether system restrictions had previously prevented the service from running continuously. The additional power may simply reflect a connection changing from frequently unavailable to continuously usable. For an all-day connection, prioritize stability. For scheduled use, manually stop the connection to avoid unnecessary runtime.
Keep the foreground notification and rule out reconnect loops and excessive logging
In VPN mode, v2rayNG must maintain the Android VPN service, which the system generally requires to run as a foreground service for long-lived tasks. The status-bar notification is its visible marker. Disabling the notification category, using system cleaners to force-hide it, or repeatedly killing background processes can desynchronize the service state from the interface. The UI may show a connection while traffic cannot pass, after which the core starts again and rebuilds the connection.
In the v2rayNG 1.10.x series, open the main-screen menu and go to Settings → Parameter settings to check the log level. For everyday use, warning or none is recommended; debug is for short-term diagnosis, not hours of continuous operation. Debug records more connection events and routing details, increasing file writes and UI refreshes on devices with frequent requests.
Error: context canceled
Cause and fix: The connection task was stopped, the network changed, or the core restarted and canceled the task. Occasional entries can be ignored. If they repeat every few seconds, first disable tools that automatically switch networks, then stop v2rayNG for 10 seconds and reconnect.
Error: failed to find an available destination
Cause and fix: The destination address could not be resolved, or the current route has no usable outbound. Check the node address and DNS settings, switch to a confirmed working node, and restart the core.
Error: io: read/write on closed pipe
Cause and fix: A read or write was attempted after the network changed or the connection closed. A few entries are normal during disconnects. If they keep filling the log, disable debug logging and check whether Wi-Fi and mobile data are switching repeatedly.
Network changes are a common amplifier of background battery drain. Leaving Wi-Fi coverage, switching repeatedly between mobile data and Wi-Fi, or joining a network that requires web authentication can invalidate the current connection. The core must resolve the server address again, establish a TCP or other transport connection, and complete the protocol handshake. One reconnect costs little, but several per minute can prevent the device from entering stable standby.
Use a 15-minute comparison to determine whether network switching is responsible. First use stable Wi-Fi only, disable automatic mobile-data switching, lock the screen, and watch the temperature and logs. Then repeat using mobile data only. If reconnects occur continuously on just one network, the problem is more likely the access network, DNS, or node path than v2rayNG's background permissions.
- If the logs show a connection closing and reopening every few seconds, check network stability first.
- When the server address is a domain name, failed DNS resolution can multiply retry attempts.
- If node latency suddenly rises and packet loss is obvious, switch to a stable node before tuning power settings.
- Speed tests deliberately generate many connections and a lot of traffic, so do not run them repeatedly during battery-drain testing.
- After changing parameters, stop and restart the connection so the old core does not continue using the previous configuration.
Bottom line: a persistent notification does not mean abnormal battery drain
A persistent foreground-service notification means the VPN service is running. What needs attention is a notification that repeatedly disappears and returns, continuously scrolling logs, frequent network changes, or sustained warmth without traffic.
Use per-app proxying to reduce unnecessary background traffic
In VPN mode, v2rayNG may receive network requests from many apps on the device, including weather updates, cloud sync, app-update checks, and system components. Processing each small request costs little, but dozens of apps waking periodically in the background can create a steady stream of scattered traffic. If only a browser, messaging app, or specific work app needs the proxy, per-app proxying is usually a more direct solution than changing protocol parameters.
v2rayNG per-app proxying determines which Android apps enter the VPN tunnel. It is separate from V2Ray routing rules: per-app proxying filters traffic by app at the device entrance, while routing rules choose an outbound based on the domain, IP, or port after traffic reaches the core. Reducing the number of entry apps keeps unrelated traffic out of the core and lowers the chance of proxying local-network tools or high-traffic apps unnecessarily.
Open per-app proxy settings
Open the v2rayNG main menu, go to Settings → Per-app proxy, and enable the feature.
Choose a filtering mode
When only a few apps need the proxy, choose “Proxy selected apps only.” When only a few apps need to be excluded, choose “Bypass selected apps.”
Select only necessary apps
Start with only the browsers, messaging apps, and work apps that genuinely need the proxy. Do not select every system component at once.
Exclude high-traffic tasks
If they do not need the proxy, exclude local video, local-network transfers, system updates, and cloud photo synchronization.
Rebuild the VPN connection
Save the settings, stop the current connection, wait 10 seconds, and start it again so the new app scope is written to the VPN configuration.
After narrowing the proxy scope, test both selected and unselected apps. Selected apps should reach their target services normally; unselected apps should use the current network directly. If an app has multiple processes or depends on system components, selecting only the main app may leave some features offline. Add related components only as needed instead of selecting everything in advance.
Per-app proxying cannot reduce the encryption core's baseline runtime cost, but it can reduce background data and the time the wireless radio stays active. The effect depends on app usage: devices with substantial background syncing will show a clearer difference, while devices with little network activity may change by less than 1% of battery.
| Use case | Recommended mode | What to check |
|---|---|---|
| Only a few apps need the proxy | Proxy selected apps only | Keep system updates and cloud sync out |
| Most apps need the proxy | Bypass selected apps | Exclude local-network and high-traffic apps |
| All-day messaging and light browsing | Keep the allowlist small | Monitor lock-screen messages and standby battery |
| Temporary downloads or speed tests | Enable it only for the task | Stop the connection when finished |
Nodes, protocols, and DNS settings also affect background power use
VMess and VLESS are not, by themselves, enough to determine battery use. On mobile devices, link quality usually matters more than the protocol name. A stable node with 80 ms latency and little packet loss is often more efficient than one with 300 ms latency and frequent timeouts, because the latter causes more retransmissions, handshakes, and DNS queries. Do not use an obviously unstable route long-term just to prefer a particular protocol label.
DNS also affects connection setup. When the server address is a domain name, the core must resolve it during startup; app requests for domains also generate queries according to the current DNS configuration. An unreachable or slow resolver, or a cache invalidated after a network change, can cause queued requests and repeated attempts. If the logs repeatedly show resolution failures, fix DNS or the node address instead of masking the problem by removing battery restrictions.
Whether connection reuse should be enabled depends on the server configuration and real-world network testing. Reuse can reduce some repeated connection setup, but on unstable links, servers with limits, or networks where long-lived connections are often interrupted, it can also affect multiple requests at once. Change one parameter at a time and observe for at least 30 minutes. Changing logging, DNS, reuse, and routing rules together makes it impossible to tell which setting helped.
Keep routing rules clear. Large sets of duplicate domain rules, conflicting IP conditions, or overly broad matches are more likely to create maintenance problems than significant battery drain. Rules are matched in order, so an earlier rule may take effect first. Handle local-network addresses and local services explicitly when they should connect directly, preventing local requests from taking a remote route and timing out.
- Prefer nodes that connect successfully in three consecutive tests with little latency variation.
- Do not run batch speed tests or continuous latency tests during standby battery testing.
- If a node domain fails to resolve, check DNS and the network instead of retrying indefinitely.
- Keep automatic time synchronization enabled; clock drift can cause some connection handshakes to fail.
- After updating a subscription, enable only the nodes you need and remove or disable configurations that have been unavailable for a long time.
A recommended setup for stable connections and longer battery life
For all-day messaging or an always-on work connection, keep the v2rayNG foreground service, set its battery policy to Unrestricted, use warning or none logging, and choose “Proxy selected apps only.” Prioritize stable nodes with low packet loss and do not run continuous speed tests in the background. This keeps the VPN service stable while reducing scattered traffic from unrelated apps.
For use during specific periods, keep normal system battery optimization enabled, start the connection when needed, and stop the service from inside v2rayNG when finished. Do not assume swiping the app away from Recents means it has disconnected; confirm that both the VPN icon and foreground-service notification are gone. For short sessions, stopping the connection manually is more effective than repeatedly tuning background settings.
Establish a baseline
Record 4-hour standby battery loss, v2rayNG background time, network type, and device temperature instead of judging from a single battery ranking.
Keep the background service stable
When an always-on connection is needed, allow background operation and keep the foreground notification visible to prevent repeated relaunches after system freezing.
Narrow the proxy scope
Use per-app proxying, keep only necessary apps selected, and exclude system updates, cloud sync, and local-network transfer tools.
Address recurring errors
Review 10 to 15 minutes of logs and address persistent DNS, connection-closed, and unavailable-destination errors.
Retest one variable at a time
Change only one variable per test and retest for at least 30 minutes; a full battery comparison should run for more than 4 hours.
If the device still loses more than 5% per hour on fixed Wi-Fi with the screen off, no downloads or hotspot use, and no repeated reconnects in the logs, restart the device and compare with a freshly imported configuration known to work. If there is still no improvement, update to the current v2rayNG version listed on the download page. Do not immediately restore every old parameter; first test one node with the smallest possible proxy-app scope to rule out legacy settings.
If the device remains warm after v2rayNG is stopped, or Android shows another app active in the background for a long time, investigate that app, mobile signal strength, and system sync tasks. A proxy client controls only traffic entering its tunnel; it cannot fix high screen brightness, weak cellular signal, continuous location access, or battery aging.
Bottom line: choose between a stable always-on connection and stopping it when needed
For an all-day connection, keep the foreground service and reduce the number of proxied apps. For short sessions, stop it manually from inside v2rayNG. Frequent freezing, relaunching, and reconnecting is usually harder to diagnose and may not save power.