Estimate how long your ESP32 project can run on a battery, or work backwards to find the battery size you need.
Still planning? Choose your board and a project profile. If you have measured the current drawn by your complete circuit, use Measured project for a better estimate.
How long can an ESP32 run on a battery?
Battery life depends on the current drawn by the complete board, how long it stays awake and how often it wakes up. A sensor that sends a reading every 15 minutes can last much longer than one that keeps Wi-Fi connected. The calculator above estimates runtime for your setup.
Using the calculator
For a new build, start with Planning estimate. Choose your board, the closest project type, your wake interval and battery details. These are starting figures, not measurements from your circuit.
If you’ve built the project, choose Measured project and enter your own awake and sleep currents. Advanced power model lets you adjust the individual phases. To find a suitable battery capacity instead of runtime, choose What battery size do I need?
Your board and sleep current matter
Two boards using the same ESP32 chip can have very different sleep currents. Regulators, power LEDs and connected sensors may still draw power while the ESP32 is asleep. Use figures for your complete board wherever possible, not just the chip.
Not sure how long your project will stay awake? Leave the suggested value for a first estimate. Once it’s running, time the period from boot to deep sleep and measure the current in both states. A multimeter can miss short Wi-Fi and radio current spikes, so a power profiler is better for detailed measurements.
For more on this, see my ESP32 deep sleep guide and low-power board comparison.
Battery capacity and real-world losses
The default battery option is a single-cell Li-ion/LiPo. For another battery type or one connected through a regulator or converter, choose Other battery and enter the battery voltage. Check how your board should be powered before connecting anything.
The main runtime result is rounded because the inputs and battery’s usable capacity aren’t exact. Temperature, battery age, converter losses and the time spent connecting to Wi-Fi can all affect the result. Open Show calculation details to see the numbers used.
What affects battery life?
- Awake current and the length of each wake cycle
- Deep-sleep current from the board and attached sensors
- How often the ESP32 wakes
- Wi-Fi, Bluetooth, LoRa, Zigbee or Thread activity
- Battery condition, temperature and regulator efficiency
Battery-life example
Here’s a simplified example of a sensor that wakes every 15 minutes. The currents are hypothetical, not measurements from a particular ESP32 board.
| Wake interval | 15 minutes |
|---|---|
| Awake current | 80 mA for 10 seconds |
| Sleep current | 0.08 mA (80 µA) for 890 seconds |
| Battery | 2,000 mAh, with 80% assumed usable |
| Average current | About 0.97 mA |
| Estimated runtime | About 69 days |
This works out to roughly 0.97 mA averaged over a full cycle. A usable capacity of 1,600 mAh gives about 69 days before other losses. Your own board, peripherals and power supply can change that considerably.
For a project using a similar sleep-and-wake approach, see my LoRa water-tank sensor. The outdoor sensor power guide covers batteries and charging, and you can use the solar sizing calculator if you want to add a panel.
Frequently asked questions
What if my ESP32 board isn’t listed?
Choose Generic ESP32 dev board / not sure for a broad planning estimate, or Other board / not listed if you’re entering your own board figures. If you’ve measured the whole project, use Measured project.
Does a bigger battery always solve short runtime?
Not necessarily. If a board draws too much current in deep sleep or spends too long awake, reducing that consumption can have a greater effect than fitting a larger battery.
Can I use this to choose a solar panel?
Use this tool to estimate battery consumption first, then enter the daily usage into my Solar & Battery Sizing Calculator. For single-cell Li-ion solar charging hardware, I’ve also covered the CN3791 solar charger.




