Compound interest formula

The compound interest formula

The compound interest formula is A = P(1 + r/n)nt. A is the final amount. P is the starting amount, the money you put in. r is the annual interest rate as a decimal, so an example rate of 5% is 0.05. n is how many times a year interest is added. t is the number of years.

For a single deposit, our compound interest calculator gives the same answer, and shows the growth year by year.

Worked example: $10,000 for 10 years

Take $10,000 at an example rate of 5% a year, compounded monthly, for 10 years.

  1. Rate per month. Divide the annual rate by 12: 0.05 ÷ 12 = 0.004166667.
  2. Number of months. Multiply 12 by the years: 12 × 10 = 120.
  3. Growth factor. Add 1 to the monthly rate and raise it to the number of months: (1 + 0.004166667)120 = 1.647009 (to 6 decimal places).
  4. Result. Multiply the starting amount by the growth factor: 10,000 × 1.647009 = $16,470.09.

Keep every decimal until the last step. Rounding the monthly rate early changes the answer.

For education only, not financial advice.

The formula with monthly contributions

This version adds a deposit every month. With the deposit at the end of each month, the formula is:

FV = P(1 + i)N + PMT × ((1 + i)N − 1) / i

The first part is the starting amount growing on its own. The second part is all the monthly deposits, each growing for the months it has left.

Worked example. $10,000 plus $100 at the end of each month, at an example rate of 5% compounded monthly, for 10 years:

The "…" means every decimal is kept. Rounding them first can move the answer by a cent.

Of that, $22,000.00 is money put in: $10,000 to start, plus 120 deposits of $100.

For education only, not financial advice.

Deposits at the start of each month. Multiply the contribution part by (1 + i), because each deposit earns one extra month of interest. With the same $10,000, $100 a month, example rate of 5% compounded monthly and 10 years, the contribution part becomes $15,592.93, and the total becomes $32,063.02. For education only, not financial advice.

At a 0% rate. The formula would divide by zero, so use FV = P + PMT × N instead. With $10,000 to start and $100 at the end of each month for 10 years: $10,000 + $100 × 120 = $22,000.00. For education only, not financial advice.

When this formula applies. This formula is for monthly compounding with monthly deposits, where the two line up. For annual or quarterly compounding with monthly deposits, our calculator uses a common bank convention instead, explained in how this calculator works. For example, $10,000 plus $100 at the end of each month, at an example rate of 5% compounded annually, for 10 years, gives $31,728.31 on the calculator. That is why its answer differs from a textbook formula in those cases. For education only, not financial advice.

Try the formula with your numbers

Contribution timing
Monthly rate i = r ÷ 12
0.004166667
Number of months N = 12 × t
120
Growth factor (1 + i)N
1.647009
Starting amount part P × (1 + i)N
$16,470.09
Contribution part PMT × ((1 + i)N − 1) / i
$15,528.23
Total
$31,998.32

The parts are rounded separately, so they can differ from the total by a cent.

For education only, not financial advice. The 5% starting rate is only an example; try your own. Real returns vary and are not guaranteed. Taxes, fees and inflation are not included.

Solving for the rate, the time or the starting amount

The same formula can be turned around to find any one piece. These examples use a single deposit and monthly compounding.

The rate. r = n((A/P)1/(nt) − 1)

What rate would turn $10,000 into $20,000 in 10 years, compounded monthly? 12 × (21/120 − 1) gives an example rate of about 6.95%. It is "about" because at an example rate of exactly 6.95%, the $10,000 would grow to $19,996.96. This is arithmetic, not a rate you can expect to get. For education only, not financial advice.

The time. t = ln(A/P) / (n · ln(1 + r/n))

Here ln is the natural logarithm, a button on most scientific calculators. How long would $10,000 take to reach $20,000 at an example rate of 5%, compounded monthly? The formula gives 13.89 years. Interest is only added once a month, though, so the balance actually passes $20,000 at the end of month 167 (13 years 11 months). It is $19,941.74 after month 166 and $20,024.83 after month 167. For education only, not financial advice.

The starting amount. P = A / (1 + r/n)nt

How much would need to go in today to have $20,000 after 10 years at an example rate of 5%, compounded monthly? Divide by the growth factor: 20,000 ÷ 1.647009… = $12,143.22. For education only, not financial advice.

Continuous compounding

Compounding more and more often has a limit. That limit is continuous compounding:

A = Pert

Here e is a mathematical constant, about 2.71828. Most calculators and spreadsheets have it built in (in a spreadsheet, EXP()).

$10,000 at an example rate of 5% for 10 years: 10,000 × e0.05 × 10 = 10,000 × e0.5 = $16,487.21.

That is the ceiling. With the same $10,000, example rate of 5% and 10 years, daily compounding gets very close, at $16,486.65, but never passes it.

For education only, not financial advice.

The rule of 72 gives a quick estimate of how long money takes to double at a fixed rate: divide 72 by the rate.

Compound vs simple interest formula

Simple interest is paid only on the starting amount, never on interest already earned. Its formula is:

A = P(1 + rt)

$10,000 at an example rate of 5% for 10 years: 10,000 × (1 + 0.05 × 10) = $15,000.00. Compounded monthly, the same $10,000 at the same example rate for 10 years comes to $16,470.09.

For education only, not financial advice.

Compounding frequency compared

The more often interest is added, the sooner it starts earning interest of its own. Here is $10,000 at an example rate of 5% for 10 years, with no extra contributions:

CompoundingnFinal balance
Annually1$16,288.95
Quarterly4$16,436.19
Monthly12$16,470.09
Daily365$16,486.65

For education only, not financial advice.

The difference is real but small. APY (annual percentage yield) is the growth in one year once compounding is included, so it lets you compare one rate across frequencies. Try the APY calculator.

Doing it in a spreadsheet

Excel and Google Sheets have a built-in FV (future value) function. These use the same example as above: $10,000 plus $100 a month at an example rate of 5% compounded monthly, for 10 years.

=FV(0.05/12, 120, -100, -10000) returns 31,998.32 (to the cent; deposits at the end of each month).

=FV(0.05/12, 120, -100, -10000, 1) returns 32,063.02 (to the cent; deposits at the start of each month, and the final 1 means "start").

The order is: rate per month, number of months, monthly payment, starting amount, and timing.

Why the minus signs? FV treats money you pay in as negative and money you get back as positive. The $100 a month and the $10,000 are paid in, so they are entered as negatives. The balance comes back as a positive number.

To write the formula out by hand instead:

=10000*(1+0.05/12)^120 returns 16,470.09 (to the cent; single deposit).

=10000*(1+0.05/12)^120 + 100*((1+0.05/12)^120-1)/(0.05/12) returns 31,998.32 (to the cent; with $100 at the end of each month).

For education only, not financial advice.

Common mistakes