Return on investment (ROI) is a percentage that measures the gain or loss generated by an investment relative to its cost, calculated as (Net Profit ÷ Cost of Investment) × 100. A positive ROI means the investment earned more than it cost, while a negative ROI means it lost money. ROI is widely used in finance, marketing, and business planning because it reduces any investment to a single comparable number, whether you spent $500 on a stock or $50,000 on a piece of equipment. The metric's simplicity is also its biggest strength: with just two inputs, the initial cost and the final value, you can judge whether a decision was profitable in seconds.

Below we walk through the ROI formula, the exact steps to calculate it, a worked numeric example, and the difference between simple ROI and annualized ROI. We also explain when ROI can mislead you, and link to a free ROI Calculator that produces the result automatically.

how to calculate roi
how to calculate roi

The ROI Formula

The basic ROI formula has three equivalent forms, all producing the same percentage:

  • ROI = [(Final Value − Initial Cost) ÷ Initial Cost] × 100
  • ROI = [(Gain − Cost) ÷ Cost] × 100
  • ROI = [Net Profit ÷ Investment] × 100

Each version expresses the same idea: how much you earned (or lost) per dollar invested. The "gain" or "net profit" must include all costs and all proceeds tied to the investment, not just the headline price change. For a rental property, for example, net profit should factor in closing costs, repairs, and rental income received. For a stock, it should include dividends and any commissions you paid.

How to Calculate ROI Step by Step

The full calculation takes only a moment once your two input numbers are ready. Follow these steps for any investment, business project, or marketing campaign:

  1. Enter the initial cost — the total amount of money you put in, in dollars. Include every expense tied to the investment, not only the purchase price.
  2. Enter the final value — what the investment is worth now, or what you sold or liquidated it for. Use the actual cash you would receive, not an estimated market price.
  3. Read the ROI percentage and net profit instantly — the result tells you the percentage return on every dollar you invested.
  4. Optionally add a holding period in years — this also shows the annualized ROI (CAGR), which is essential when comparing investments held for different lengths of time.
  5. Compare to a benchmark — pit the ROI against the return you would have earned elsewhere, such as an index fund or a savings account, to judge whether the risk was worth it.

You can run the full calculation manually or skip the arithmetic with the ROI Calculator, which also surfaces net profit and annualized ROI in the same view.

A Worked Example Using the Formula

Suppose you bought 100 shares of a stock at $50 per share, paid a $10 commission, and sold them one year later at $65 per share with another $10 commission. The numbers break down as follows:

  • Initial cost: (100 × $50) + $10 = $5,010
  • Final value: (100 × $65) − $10 = $6,490
  • Net profit: $6,490 − $5,010 = $1,480
  • ROI: ($1,480 ÷ $5,010) × 100 ≈ 29.5%

Reading the result: every dollar invested produced roughly 29.5 cents of profit, before taxes. Because the holding period was one year, the annualized ROI equals the simple ROI in this case. Holding the same investment for three years at a 29.5% total ROI would correspond to a much lower annualized rate, which is why CAGR is the right metric whenever timeframes differ.

Simple ROI vs. Annualized ROI (CAGR)

Simple ROI ignores time. An investment that returns 30% in one year is fundamentally different from one that returns 30% over ten years, yet the basic ROI formula gives them the same score. Annualized ROI, also called the compound annual growth rate (CAGR), solves this by smoothing the return into an equivalent yearly rate.

The CAGR formula is: [(Final Value ÷ Initial Cost)^(1 ÷ Years) − 1] × 100. Using the stock example above, if you held the position for three years instead of one, the 29.5% total ROI would translate to roughly 9% annualized, a far less impressive number once time is factored in. Investors use CAGR to compare assets with different holding periods, and it is also the metric most financial planners quote when they discuss long-term returns.

When ROI Can Mislead You

ROI is a starting point, not a complete answer. Several factors are invisible to the percentage:

  • Risk — a 25% ROI from a volatile small-cap stock is not equivalent to a 25% ROI from a government bond.
  • Time — comparing a 10% six-month return against a 10% five-year return favors the wrong investment.
  • Cash flow timing — ROI assumes the initial cost is paid up front and the final value is collected at the end, with nothing in between.
  • Taxes and fees — commissions, capital gains tax, and management fees all reduce the real return but are often left out.
  • Opportunity cost — ROI does not measure what else you could have done with the money.

For a fuller picture, pair ROI with metrics such as internal rate of return (IRR), net present value (NPV), or payback period. For related day-to-day calculations, the Savings Calculator shows how regular deposits grow over time, and the Compound Interest Calculator lets you isolate the impact of compounding frequency on a lump sum. Both tools are useful when you want to benchmark an investment's ROI against what a passive savings strategy would have produced.

Common Use Cases for ROI

Although ROI started in corporate finance, it now shows up across many personal and professional decisions. The table below summarizes the most common situations where the metric is applied.

Use Case Typical Inputs What ROI Tells You
Stock or ETF investment Purchase price plus commissions, sale price, dividends received Total percentage gain on the position
Real estate rental Down payment, closing costs, repairs, rental income, sale price Profitability of a property over its full holding period
Marketing campaign Campaign cost, revenue attributed to the campaign Whether the campaign produced more revenue than it consumed
Business project Project budget, projected vs. actual financial return Whether the project met its profitability target
Education or training Tuition, time cost, salary increase attributable to the credential Long-term financial payoff of upskilling

In each case, the ROI is a quick screening tool. A negative or very low ROI suggests the decision should be revisited, while a strong positive ROI earns deeper analysis using the complementary metrics mentioned above.

Tips for Accurate ROI Calculations

Small accounting choices have an outsized effect on the final percentage. Keep these habits in mind for trustworthy numbers:

  • Include every cost — fees, taxes, commissions, and maintenance all count toward the investment basis.
  • Use realized values, not estimates — base the final number on cash you have actually received or can verify.
  • Always state the holding period — quote both the simple ROI and the annualized rate when comparing investments.
  • Be consistent across comparisons — calculate ROI the same way for every option, or the comparison is invalid.
  • Document your assumptions — write down which costs and proceeds you included so the number can be reproduced later.

If you also want to size up a future purchase, the Home Affordability Calculator applies the 28/36 rule to estimate the maximum home price you can afford. Pairing that figure with an ROI estimate on the down payment gives a much clearer view of whether buying makes sense in your situation.

Calculate ROI in moments

Manual ROI is two numbers and a single division, which is fast on its own. For a quick check, open the ROI Calculator, type in the initial cost and final value, and the page returns the ROI percentage, net profit, and (with a holding period) the annualized CAGR. The tool runs entirely in your browser, so no figures are stored or sent anywhere, and you can re-run scenarios as many times as you like.

More on this topic: Calculate Your Mortgage Payment and Total Interest in One Click.