Home › Finance › Compound Interest Calculator
Compound Interest Calculator
Computes the future balance of a principal earning compound interest at a chosen compounding frequency, optionally with a fixed deposit at the end of every month, and splits the result into contributions and interest.
When to use
You need to project a savings account, certificate of deposit or investment balance from a starting amount, an annual rate, a term and optional monthly deposits.
Do not use when: Interest is not reinvested (use simple-interest), you need the deposit required to hit a target (use savings-goal), or you are repaying a loan (use loan-payment).
Formula
A = principal × (1 + r/n)^(n·years) with r = annual_rate_percent/100 and n periods per year. Contributions: i_m = (1 + r/n)^(n/12) − 1, m = 12·years, FV_contrib = monthly_contribution × ((1 + i_m)^m − 1) / i_m (m × contribution when r = 0). final_balance = A + FV_contrib.
Interest is credited n times per year at r/n per period. Monthly deposits are assumed at the end of each month and grow at the effective monthly rate of the chosen compounding, so principal and deposits follow one consistent growth curve; the deposit formula assumes 12·years is a whole number of months.
Inputs
| Parameter | Type | Unit | Required | Description |
|---|---|---|---|---|
principal | number | yes | Starting amount deposited or invested, in any currency. Range: ≥ 0, ≤ 1000000000000 | |
annual_rate_percent | number | % | yes | Nominal annual rate (APR) in percent; 5 means 5 %. Range: ≥ 0, ≤ 100 |
years | number | years | yes | Length of the investment in years; fractional years allowed (2.5 = 30 months). Range: > 0, ≤ 200 |
compounding_frequency | enum: annually | semiannually | quarterly | monthly | weekly | daily | default monthly | How often interest is credited: n = 1, 2, 4, 12, 52 or 365 periods per year. | |
monthly_contribution | number | default 0 | Optional fixed deposit made at the end of every month, compounded at the effective monthly rate implied by compounding_frequency. Range: ≥ 0, ≤ 1000000000 |
Outputs
| Output | Type | Unit | Description |
|---|---|---|---|
final_balance | number | Principal, contributions and all compounded interest at the end of the term. | |
total_contributions | number | Principal plus all monthly deposits (money paid in). | |
total_interest | number | final_balance − total_contributions. | |
effective_annual_rate_percent | number | % | (1 + r/n)^n − 1: the yield actually earned per year at this compounding frequency. |
growth_multiple | number | final_balance / total_contributions. |
Example
10,000 at 5 % compounded monthly for 10 years: {"principal":10000,"annual_rate_percent":5,"years":10,"compounding_frequency":"monthly"} → {"final_balance":16470.09,"total_contributions":10000,"total_interest":6470.09,"effective_annual_rate_percent":5.1162,"growth_multiple":1.647}
5,000 plus 100/month at 6 % monthly for 20 years: {"principal":5000,"annual_rate_percent":6,"years":20,"compounding_frequency":"monthly","monthly_contribution":100} → {"final_balance":62755.11,"total_contributions":29000,"total_interest":33755.11}
GET https://tttkmbb.com/api/v1/calculate/compound-interest?principal=10000&annual_rate_percent=5&years=10&compounding_frequency=monthly
Machine access
- API:
GET https://tttkmbb.com/api/v1/calculate/compound-interest(query parameters) orPOSTwith a JSON body{"inputs": {...}} - Schema: https://tttkmbb.com/api/v1/calculators/compound-interest · Markdown: https://tttkmbb.com/finance/compound-interest.md · JSON definition: https://tttkmbb.com/finance/compound-interest.json
- MCP: server
https://tttkmbb.com/mcp, toolcalculate_compound_interest - OpenAPI operationId:
calculate_compound_interest - Freshness:
static. Authentication: none. Rate limit: fair use (see rate limits).
Sources
- Investopedia – Compound Interest: Formula and Examples (reference)
- Wikipedia – Compound interest (reference)
FAQ
Does the compounding frequency matter much?
Less than the rate and the time. 5 % compounded annually yields 5.00 %, monthly 5.116 %, daily 5.127 % per year; the effective_annual_rate_percent output shows the difference.
Are contributions made at the start or the end of the month?
At the end of each month (ordinary annuity). Start-of-month deposits would earn one extra month of interest, i.e. FV_contrib × (1 + i_m); use future-value with payment_timing=beginning for that.
Is the rate an APR or an APY?
annual_rate_percent is the nominal APR that is divided by the number of compounding periods. If you only know the APY, enter it with compounding_frequency=annually.
Related calculators
- Savings Goal Calculator — Solve for the monthly deposit needed to reach a target balance.
- APY Calculator — Convert the nominal APR into the effective annual yield.
- Simple Interest Calculator — Interest without compounding, for comparison.