The net present value formula and its parts
Net present value is the sum of every cash flow's present value, with money paid out counted as negative; OpenStax defines it as the present value of the inflows minus the present value of the outflows.[1]
| Symbol | Meaning | In the example |
|---|---|---|
| C0 | Cost paid today (year 0), not discounted | $40,000 |
| CFt | Net cash flow at the end of period t (negative for a later outlay) | $8,000 … $14,500 |
| r | Discount rate per period: your required return or cost of capital | 0.08 |
| t, n | Period number, and the last period | 1 … 5 |
| 1 ÷ (1 + r)t | Discount factor: today's value of $1 received at t | 0.9259 … 0.6806 |
A positive NPV means the cash flows return more than r; zero means exactly r; negative means less. The rate that makes NPV zero is the internal rate of return, which the IRR calculator finds.[3]
How to calculate NPV by hand
To calculate NPV, divide each cash flow by (1 + r) raised to its period, add the results and subtract the initial cost. Microsoft's second NPV example, worked line by line:[4]
| Year | Cash flow | Divide by 1.08t | Present value | Running total |
|---|---|---|---|---|
| 0 | −$40,000.00 | 1 (today) | −$40,000.00 | −$40,000.00 |
| 1 | $8,000.00 | 1.080000 | $7,407.41 | −$32,592.59 |
| 2 | $9,200.00 | 1.166400 | $7,887.52 | −$24,705.08 |
| 3 | $10,000.00 | 1.259712 | $7,938.32 | −$16,766.75 |
| 4 | $12,000.00 | 1.360489 | $8,820.36 | −$7,946.39 |
| 5 | $14,500.00 | 1.469328 | $9,868.46 | $1,922.06 |
The five present values add up to $41,922.06, so NPV = $41,922.06 − $40,000 = $1,922.06, the same $1,922.06 Excel prints. Add a $9,000 loss in year 6 and the NPV drops to −$3,749.47, because that outlay is worth $5,671.53 today.[4]
The rate matters as much as the cash flows. The same project at other discount rates:
| Discount rate | NPV |
|---|---|
| 4% | $7,263.78 |
| 6% | $4,471.70 |
| 8% | $1,922.06 |
| 10% | −$411.30 |
| 12% | −$2,551.25 |
NPV formula in Excel and Google Sheets
Excel's NPV function assumes its first value arrives one period from now, so the year-0 cost goes outside the function: =NPV(8%, B2:B6) + B1, where B1 holds −40,000.[4] Putting B1 inside the range discounts the cost by a year and returns $1,779.69 instead of $1,922.06.
When the first cash flow really is a year away, keep it inside. Microsoft's first example pays $10,000 one year from today and receives $3,000, $4,200 and $6,800 in the next three years; at 10%, =NPV(10%, -10000, 3000, 4200, 6800) = $1,188.44.[4]
| Function | Use it when | Timing it assumes |
|---|---|---|
NPV(rate, values) | Equal periods (years, months) | First value one period from now; add the cost today separately |
XNPV(rate, values, dates) | Cash flows on irregular dates | First value on the first date (today); others discounted by days ÷ 365 |
PV(rate, nper, pmt) | The same payment every period | End or start of each period |
XNPV discounts each cash flow by (1 + r)(di − d1)/365. For Microsoft's $10,000 investment with returns on days 60, 303, 411 and 456, =XNPV(0.09, values, dates) = $2,086.65.[5] Google Sheets has the same three functions with the same arguments.
NPV of an annuity: the shortcut for equal cash flows
When every cash flow is the same, the sum collapses to the present value of an annuity:[2]
A $20,000 machine that saves $5,000 a year for 6 years at 7%: the annuity factor is 4.7665, so NPV = −20,000 + 5,000 × 4.7665 = $3,832.70, the same as adding the six discounted values one by one. The present value calculator handles annuities, with payments at the start or end of each period.
Mistakes that skew NPVDiscounting the year-0 cost. Using an annual rate on monthly cash flows (convert it: (1 + r)1/12 − 1). Counting money already spent (sunk cost). Leaving out a later outlay such as a replacement or a balloon payment. Comparing projects of different sizes by IRR instead of NPV.
Calculators that use the NPV formula
Run your own cash flows through the NPV calculator, which adds IRR, MIRR, the profitability index and discounted payback. The IRR calculator handles monthly and dated cash flows, and the TVM calculator solves for any one of N, rate, PV, payment or FV.
- NPV calculatorNet present value, IRR, MIRR and payback of yearly cash flows
- IRR calculatorInternal rate of return for yearly, monthly or dated cash flows, with XIRR and MIRR
- Present value calculatorWhat a future sum or payment stream is worth today
- Time value of money (TVM) calculatorSolve N, I/Y, PV, PMT or FV like a financial calculator
Frequently asked questions
What is the net present value formula?
NPV = −C0 + CF1/(1 + r) + CF2/(1 + r)2 + … + CFn/(1 + r)n, where C0 is the cost today, CFt the cash flow in period t and r the discount rate.
How do you calculate NPV in Excel?
Use =NPV(rate, year 1 … year n) + year-0 value, with the year-0 cost entered as a negative number. $40,000 returning $8,000 to $14,500 at 8% gives $1,922.06.
What is the difference between NPV and XNPV?
NPV assumes equal periods and starts one period from now. XNPV takes a date for each cash flow, starts on the first date and discounts by the number of days over 365.
Is a higher NPV always better?
Between projects of similar risk, yes: NPV is the dollar value a project adds at your required return. For riskier cash flows, use a higher discount rate rather than a lower NPV threshold.