Provide any two of capacity, current, and runtime — the third is solved. Battery voltage enables Wh output and power-based input. Efficiency and depth of discharge are optional corrections.
The runtime of a battery-powered device follows directly from the relationship between stored charge and current consumption. A battery rated at capacity \( C \) (in mAh or Ah) can deliver an average current \( I \) for a time: \[ t = \frac{C}{I} \] A 2000 mAh battery powering a 100 mA load will last 20 hours in the ideal case. The formula is the same regardless of chemistry — the mAh rating is the fundamental quantity that defines how much charge the battery holds.
When the load is specified as a power draw rather than a current, we first convert using the battery voltage \( V \): \[ I = \frac{P}{V}, \qquad t = \frac{C \cdot V}{P} \] This is useful when the datasheet of a module gives a power figure rather than a current figure, or when the load operates from a regulated voltage that differs from the battery voltage.
Most battery-powered systems include a voltage regulator or DC-DC converter between the battery and the load. These converters are not lossless: a boost converter running at 85% efficiency requires the battery to supply 100/85 ≈ 1.18 times the power the load actually consumes. The calculator accounts for this by dividing the load current by the efficiency factor before computing the runtime: \[ I_{\text{battery}} = \frac{I_{\text{load}}}{\eta} \] Ignoring converter losses is one of the most common sources of error when estimating battery life. A system that looks like it should run for 10 hours at full load may actually run for 8.5 hours once a typical 85% efficient boost converter is factored in.
Most battery chemistries should not be discharged to zero. Doing so shortens cycle life significantly. The depth of discharge (DoD) sets what fraction of the nominal capacity is actually used:
When DoD is entered, the calculator reduces the effective capacity to \( C \cdot \text{DoD} \) before computing runtime or required capacity. For sizing a battery pack with longevity in mind, enter the DoD along with the required runtime to find the nominal capacity needed.
Any two of capacity, current, and runtime determine the third. The rearranged formulas are:
The calculation assumes a constant average current draw. Real devices rarely have a flat profile: a microcontroller sleeping most of the time with periodic radio bursts has a very different average than its peak consumption. For duty-cycled loads, compute the time-weighted average current and use that as the input.
Battery capacity also degrades with temperature. Most lithium cells deliver their rated capacity only at around 20–25 °C. At 0 °C available capacity can drop to 70–80% of the nominal value; at -20 °C it can fall below 50%. For outdoor or automotive applications, it is worth applying an additional temperature derating factor on top of the DoD.
For lead-acid batteries, the Peukert effect is relevant: capacity decreases at higher discharge rates, so the simple formula overestimates runtime under heavy loads. For lithium chemistries the Peukert effect is minor and can usually be ignored in first-order estimates.
More calculators: blog.hirnschall.net/tools/.