Even when you haven’t installed a new app, many users notice that their phone’s charge disappears faster than expected. The most common culprits are:
Android provides a set of built‑in tools that let you see exactly which component is drawing power. Coupled with adb (Android Debug Bridge), you can obtain detailed logs that go beyond the simple battery‑usage chart.
adb executable should be in your PATH.The quickest way to spot a power‑hungry app is the built‑in Battery usage screen.
If the battery‑usage chart points to an app you recognise, you can often resolve the issue by restricting its background activity (Settings > Apps > [App] > Battery > Background restriction). However, to verify that the restriction actually reduces wake‑ups, we move to the ADB diagnostics.
Android records low‑level power events in a binary file called batterystats. The dumpsys battery command gives a quick snapshot, while dumpsys batterystats provides a full log.
adb tcpip 5555 then adb connect <IP>).adb shell dumpsys battery
This prints the current battery state (level, temperature, voltage, etc.). Record the level value for later comparison.
adb shell dumpsys batterystats --reset
This clears the previous log so you can capture a fresh period of activity.
adb pull /data/system/batterystats.bin ./batterystats.bin
(You may need adb root on some devices; most consumer phones allow read‑only access without root.)
adb shell dumpsys batterystats --history
This prints a chronological list of wake‑locks, network activity, and CPU usage.
The output is dense. Look for lines that start with W (wakelock) or R (running) followed by a package name. Example:
W 0:00:12 com.facebook.katana:wakelock 1500ms
Repeated entries for the same package indicate a likely drain source.
Android 6.0+ introduced a Power Manager API that apps should use responsibly. A misbehaving app may hold a wakelock indefinitely.
adb shell dumpsys batterystats --charged | grep "Wakelock" | sort -k2 -nr | head -n 10
grep not available on the device), you can filter locally:
adb shell dumpsys batterystats | grep -i wakelock
Common legitimate wakelocks include com.google.android.gms (Google Play services) and android (system). If a third‑party app appears, you have a candidate for further action.
Depending on the culprit, you have several safe options:
adb shell am force-stop com.example.app.
android.hardware.location) is the offender, try toggling the related hardware (Location, Bluetooth, NFC) off when not needed.After applying a change, repeat the short monitoring cycle to confirm improvement.
adb shell dumpsys batterystats --reset.adb shell dumpsys batterystats --history and compare the number of wakelock entries for the previously offending package.If the numbers remain unchanged, consider the following troubleshooting steps.
/data/system/batterystats.binSome OEMs lock down the /data partition. In that case, you can still retrieve the human‑readable history without root:
adb shell dumpsys batterystats --history > batterystats.txt
Parse the text file locally with a simple grep or import it into a spreadsheet.
This usually means the system is busy with background processes like indexing, updates, or a stuck MediaScanner. A simple reboot often clears the temporary load. If it recurs, consider clearing the cache partition (Power off → hold Volume Up + Power on on most devices).
If you have exhausted the steps above and still see rapid discharge, the issue may be hardware‑related (aging battery, faulty charging port) or a low‑level firmware bug. At that point, you can:
adb shell cat /sys/class/power_supply/battery/capacity to read the raw capacity value.adb shell dumpsys battery – look for health field (e.g., GOOD, OVERHEAT).BAD or OVERHEAT.By combining the visual battery‑usage UI with the granular ADB diagnostics, you gain a clear picture of what’s draining your phone and can take precise actions without resorting to trial‑and‑error. Regularly revisiting the stats after major app updates keeps your device running longer between charges.









