Home›Interest & financial math

Opportunity cost: what if I had invested?

The opportunity cost of an expense is what the same money would be worth if it were invested instead of spent. This calculator shows, for a recurring expense or a one-time purchase, how much it would be worth in the future at the return you type.

That daily coffee, the weekly takeout or a new phone: what would the money have become if it had been invested? Enter the expense, the return and the horizon and see the future value, the part that is return and the equivalent in today’s money.

Educational simulation. Not investment advice. Results are estimates based on the data you enter and do not replace advice from a qualified professional.

Updated on Dec 1, 2026

Illustrative example: a $4 coffee, 20 times a month, for 10 years, at a 6% yearly return and 3% yearly inflation. Replace it with your own expense, the return you want to test and the horizon.

One-click examples (illustrative)
The expense
If the money had been invested
Compare with other expenses (optional)Other expenses, one per line: expense, amount each time and times per month.

Type in a cell: Tab moves on, Enter goes down, arrows move; paste several rows from Excel (Ctrl+V).

The return is typed and constant, with no tax or fees; contributions are made at the end of each month. For a one-time purchase, the amount is invested today and, in the list, “Times per month” becomes the quantity bought. Want the real rate? See the real interest rate.

Your inputs stay only on this browser and are not sent anywhere. Untick to delete them.

—What you would have if you invested
—

Educational estimate with the return and inflation you type. Not a promise of returns nor a recommendation to invest or to cut an expense.

What you spent × what investing would give

Year by year: the cumulative spending against the value of the same money invested at the return you typed. The dashed line is the invested value in today’s money, after inflation.

Tap the chart to see the values.

The effect of cutting part of the expense

What you would build by investing only the part you cut: 25%, 50% or 100% of the expense. Each bar adds the money kept and the return.

Tap the chart to see the values.

Where the final value comes from

How much of the future value is the money you did not spend and how much is return.

Tap the chart to see the values.

Year-by-year workings

Understand why

Two articles show the same effect with example numbers: how small amounts, repeated, and the time invested change the result.

Next step

Take this page’s results to another calculator with the fields already filled in.

The summary lists your inputs, results, formulas, assumptions and sources. The full report also includes the charts and interpretations, in color. In the print dialog, choose Save as PDF.

Method, assumptions and sources

Formulas

Monthly deposit = amount of each expense × times per month (a week counts as 52 ÷ 12 per month), with yearly increase (1 + increase)^(year − 1)
Monthly rate = (1 + yearly return)^(1/12) − 1; future value = Σ deposit in month m × (1 + monthly rate)^(N − m), N = 12 × years (deposits at the end of the month)
One-time purchase: future value = amount × (1 + yearly return)^years; return = future value − total spent
Today’s money = future value ÷ (1 + yearly inflation)^years; cutting p% of the expense builds p% of the future value

Assumptions and limits

  • Return and inflation are constant and typed by you; the calculator looks up no tables. Nominal values, except where marked “today’s money”.
  • No tax, fees or market risk. The result shows what could have been, not a promise. The example numbers are illustrative.

Official sources and references

  • Brealey, R.; Myers, S.; Allen, F. Principles of Corporate Finance. McGraw-Hill (future value, annuities and present value)

Frequently asked questions

What is the opportunity cost of an expense?

It is what you give up by spending instead of investing. In the example, a $4 coffee, 20 times a month, for 10 years adds up to $9,600 spent; invested at 6% a year, it becomes $12,998. The $3,398 difference is the return the expense did not earn.

How much would I have if I invested my coffee money every month?

With $80 a month ($4 × 20), deposited at the end of each month at 6% a year, you would have about $12,998 in 10 years. The rate is an example: type the one you want to test. At 3% a year the result falls, and the calculator shows the difference right away.

What does the value in today’s money mean?

It is the future value divided by the inflation over the period: $12,998 ÷ 1.03^10 = $9,672, the equivalent purchasing power today. It shows that part of the growth only offsets rising prices. It is optional: leave inflation at zero to ignore it.

What does a one-time purchase, like a phone, really cost?

Choose “One-time purchase”. A $900 phone invested for 10 years at 6% a year would become $1,612 (1.79 times), or about $1,199 in today’s money. That does not mean the purchase is wrong: it is the full price of choosing to spend now.

Is it worth cutting 100% of an expense?

It depends on what it brings you. The calculator shows the effect of cutting 25%, 50% and 100%: in the example, 25% alone would build $3,249 in 10 years. Cutting part and keeping what you enjoy is usually more sustainable than cutting everything.

Is the typed return guaranteed?

No. The rate is constant and typed by you, with no tax or fees, and actual returns vary. Use conservative rates to test. The calculator does not recommend any investment or product and makes no market forecast.

How is this different from compound interest, the rule of 72 and CAGR?

Here the starting point is an everyday expense, turned into monthly deposits, with the future value per unit and a comparison between expenses. The compound interest calculator starts from an amount and a deposit; the rule of 72 shows the time to double; CAGR measures the growth of a value already observed.

Opportunity cost: what an expense is worth if it is invested

Opportunity cost is what you give up by choosing one thing over another. For an everyday expense, it is what the same money would be worth if it were invested: small amounts, repeated for years, plus the return on them, add up to more than they seem.

Illustrative example

A $4 coffee, 20 times a month, is $80 a month and $9,600 over 10 years. Invested at the end of each month at 6% a year, that money would become about $12,998, of which $3,398 is return. With 3% yearly inflation, that equals about $9,672 in today’s money. Each $4 spent today would be worth $7.16 in 10 years (1.79 times).

Share of the expense cutBuilt in 10 years
25%$3,249
50%$6,499
100%$12,998

How to use the result

Use the math to choose, not to scold yourself: see which expenses are worth the pleasure and which are automatic habit, and compare several in the list. Cutting part of an expense is usually more realistic than cutting all of it. To test horizons and rates, see compound interest; to learn how long money takes to double, the rule of 72.

What the math does not do

The return is typed and constant, with no tax or fees, and is not a promise. The calculator does not say you should cut an expense nor recommend an investment. The example numbers are illustrative.