How to Calculate Compound Interest (With Examples)

How to Calculate Compound Interest

To calculate compound interest, use the formula A = P × (1 + r ÷ n)n×t, where P is the starting amount, r is the annual rate as a decimal, n is how many times a year interest is added, and t is the number of years. On $10,000 at 7% compounded monthly for 20 years, that works out to $40,387.39 — $30,387.39 of interest on top of the $10,000 you started with.

This guide runs that example end to end, so you can repeat it with your own numbers — then shows how the answer changes with yearly instead of monthly compounding, what happens when you add money every month, how to check it in Excel, and what the same maths does to a credit-card balance.

Key takeaways

  • Compound interest is interest earned on your original amount and on the interest already added — each round of interest is calculated on a bigger balance than the last.
  • The formula is A = P × (1 + r ÷ n)n×t. You need four inputs: the starting amount, the annual rate, how often interest is added, and the time in years.
  • $10,000 at 7% compounded monthly for 20 years grows to $40,387.39. The same money at the same rate with yearly compounding reaches $38,696.84 — the frequency alone is worth $1,690.55.
  • Regular contributions matter more than the rate for most savers: $1,000 plus $200 a month at 7% for 30 years becomes $252,110.70, and interest overtakes contributions around year 15.
  • Starting ten years earlier is worth far more than it costs: $200 a month from age 25 reaches $524,962.68 by 65, against $243,994.20 from age 35 — $280,968.48 more for $24,000 extra paid in.

What compound interest is — and how it differs from simple interest

The Consumer Financial Protection Bureau (CFPB) puts it in one sentence: compound interest is when you earn interest on the money you have saved and on the interest you earn along the way. The CFPB’s own example makes the point concrete: $1,000 at 5% compounded once a year becomes $1,050 after year one, then $1,102.50 after year two — the second year’s interest is 5% of $1,050, not of $1,000.

Simple interest never does that: it pays the same amount every year, calculated on the original amount only — $700 a year on $10,000 at 7%, for as long as the money sits there. Compound interest starts at the same $700, then adds a little more each year, because there is more money working each time. The gap between the two is the whole story:

After 20 yearsInterest earned
Simple interest, 7%$24,000.00$14,000.00
Compound interest, yearly, 7%$38,696.84$28,696.84
Compound interest, monthly, 7%$40,387.39$30,387.39

Over 20 years, monthly compounding earns more than twice the interest simple interest does. The advantage starts small — just $22.90 ahead after year one — and dominates later, because the interest itself starts earning interest.

The compound interest formula

A = P × (1 + r ÷ n)n×t

Each letter is one thing you need to know before you start:

  • A — the final amount: principal plus all the interest. This is the answer you are solving for.
  • P — the principal, the amount you start with. In the worked example below, $10,000.
  • r — the annual interest rate, written as a decimal — 7% becomes 0.07, not 7.
  • n — how many times a year interest is added to the balance. 1 for yearly, 4 for quarterly, 12 for monthly, 365 for daily.
  • t — the time in years the money stays put.

To find the interest alone, subtract the principal: interest = A − P. The exponent is where the power lives: time sits up there, so each extra year multiplies the whole balance again instead of adding a fixed amount.

When n = 1, the formula simplifies to A = P × (1 + r)t — the yearly-compounding version, which is the easiest to do by hand.

Worked example: $10,000 at 7%, compounded monthly, for 20 years

Step 1 — Set the inputs. P = $10,000. r = 7% = 0.07. n = 12 (monthly). t = 20 years.

Step 2 — Work out the rate per period. r ÷ n = 0.07 ÷ 12 = 0.0058333. That is the rate applied each month: about 0.58%.

Step 3 — Work out the number of periods. n × t = 12 × 20 = 240 monthly periods.

Step 4 — Raise and multiply. (1 + 0.0058333)240 = 4.038739. Multiply by the principal: $10,000 × 4.038739 = $40,387.39.

Step 5 — Work out the interest. $40,387.39 − $10,000 = $30,387.39 of interest — three times the amount you started with.

The yearly gain keeps rising even though the rate never changes:

YearBalanceInterest so farGain that year
1$10,722.90$722.90$722.90
5$14,176.25$4,176.25$955.71
10$20,096.61$10,096.61$1,354.84
15$28,489.47$18,489.47$1,920.66
20$40,387.39$30,387.39$2,722.78

