Battery Life Calculator
Estimate how long a battery lasts, including devices that sleep most of the time and wake up briefly.
How it works
Iavg = Iactive × D + Isleep × (1 − D) | Runtime = Capacity × Usable% / IavgHere D is the fraction of time the device is awake. Only part of the rated capacity is usually available, because of voltage cut-off, temperature, aging and high discharge currents, so the calculator applies a usable-capacity factor (80% is a common starting point).
This is an estimate. Real battery life depends on temperature, discharge rate, regulator efficiency and cell quality. Measure your actual current draw whenever you can.
Frequently asked questions
Why is my real battery life shorter than the estimate?
Common reasons are higher real sleep current, regulator losses, cold temperatures, battery self-discharge and a rated capacity that was measured at a very low discharge rate.
How do I reduce power consumption?
Spend more time in deep sleep, lower the clock speed, turn off unused peripherals and radios, and use a more efficient regulator.
What is mAh?
Milliamp-hours is a measure of charge. A 2000 mAh battery can in theory supply 2000 mA for one hour or 20 mA for 100 hours.
More calculators
I take on small freelance jobs: Arduino and Raspberry Pi projects, Python scripts and small PCB designs.
See what I can build