Skip to content
Battery Runtime

Battery Life Calculator

Estimate how long a battery-powered device will run from its capacity in mAh and the current it draws in mA. Handles sleep modes and duty cycles for sensors, wearables and IoT projects.

Updated · Free, no sign-up · Runs in your browser

Quick answer

Battery life (hours) = capacity (mAh) × 0.85 ÷ current draw (mA). A 2,000 mAh battery powering a 100 mA device lasts about 17 h. For devices that sleep, use the average current.

Calculate device battery life

mAh
Does the device sleep between uses?
mA
%

85% allows for temperature, age and cut-off voltage.

Estimated battery life

17 h

≈ 17 hours at an average 100 mA

Average current
100 mA
In days
0.7 days

2,000 mAh × 85% ÷ 100 mA = 17 h

The battery life formula

Battery life (h) = capacity (mAh) × usable share ÷ average current (mA)

The usable share, 85% by default, covers the capacity you lose to temperature, battery age and the device’s cut-off voltage. Lithium cells deliver close to their rating; alkaline batteries in high-drain devices can deliver well under it.

Devices with a sleep mode

Most battery-powered electronics spend nearly all their time asleep. The average current decides battery life:

Average (mA) = active mA × active % + sleep mA × (100% − active %)

Example: a temperature sensor wakes once a minute, draws 15 mA for 60 ms (0.1% of the time) and sleeps at 5 µA. Its average is 0.02 mA, so a 225 mAh CR2032 coin cell lasts about 398 days 13 h. In practice, coin cell self-discharge and pulse-current limits shorten that, so test with your real hardware.

Typical battery capacities

BatteryNominal voltageTypical capacityLife at 10 mA
CR2032 coin cell3 V225 mAh19 h 8 min
AAA alkaline1.5 V1,000 mAh3 days 13 h
AA alkaline1.5 V2,500 mAh8 days 21 h
AA NiMH rechargeable1.2 V2,000 mAh7 days 2 h
18650 lithium-ion3.6–3.7 V3,000 mAh10 days 15 h
9 V alkaline9 V550 mAh46 h 45 min

Capacities vary by brand and by how fast the battery is drained; alkaline ratings in particular are measured at low currents. Check the manufacturer’s datasheet for the current your device draws.

How to measure your device’s current

  • Datasheet or spec sheet: look for the operating and standby current.
  • Multimeter in series: set it to mA and place it between the battery and the device. It is fine for steady loads but misses short peaks.
  • USB power meter: for USB-powered gadgets, it shows current and mAh used over time.
  • Power profiler: for sleep currents in the microamp range, a dedicated power analyser captures both the sleep floor and the wake-up spikes.

For larger batteries rated in Ah or Wh, such as 12 V, UPS or power station batteries, the battery runtime calculator works in watts and accounts for inverter losses. The reasoning behind both calculators is in how battery runtime is calculated.

Frequently asked questions

How do you calculate battery life in hours?

Battery life (hours) = battery capacity in mAh ÷ device current in mA. Multiply the result by about 0.85 to allow for temperature, ageing and the device shutting off before the battery is completely flat. A 2,000 mAh battery powering a 100 mA device lasts about 2,000 × 0.85 ÷ 100 = 17 hours.

How long will a 2000 mAh battery last?

At 100 mA, about 17 h. At 20 mA, about 3 days 13 h. At 500 mA, about 3 h 24 min. The current your device draws makes all the difference, so measure or look it up rather than guessing.

How do I calculate battery life for a device that sleeps?

Work out the average current: active current × share of time active + sleep current × share of time asleep. Then divide the capacity by that average. A sensor that draws 15 mA for 0.1% of the time and 5 µA otherwise averages about 0.02 mA, so a CR2032 coin cell lasts around a year. Choose Sleeps (duty cycle) in the calculator to do this.

Does battery voltage matter for mAh battery life?

Only when you compare batteries of different voltages or the device uses a regulator. mAh ÷ mA works when the capacity and current are at the same voltage. If a 3.7 V battery feeds a 5 V device through a boost converter, convert both to watt-hours first (the mAh to Wh converter does this), or use the main battery runtime calculator in Wh.

Why does my battery die sooner than the calculation?

Short bursts of high current (radio transmissions, motors, screen backlight) raise the average more than you expect, alkaline batteries lose capacity at higher currents, and cold weather cuts capacity. Lower the usable capacity setting to 70% for alkaline batteries in demanding devices.