For anyone troubleshooting battery drain while an iPhone or iPad is locked. First, distinguish the app’s share of battery usage from the device’s total battery drop in Battery. Then check automatic connection settings under Shadowrocket’s Settings → On Demand. Finally, compare consistent test periods on the same device to decide whether to adjust the triggers, connect manually, or investigate repeated reconnects.
Battery usage: percentage, battery drop, and activity
On your iPhone or iPad, open Settings → Battery, select the period with unusual battery drain, and review app battery usage for that period. The percentage next to Shadowrocket is the system’s estimate of its share of power used during the selected period—not the percentage points deducted from the battery charge. If other apps use little power while the screen is locked, Shadowrocket may rank near the top even when the total battery drop is small.
For example, a drop from 82% to 79% is a 3-percentage-point decrease for the whole device. If Shadowrocket accounts for 30% of usage during that period, that does not mean it used 30 percentage points. These figures are an illustration, not measured results. Don’t judge settings from a single short period or a small percentage estimate: battery figures are rounded, and background syncing and network changes can also affect the result.
First check whether the device’s battery drain happens repeatedly
If Shadowrocket is simply near the top of the app list, keep your settings and record another period under similar conditions. Investigate background activity and reconnects only if a higher usage share coincides with a larger total battery drop across multiple periods.
On Demand vs. staying connected: choose based on how you use it
On Demand controls when the system automatically establishes a VPN connection based on configured conditions. Once connected, the VPN may remain active after the screen locks; connecting on demand does not mean disconnecting when idle. Here, staying connected means manually turning on the connection from Home and keeping it active during the observation period. This is not Always On VPN in device management.
| Usage pattern | How to set it up | What to check |
|---|---|---|
| Occasional use; disconnect when finished | Turn off automatic triggers under Settings → On Demand. When you’re done, go to Home and turn off the connection. | Check that the connection stays off while the screen is locked. You’ll need to turn it on manually next time. |
| Connect automatically on specific networks | Enable On Demand under Settings → On Demand and check that the relevant triggers are available and enabled. | Check whether the connection starts as expected after switching networks, and whether it also triggers on networks where you don’t need it. |
| Use continuously for a period | Turn on the connection manually from Home and leave it on. If managing it manually, turn off On Demand to prevent an automatic reconnect after disconnecting. | Check that the connection remains stable on a reliable network, and remember to turn it off when you’re done. |
After changing a setting, test it in a situation that previously triggered the issue. For example, first check the connection status on Home over a familiar Wi-Fi network, then test what happens after leaving Wi-Fi if you need to verify network switching. Don’t change Global Routing, rule files, and the server you use at the same time; otherwise, you won’t know which change caused the result.
Battery drain while locked: compare two sets of notes to distinguish idle use from reconnects
Run two test periods on the same device. Start with 60 minutes per period, ideally at the same location and around the same time of day. Use the same Wi-Fi network and keep charging status, Low Power Mode, and routine background tasks consistent; ideally, don’t charge during either test. Before each test, note the battery level and Home connection status. Afterwards, review activity in Battery for the matching period.
- Record a disconnected baseline. Turn off On Demand, disconnect from Home, and lock the screen. Do this only when you don’t need a VPN connection. Note the starting and ending battery levels, test duration, and any downloads, photo syncing, or other tasks during the period.
- Record a manually maintained connection. Keep On Demand off and use the same server and existing configuration. Turn on the connection from Home, then lock the screen. If the difference appears only once or amounts to just one percentage point, repeat the test before changing any settings.
- Test automatic triggers separately. Keep the same server and configuration, enable On Demand, and reproduce a network switch along your usual route. Note when the switch occurs, whether an error appears, and whether the connection recovers. If both tests on familiar Wi-Fi are similar but the issue mainly occurs during a commute or frequent network changes, check the trigger conditions and network reachability first. Don’t use results from a fixed network to draw conclusions about mobile use.
Discard a test pair if the background tasks differed significantly between the two locked-screen periods, or if one test stayed on Wi-Fi while the other switched to cellular. Battery provides clues about energy use and activity, but app percentages alone can’t reconstruct every disconnection. Reproducible changes in connection status are more useful for troubleshooting than a one-off battery ranking.
Automatic reconnects and connection failures: isolate the trigger first
If the VPN reappears soon after you disconnect from Home, first check whether On Demand is still enabled. Manually disconnecting ends the current connection, but may not remove the system’s automatic connection conditions. If it still connects automatically with On Demand off, check whether the active configuration in system VPN settings is the one associated with Shadowrocket. Don’t delete configurations you don’t recognize; if the device is managed, check with your administrator first.
Error: The VPN server did not respond.
What it means: This system message indicates that the connection did not receive the expected response. By itself, it doesn’t tell you whether the current network is unreachable, the configuration is incorrect, or the server is having a problem.
What to do: Temporarily turn off On Demand and retry manually from Home on a stable network. If it still fails, check the server address and port for your existing service and ask your provider to confirm that it’s available. Then restore automatic triggers if needed.
If the same configuration fails only after switching networks, note the network types before and after the switch and when the failure occurred. A connection test on a stable network can help distinguish “couldn’t connect in the first place” from “didn’t reconnect after switching networks,” and prevent background activity from repeated failures being mistaken for normal idle battery use.
Why battery use varies: a connection isn’t the same as active traffic
Returning to the Home screen or locking the screen only means Shadowrocket is no longer in the foreground. The VPN tunnel can still carry traffic that the system routes through it. The diagram below shows a request that has entered the tunnel. Whether it’s proxied depends on the current routing mode and configuration, not on On Demand.
When Config is selected under Global Routing, traffic is handled according to the rules in your configuration. A DIRECT match means only that the request connects directly; it doesn’t mean the tunnel is off or that background battery use is zero. Handling traffic, maintaining sessions, and reconnecting after network changes can all involve network or processor activity. On Demand controls automatic connection conditions; it doesn’t control when other apps sync. That’s why the same settings can produce different battery records on a fixed desktop network and during a commute with changing networks.
- For brief sessions when you want to stay disconnected after locking the screen: turn off On Demand, then disconnect manually from Home when finished and confirm the connection status.
- For automatic connections based on network conditions: keep the triggers you need, and first check whether the connection recovers properly after switching networks.
- For continuous connections: keep your current routing settings, rule out reconnects and background transfers first, then use repeated test results to decide whether to shorten the time you stay connected.