Battery Calculator

Estimate how long a battery takes to charge, how long it'll last, or work out its capacity from a simple discharge test — pick a mode above to get started.

Result
Estimated Charge Time
Energy NeededTo reach 100% from current charge
Result Live
Estimated Runtime
Available Energy

Calculate battery capacity from a controlled discharge test using a known current and measured discharge time.

Result Live
Battery Capacity
Energy Capacity

How to use the Battery Calculator

This calculator has three modes for common battery calculations: Charge Time, Battery Life, and Battery Capacity. You can enter battery capacity in mAh, Ah, or Wh depending on the information available on your battery or device.

When a battery is specified in mAh or Ah, the calculator uses its nominal voltage to convert the capacity into watt-hours (Wh). This makes it possible to compare the battery's stored energy with charger or device power, which is normally specified in watts.

How to calculate battery charge time

Battery charge time depends on how much energy is still needed and how much power effectively reaches the battery. The calculator first determines the battery's total energy capacity, then calculates the portion remaining at the current state of charge.

Energy Needed
Energy Needed = Battery Capacity (Wh) × (1 − Current Charge / 100)
Effective Charging Power
Effective Power = Charging Power × Efficiency / 100
Charge Time
Charge Time = Energy Needed / Effective Charging Power

For example, a 14.8 Wh battery at 20% charge needs about 11.84 Wh to reach 100%. With a 20 W charger and 85% charging efficiency, the effective charging power is 17 W, giving a theoretical charge time of about 42 minutes.

This is an estimate rather than a prediction of the exact time shown by a real device. Charging power can change during charging, and many lithium-ion devices reduce charging power as the battery approaches full.

How to calculate battery life

Battery life can be estimated by dividing the energy available in the battery by the power consumed by the device. If the battery is only partially charged, the calculator uses the current charge level to determine how much energy remains available.

Available Energy
Available Energy = Battery Capacity (Wh) × Current Charge / 100
Battery Life
Runtime = Available Energy / Device Power Consumption

For example, a 37 Wh battery that is 50% charged has approximately 18.5 Wh remaining. If the device continuously consumes 5 W, the theoretical runtime is about 3.7 hours.

Actual battery life can be shorter or longer because device power consumption changes over time. Screen brightness, processor load, wireless connections, temperature, battery age, and other factors can all affect runtime.

How to calculate battery capacity

If you don't know a battery's rated capacity, you can estimate it from a controlled discharge test. Measure the current drawn from a full battery and the amount of time the battery takes to reach the chosen discharge endpoint.

Battery Capacity
Capacity (Ah) = Discharge Current (A) × Discharge Time (hours)

For example, if a battery supplies a constant 0.5 A for 4 hours, its measured capacity is approximately 2 Ah, or 2,000 mAh.

You can also estimate its energy capacity in watt-hours by multiplying the amp-hour capacity by the battery's average voltage during the discharge test:

Energy Capacity
Energy Capacity (Wh) = Capacity (Ah) × Average Voltage (V)

The battery capacity calculation is an estimate based on the test conditions. Battery capacity can vary with discharge current, temperature, battery age, and the voltage cutoff used during the test.

mAh vs. Ah vs. Wh

Battery capacity is commonly listed in mAh (milliamp-hours) or Ah (amp-hours), while energy is measured in Wh (watt-hours). mAh and Ah describe electrical charge, whereas Wh takes voltage into account and describes energy.

Convert Ah to Wh
Wh = Ah × Voltage (V)

For example, a 5 Ah battery with a nominal voltage of 12 V has an approximate energy capacity of 60 Wh:

5 Ah × 12 V = 60 Wh

If you need to calculate or convert energy in watt-hours without the battery-specific calculations, see our Watt-hour Calculator.

Why battery voltage matters

A battery's mAh rating alone doesn't tell you how much energy it stores. Two batteries can have the same mAh capacity but different voltages and therefore different energy capacities.

For example, a 2,000 mAh battery at 3.7 V stores approximately 7.4 Wh, while a 2,000 mAh battery at 12 V stores approximately 24 Wh. This is why voltage is required when converting an mAh or Ah rating into Wh.

The calculator uses nominal battery voltage for these conversions. Actual battery voltage changes as a rechargeable battery charges and discharges, so the resulting Wh value should be treated as an estimate.

Frequently asked questions

How long does 20 percent battery last?

It depends on the battery's capacity and how much power your device consumes. Use the Battery Life tab above, set "Current Charge Level" to 20%, and enter the battery capacity and device power consumption to estimate the remaining runtime.

Why do I need to enter voltage if I already know my battery's capacity in mAh?

mAh and Ah measure electrical charge rather than energy, so they don't account for voltage. Since charger and device power are normally specified in watts, voltage is needed to convert mAh or Ah into watt-hours. If you already know the battery's capacity in Wh, you can enter it directly without entering voltage.

What charging efficiency should I use?

85% is a reasonable general estimate for lithium-ion charging. Actual efficiency varies with the charger, charging circuitry, cable, battery, temperature, and charging conditions, so the result should be treated as an estimate.

What is the difference between mAh and Wh?

mAh measures electrical charge, while Wh measures energy. Watt-hours take voltage into account, so Wh is generally more useful when comparing the energy stored by batteries with different voltages. Convert using Wh = Ah × V.

Can I use this calculator for different types of batteries?

Yes. The calculations are based on general electrical relationships and can be used for rechargeable batteries when their capacity, voltage, current, power, and other required values are known. Actual charging time and runtime can vary depending on the battery chemistry, charging system, discharge conditions, and device.