Compound interest is interest calculated on your balance plus the interest already earned, so each period’s interest is charged on a bigger base than the one before. That single change is why money grows faster the longer it sits, and why the last few years of a long plan add far more than the first few.
What is the compound interest formula?
The standard formula for a single lump sum is A = P(1 + r/n)^(nt). Each letter stands for one input, and once you have all four you can solve the whole thing on any calculator.
- A is the final balance.
- P is the starting amount, or principal.
- r is the annual rate written as a decimal, so 7% becomes 0.07.
- n is how many times interest compounds each year. Monthly is 12.
- t is the number of years.
The exponent does the heavy lifting. Because the term (1 + r/n) is raised to the power of nt, growth is multiplicative rather than straight-line. That is the mathematical reason compounding feels slow at first and fast later.
How do you calculate compound interest step by step?
You work through five steps: convert the rate, set the period count, apply the formula for the lump sum, then handle contributions month by month. Doing it in that order keeps the arithmetic clean.
Step 1: Convert the annual rate to a decimal and a period rate
Divide the percentage by 100 to get the decimal. A 7% annual return becomes 0.07. Then divide by the number of compounding periods per year: 0.07 divided by 12 gives roughly 0.005833 per month.
That monthly figure is what actually gets applied each period. Small rates repeated many times are what produce large balances.
Step 2: Work out the number of compounding periods
Multiply the years by the periods per year. Twenty years with monthly compounding is 20 times 12, or 240 periods. Keep that number handy — it is the exponent in the formula.
If you only have a lump sum and no contributions, you can stop after step 3.
Step 3: Apply the formula to the lump sum
Raise (1 + period rate) to the number of periods, then multiply by the starting amount. For a lump sum, this gives the balance with no further deposits. Everything after this step only matters if you add money along the way.
Step 4: Add each contribution after its period’s interest
For monthly contributions, take the balance, multiply it by one plus the monthly rate, then add the deposit. Repeat for all 240 months. The order matters: interest is applied to what was already there before the new money goes in.
Written as a loop, it looks like this:
balance = balance × (1 + r/12) + monthly contribution
Step 5: Split the result into contributions and interest
Add up the starting amount and every contribution to get total contributed. Subtract that from the final balance and you have interest earned. This is the number that shows what compounding actually did for you.
For a shortcut, our compound interest calculator runs all five steps from four inputs.
Worked example: $10,000 plus $500 a month at 7% for 20 years
Put those inputs together and the balance reaches $300,850.72 after 240 months. Here is how the pieces break down.
- Starting amount: $10,000
- Monthly contribution: $500
- Total contributions: $500 × 240 = $120,000
- Total contributed: $10,000 + $120,000 = $130,000
- Final balance: $300,850.72
- Interest earned: $300,850.72 − $130,000 = $170,850.72
- Interest as a share of the balance: $170,850.72 ÷ $300,850.72 = 56.8%
More than half of the final balance is interest rather than money out of your pocket. That is the whole case for starting early and staying in.
The growth is also back-loaded. After one year the balance is $16,919.19, meaning only $919.19 of interest has built up.
After five years it is $49,972.70, after ten years $106,639.02, and after fifteen years $186,970.62. More than a third of the final balance arrives in the last five years alone.
Two comparisons show where the value comes from. Cut the horizon to ten years and the same $10,000 and $500 a month reaches just $106,639.02, roughly a third of the twenty-year figure. Drop the contributions entirely and the $10,000 alone grows to $40,387.39 over twenty years.
You can see the same mechanic at work on the other side of the ledger in our guide to how amortization works, where a loan balance compounds against you in exactly the same shape.
How often should interest compound?
More frequent compounding grows the balance slightly faster, because interest starts earning interest sooner. The size of the effect depends on the rate and the horizon, not on the label on the account.
For savings accounts and most investment accounts, monthly is the usual assumption, and it is what the example above uses. Daily compounding is a small step faster than monthly at the same stated rate. Annual compounding is the slowest.
The bigger variable is the rate itself, not the frequency. At 5% instead of 7%, the same $10,000 plus $500 a month reaches only $232,643.24 over twenty years — about $68,000 less. That gap is roughly 40 times the kind of difference frequency alone tends to produce at these rates.
Use the return net of fees. A fund charging 1% a year keeps a meaningful share of the return over twenty years, and the calculator will happily show you the rosy version if you feed it the gross number.
What return should you assume?
Match the assumption to where the money will actually sit, not to what you hope it earns. A high-yield savings account, a bond fund and a stock portfolio have very different expected returns and very different risk.
A diversified stock portfolio has historically returned around 7% a year on average, with large up and down years along the way. That 7% is an average, not a promise, and a bad decade early on can change the picture a lot.
For money you need in two or three years, a much lower rate is honest. For a thirty-year retirement plan, the long-run average is a more reasonable input, as long as you accept the volatility. Our guide to what compound interest is and how it grows your money walks through how the assumption changes the result.
How does compounding change if you add money monthly?
Monthly contributions often matter as much as the return, and sometimes more. In the example, the $500 a month turned a $40,387.39 lump-sum result into $300,850.72 — the contributions did most of the work.
The reason is simple arithmetic. Each deposit joins the balance and then compounds for every remaining period. Early contributions compound for the full term; late ones barely compound at all.
That is why a plan that starts at 25 and runs to 65 looks so different from one that starts at 45, even with the same monthly amount. Time is the input you cannot buy back later.
How do you check your own numbers?
Run the formula, then sanity-check the output against two things: total contributed and the interest share. If interest is a tiny slice of the final balance, either the horizon is short or the return is low.
Try a second rate and a second horizon. If a one-point change in the assumed return moves the answer by tens of thousands of dollars, you know the result is sensitive to the assumption and should not be treated as a forecast.
Then translate it into monthly terms. Divide the final balance by the number of months to see what the plan is effectively building toward. In the example, $300,850.72 over 240 months averages $1,253.54 a month — useful for comparing against your actual budget.
If you are aiming at a specific number rather than just watching growth, the savings goal calculator works backwards from the target.
Common mistakes
- Forgetting to convert the rate. Using 7 instead of 0.07 in the formula produces an answer that is wildly wrong. Always divide the percentage by 100 first.
- Treating the average return as steady. The calculator assumes the same return every year. Real portfolios have years of 20% and years of minus 15%, and the order of those years changes the outcome.
- Assuming a gross return. Fees come out of the return before you see it. A 1% annual fee over twenty years keeps a meaningful share of the growth.
- Adding contributions before interest. Apply interest to the existing balance first, then add the deposit. Doing it the other way overstates the result.
- Using a short horizon for long-term money. Compounding needs time. Ten years at these inputs produces about a third of the twenty-year result.
- Ignoring the loan side. The same math runs against you on debt. A credit card balance compounds at a far higher rate than any savings account pays.
Once you have the formula down, the fastest way to see your own picture is to plug in your numbers and watch the year-by-year table build.