Battery Life Calculator
The Battery Life Calculator estimates how long a battery will power your device from its capacity, the current your circuit draws, and the energy lost along the way. Enter a few numbers and you get a realistic runtime in hours or days, updated live as you type.
It works for hobby and engineering projects alike — an Arduino or ESP32 sensor node, an 18650 or LiPo pack, an LED strip, or a power bank. Two modes cover both directions of the question: Battery Life tells you how long a given battery lasts, and Required Capacity tells you what capacity you need for a target runtime.
How to Use the Battery Life Calculator
Choose a mode
Keep the default Battery Life tab to find how long a battery lasts, or switch to Required Capacity to size a battery for a runtime you set.
Enter the battery
Type the Capacity in mAh or Wh and the Voltage. Or tap Presets and pick a battery — the capacity and voltage fill in automatically.
Add the load
Enter your device's Current (mA) and set the Duty Cycle below 100% if it sleeps between bursts. Use Add Load to include more devices sharing the battery.
Tune efficiency and read the result
Drag the Efficiency slider (default 85%) to match your regulator, then read the runtime, the load breakdown, and the step-by-step formula — all updated in real time.
Features
Battery Life from Capacity and Draw
Estimate runtime from a battery's capacity in mAh or Wh and your device's current draw.
Required Capacity Mode
Flip the calculation to find the minimum battery capacity needed for a runtime you choose.
Multiple Loads
Add several devices, each with its own name, current, and duty cycle, all sharing one battery.
Circuit Efficiency Adjustment
A slider from 50% to 100% accounts for regulator and converter losses, defaulting to a realistic 85%.
12 Battery Presets
One tap fills capacity and voltage for CR2032, AA, AAA, 9V, 18650, LiPo, lead-acid, and power-bank cells.
Load Breakdown Chart
A horizontal bar chart shows how much each load contributes to total power consumption.
Color-Coded Battery Indicator
A visual battery bar turns green, yellow, or red so you can read the runtime status at a glance.
Step-by-Step Formula
See the exact formula with your numbers substituted in, so the result is never a black box.
Quick Examples
Load ready-made scenarios — Arduino, ESP32 deep sleep, LED strip, and phone charging — with one click.
Automatic mAh / Wh Conversion
Switch capacity units freely; the calculator converts between mAh and Wh using your voltage.
Real-Time Calculation
Every field recalculates instantly as you type — no submit button, no waiting.
Frequently Asked Questions
How do I calculate battery life from mAh and current?
The basic formula is runtime in hours = battery capacity (mAh) ÷ current draw (mA). This calculator goes further by multiplying the result by your circuit efficiency, so the estimate reflects real-world losses rather than the theoretical maximum.
How long will a 5000mAh battery last?
It depends entirely on the current draw. At 500 mA and 85% efficiency, a 5000 mAh battery lasts about 8.5 hours; at 50 mA it lasts roughly 85 hours. Enter your real load and duty cycle and the calculator shows the exact figure for your device.
What is the difference between mAh and Wh?
mAh (milliamp-hours) measures charge at a specific voltage, while Wh (watt-hours) measures total energy regardless of voltage. To convert, Wh = mAh × V ÷ 1000. Compare batteries in mAh when their voltage matches, and in Wh when it differs. The calculator switches between the two automatically.
What efficiency value should I use?
It depends on your power path. A linear regulator such as the LM7805 is typically 50–70% efficient, a switching buck or boost converter is usually 80–95%, and a device powered straight from the battery with no regulator is 95–100%. The slider defaults to 85%, a reasonable figure for most regulated circuits.
What is duty cycle and why does it matter?
Duty cycle is the percentage of time a load actively draws current. An IoT sensor that wakes for 1 second every 100 seconds has a 1% duty cycle, so its average current — and battery drain — is a fraction of its peak. Setting an accurate duty cycle is the biggest factor in extending estimated battery life.
Why is my actual battery life shorter than calculated?
Several real-world factors reduce runtime: cold temperatures cut usable capacity, batteries self-discharge over time, devices stop working before the cell is fully empty (voltage cutoff), brief current spikes such as WiFi transmission may not be captured by an average reading, and older cells hold less charge. Treat the result as a well-grounded estimate and leave some headroom.
How do I measure my device's current draw?
Use a multimeter in series with the power supply, or a USB power meter for USB-powered devices. For hardware with sleep modes, measure the active and sleep currents separately, then enter them as two loads with their own duty cycles so the calculator can combine them into an accurate average.
No comments yet. Be the first to comment!