In year 1 the account earns $722.90; in year 20 it earns $2,722.78 — nearly four times as much, at the same 7%. The first ten years roughly double the money; the second ten years double it again.

How compounding frequency changes the result

Frequency is how often interest is added to the balance — more frequent compounding means each round of interest starts earning sooner. Take the same $10,000 at 7% for 10 years, and change only n:

CompoundingnAfter 10 years
Yearly1$19,671.51
Half-yearly2$19,897.89
Quarterly4$20,015.97
Monthly12$20,096.61
Daily365$20,136.18

The jump from yearly to monthly is worth $425.10; from monthly to daily only $39.57 — the gains shrink fast, and continuous compounding (A = P × ert) is just $1.35 better than daily. Frequency is a small lever next to the rate and the time horizon: it will never rescue a low rate or a short horizon. When comparing accounts, APY already folds frequency in — more on that below.

Adding money every month

Real savings do not sit untouched for 20 years; most people add a bit each month. With a monthly contribution C, the future value is:

FV = P × (1 + i)N + C × [((1 + i)N − 1) ÷ i], where i = r ÷ n and N = n × t.

The first half is the starting amount growing on its own; the second half is the contributions, each compounding from the month it goes in. Take $1,000 to start, $200 a month, 7% compounded monthly, for 30 years:

  • Monthly rate i = 0.07 ÷ 12 = 0.0058333; periods N = 360.
  • Starting amount: $1,000 × (1.0058333)360 = $8,116.50.
  • Contributions: $200 × [((1.0058333)360 − 1) ÷ 0.0058333] = $243,994.20.
  • Total: $252,110.70. You paid in $73,000 ($1,000 to start plus $200 × 360 months); the other $179,110.70 is interest.
YearBalanceYou paid inInterest so far
1$3,550.81$3,400.00$150.81
5$15,736.21$13,000.00$2,736.21
10$36,626.62$25,000.00$11,626.62
15$66,241.41$37,000.00$29,241.41
20$108,224.07$49,000.00$59,224.07
30$252,110.70$73,000.00$179,110.70

For the first ten years, your own contributions are the bigger number. Around year 15, interest pulls ahead — and by year 30 it is nearly two and a half times what you paid in. That is why the monthly amount matters so much: an extra $100 a month started today is worth far more than an extra $300 a month started a decade from now, because the early money compounds the longest.

Starting ten years earlier is worth more than it costs

Same $200 a month, same 7%, retiring at 65 — start at 25 (40 years) or at 35 (30 years):

Start ageYears savingYou paid inBalance at 65
2540$96,000$524,962.68
3530$72,000$243,994.20

Waiting ten years costs $280,968.48 — more than double the final balance — for $24,000 less paid in. The extra decade is not ten more years of $200 deposits; it is ten more years of compounding on everything already saved. Time is the one input you cannot buy back.

The Rule of 72: a shortcut for doubling time

If you only want a rough answer, divide 72 by the annual rate to get the approximate years for your money to double:

Years to double ≈ 72 ÷ interest rate

At 7%, that is 72 ÷ 7 ≈ 10.3 years; the exact figure is 10.24 years, so the shortcut is off by about a month:

RateRule of 72Exact doubling time
5%14.4 years14.21 years
7%10.3 years10.24 years
10%7.2 years7.27 years

Use it to sanity-check a projection, not to replace one: above about 15% the gap widens, and it says nothing about contributions, where most real savings growth comes from.

Calculate compound interest in Excel, Google Sheets, or a calculator

The FV (future value) function does the whole calculation in one cell. In Excel or Google Sheets, type:

=FV(7%/12, 240, 0, -10000)

That returns $40,387.39. The arguments are the rate per period (7% ÷ 12), the number of periods (240 months), the regular payment (0 here — no contributions), and the starting amount as a negative number, money you hand over. With the monthly contributions from the earlier example, it becomes =FV(7%/12, 360, -200, -1000), which returns $252,110.70.

If you would rather type the formula directly, the same cell works as =10000*(1+7%/12)^(12*20). And if you do not want to build the spreadsheet at all, a compound interest calculator takes the same four inputs and returns the final amount with a year-by-year table — the fastest way to test a few scenarios side by side.

