# How To Calculate The Time of Charging of Your Battery ?

Knowing how to calculate the time your battery need to charged and discharged, help you to better predict and manage it.

To simplify the understanding, the analogy of filling a bucket with a water from a pipe can be used. in this analogy the time needed to completely fill the bucket depends as you guessed on two factors :

The size of the bucket : The biggest the bucket is, the more time it needs to be filled

The amount of water flowing through the pipe : The more quantity flows the less time the bucket need to be filled.

Therefore :

Time = Bucket Size / Amount of water flowing

and in our case :

Time = Battery Size / Amount of electricity flowing

In the electricity world the Ampere is used to measure electricity flowing and Ampere hour to measure the battery capacity

Ampere : Abbreviated Amp or simply A refers to the amount of electrons flowing per second. 1 ampere = 6.24 X 10^18

Ampere hour (abbreviated Ah, or sometimes amp hour) is the amount of energy charge in a battery that will allow one ampere of current to flow for one hour.

For small batteries mA (milli-ampere) is used instead. 1 ampere = 1000 mA

Consequently the equation could be written as following

Time = Ah / A.

Examples :

Giving an energy source providing 2A

- iPhone XS battery has 2658 mAh (or 2.658), if it is totally empty then the time it needs to fully charged is  :

Time = 2.658 / 2 =  1.3 hour

For the same Samsung galaxy s7 with 3,000mAh needs about 1.5 hour if it's connected to the same source.