Battery Life Calculator

Calculate how long a battery will last based on its capacity and the current draw of your device. Includes efficiency factor for realistic estimates.

Battery Life Formula: Runtime (hours) = Capacity (mAh) / Current Draw (mA) Actual Runtime = Theoretical Runtime × Efficiency Factor Where: • Capacity = Battery capacity in milliamp-hours (mAh) • Current Draw = Average current consumption in milliamps (mA) • Efficiency Factor = Real-world efficiency (0.7-0.9) - Lithium-ion: 0.85-0.9 - NiMH: 0.8-0.85 - Alkaline: 0.7-0.8 Energy Capacity (Wh) = Capacity (Ah) × Voltage (V)
Example 1 (LED Flashlight): Battery: 2000mAh (2×AA NiMH) Current: 200mA Efficiency: 0.85 Runtime = (2000 / 200) × 0.85 = 8.5 hours Example 2 (Arduino Project): Battery: 2500mAh (Li-ion) Current: 50mA average Efficiency: 0.9 Runtime = (2500 / 50) × 0.9 = 45 hours ≈ 1.9 days Example 3 (ESP32 Deep Sleep): Battery: 1000mAh Current: 5mA average (with sleep mode) Efficiency: 0.85 Runtime = (1000 / 5) × 0.85 = 170 hours ≈ 7.1 days Example 4 (Power Bank): Capacity: 10000mAh Current: 500mA (charging phone) Efficiency: 0.85 Runtime = (10000 / 500) × 0.85 = 17 hours Can charge phone ~4-5 times

How is battery life calculated?

Battery life (runtime) is calculated using the formula: Runtime (hours) = Battery Capacity (mAh) / Current Draw (mA). For example, a 2000mAh battery powering a 100mA device will last 20 hours theoretically.

Why is actual battery life shorter than calculated?

Actual battery life is typically 70-90% of calculated values due to inefficiencies, voltage drop under load, temperature effects, battery age, self-discharge, and the fact that batteries can't be fully discharged without damage.

What does mAh mean?

mAh stands for milliamp-hour, a unit of electric charge. A battery rated at 1000mAh can theoretically supply 1000mA for 1 hour, or 100mA for 10 hours, or any equivalent combination.

How do I measure current draw?

Use a multimeter in series with your device to measure current draw. For devices with varying loads (like microcontrollers), measure average current over a complete cycle, or measure different modes and calculate weighted average.

Can I use this for different battery chemistries?

Yes, the basic calculation works for all battery types (lithium-ion, NiMH, alkaline, etc.), but each chemistry has different discharge characteristics. Lithium batteries provide more usable capacity than alkaline at high currents.

What is battery efficiency factor?

Efficiency factor accounts for real-world losses. Use 0.9 for lithium-ion, 0.85 for NiMH, and 0.7-0.8 for alkaline batteries. This multiplier gives more realistic runtime estimates than theoretical calculations.

How does temperature affect battery life?

Cold temperatures reduce battery capacity significantly (50% or more at freezing). High temperatures increase self-discharge and can damage batteries. Optimal performance is typically 20-25°C (68-77°F).

What if my device has multiple power modes?

Calculate weighted average current: (Time_active × Current_active + Time_sleep × Current_sleep) / Total_time. For example: (1s × 50mA + 9s × 5mA) / 10s = 9.5mA average.

How do I extend battery life?

Reduce current draw by using sleep modes, lowering clock speeds, turning off unused peripherals, using efficient voltage regulators, optimizing code, and selecting low-power components. Even small reductions multiply over time.

What is C-rating and how does it affect battery life?

C-rating indicates discharge rate relative to capacity. 1C means discharging at current equal to capacity (2000mAh battery at 2A = 1C). Higher C-ratings reduce effective capacity and battery life due to internal resistance.

Can I connect batteries in parallel for longer life?

Yes, connecting identical batteries in parallel increases total capacity while maintaining voltage. Two 2000mAh batteries in parallel provide 4000mAh capacity, doubling runtime for the same current draw.

What is depth of discharge (DoD)?

DoD is the percentage of battery capacity used. Lithium batteries should typically discharge to 20% (80% DoD) for longevity. The calculator assumes full discharge, but multiply runtime by your desired DoD for safer estimates.