APY: the number to compare when choosing an account

Banks quote a nominal rate and a compounding schedule, and two accounts with the same nominal rate can grow differently. APY — annual percentage yield — folds the frequency into a single number, so accounts compare directly. A 7% nominal rate compounded monthly has an APY of 7.229%; compounded yearly, the same 7% has an APY of exactly 7%. When two savings accounts advertise different rates, compare APYs, not the headline rate.

Compound interest on loans: the same maths, working against you

Everything above runs in reverse on a debt. Unpaid interest is added to the balance, and the next round of interest is charged on the larger amount — which is why a credit-card balance grows faster than people expect when only minimum payments are made. A $5,000 balance at 20% compounded monthly, with no payments for a year, becomes $5,000 × (1 + 0.20 ÷ 12)12 = $6,096.96 — $1,096.96 of interest in twelve months, on a balance nobody touched.

The borrowing side has its own comparison number: APR, which folds fees into the rate the way APY folds frequency in. The guide to calculate APR on a loan works through it, and an APR calculator runs it on any offer you are comparing.

Mistakes that give you the wrong number

  • Entering 7 instead of 0.07. The formula wants the rate as a decimal; using 7 makes the answer roughly a hundred times too large.
  • Using the yearly formula when interest compounds monthly. A = P × (1 + r)t gives $38,696.84 on the worked example; the monthly version gives $40,387.39. Match n to the account’s schedule.
  • Forgetting contributions, or adding them at the wrong end. The FV formula assumes contributions go in at the end of each month; starting a month earlier or later shifts the result by one month of compounding.
  • Assuming the rate stays fixed. Every figure in this guide holds the rate constant for the whole period. Real savings rates change, and investment returns vary year to year — a 7% average over 20 years is not 7% every year.
  • Ignoring taxes, fees, and inflation. The numbers here are pre-tax and nominal. Taxes and fees reduce what you keep, and inflation reduces what it buys. For retirement planning, rerun the calculation with a lower real rate — the nominal rate minus roughly 2–3% for inflation.
  • Comparing APR with APY. APR is a borrowing cost (fees included); APY is a savings yield (frequency included). They are built for opposite sides of the same maths, and swapping them gives a misleading comparison.

A short note for UK readers

The maths is identical in the UK; only the labels change. APY’s UK equivalent is AER — annual equivalent rate — which savings accounts must show. Cash ISAs shelter the interest from tax, so compounding works on the full amount. UK personal loans are usually fixed-rate repayment loans quoted with a representative APR — the rate at least 51% of successful applicants receive — and the lender must show the total amount payable.

Frequently asked questions

What is the formula to calculate compound interest?

A = P × (1 + r ÷ n)n×t. P is the starting amount, r is the annual rate as a decimal (7% = 0.07), n is how many times a year interest is added (12 for monthly), and t is the number of years. The interest alone is A − P.

How do I calculate compound interest by hand?

Divide the annual rate by the periods per year (0.07 ÷ 12 = 0.0058333), multiply periods per year by years (12 × 20 = 240), add 1 to the rate per period and raise it to 240 (1.0058333240 = 4.038739), then multiply by the starting amount: $10,000 × 4.038739 = $40,387.39. Subtract the principal for $30,387.39 of interest.

How do monthly contributions change the calculation?

Each contribution compounds from the month it goes in, so early contributions matter most. $1,000 to start plus $200 a month at 7% compounded monthly for 30 years grows to $252,110.70 — $73,000 paid in, $179,110.70 of interest. Interest overtakes total contributions around year 15. In Excel, =FV(7%/12, 360, -200, -1000) gives the same answer.

What is the difference between compound interest and simple interest?

Simple interest pays only on the original amount — $700 a year, every year, on $10,000 at 7%. Compound interest pays on the original amount plus all interest already added, so the yearly gain rises: $722.90 in year one, $2,722.78 in year 20. Over 20 years, monthly compounding earns $30,387.39 against simple interest’s $14,000.00.

Run the formula once by hand so you know what the calculator is doing, then test your own figures — and, if the horizon is long, with a lower real rate as well: the number that matters is the one after inflation and tax, not the headline figure.

This article is general information, not financial advice. Rates, fees, and terms change, and the figures here are illustrative — check your bank’s or lender’s current terms before deciding.