# NPV Calculator

> Discounts a series of end-of-period cash flows at a required rate of return, subtracts the initial investment and reports the net present value, the present value of each cash flow and the profitability index.

- Calculator id: `npv` · Category: Finance (`finance`) · Tool name: `calculate_npv`
- Canonical page: https://tttkmbb.com/finance/npv · This document: https://tttkmbb.com/finance/npv.md · JSON definition: https://tttkmbb.com/finance/npv.json

## Purpose

Discounts a series of end-of-period cash flows at a required rate of return, subtracts the initial investment and reports the net present value, the present value of each cash flow and the profitability index.

**Use when:** You are appraising a project or investment with an upfront cost followed by periodic cash flows and want to know whether it creates value at a given discount rate.

**Do not use when:** You want the rate that makes NPV zero (use irr), the time to recover the outlay (use payback-period), or a single future amount (use present-value).

## Input

| Parameter | Type | Unit | Required | Description |
| --- | --- | --- | --- | --- |
| `discount_rate_percent` | number | % per period | required | Required rate of return or cost of capital per period in percent (annual for yearly cash flows). (min -99, max 1000) |
| `initial_investment` | number |  | required | Outlay at time 0, entered as a positive number. (min 0, max 1000000000000000) |
| `cash_flows` | number_list |  | required | Net cash flow at the end of periods 1, 2, 3 … (negative values allowed). |

## Output

| Field | Type | Unit | Description |
| --- | --- | --- | --- |
| `npv` | number |  | Σ CF_t / (1 + r)^t − initial_investment. |
| `present_value_of_cash_flows` | number |  | Σ CF_t / (1 + r)^t (before subtracting the investment). |
| `profitability_index` | number |  | present_value_of_cash_flows / initial_investment (only when the investment is > 0); above 1 means NPV > 0. |
| `discounted_cash_flows` | number_list |  | Each CF_t / (1 + r)^t in order. |
| `total_undiscounted_cash_flows` | number |  | Σ CF_t without discounting. |
| `net_undiscounted_gain` | number |  | Σ CF_t − initial_investment (NPV at 0 %). |
| `decision` | string |  | 'Accept' when NPV > 0, 'Reject' when NPV < 0, 'Indifferent' at 0. |

## Formula

`NPV = −initial_investment + Σ_{t=1..n} cash_flows[t] / (1 + discount_rate_percent/100)^t; profitability_index = (NPV + initial_investment) / initial_investment`

Cash flows occur at the end of each period and the rate is constant; the period of the rate must match the period of the cash flows (annual rate with annual flows).

## Data Sources

- Investopedia – Net Present Value (NPV): What It Means and Steps to Calculate It — https://www.investopedia.com/terms/n/npv.asp (reference, retrieved 2026-09-24)
- Wikipedia – Net present value — https://en.wikipedia.org/wiki/Net_present_value (reference, retrieved 2026-09-24)

Data freshness: `static`. Deterministic formula with fixed constants; results never go stale. Inputs supplied by the caller determine the output.

## API

- `GET https://tttkmbb.com/api/v1/calculate/npv?discount_rate_percent=…&initial_investment=…&cash_flows=…`
- `POST https://tttkmbb.com/api/v1/calculate/npv` with JSON body `{"inputs": {…}}`
- Response: unified envelope (`success`, `request`, `result.values`, `result.units`, `sources`, `freshness`, `timestamp`, `next_actions`, `links`); see https://tttkmbb.com/docs/response-format.md
- Schema: https://tttkmbb.com/api/v1/calculators/npv · OpenAPI operationId `calculate_npv` in https://tttkmbb.com/openapi.json
- Authentication: none. Rate limit: fair use, see https://tttkmbb.com/docs/rate-limits.md.

## MCP

- Server: `https://tttkmbb.com/mcp` (Streamable HTTP, JSON-RPC 2.0, no auth)
- Tool:  `run_calculator` with `{"calculator_id": "npv", "inputs": {…}}`

## Example

- −1,000 then 500, 400, 300 at 10 %: inputs `{"discount_rate_percent":10,"initial_investment":1000,"cash_flows":[500,400,300]}` → `{"npv":10.52,"present_value_of_cash_flows":1010.52,"profitability_index":1.0105,"discounted_cash_flows":[454.55,330.58,225.39],"total_undiscounted_cash_flows":1200,"net_undiscounted_gain":200,"decision":"Accept (NPV > 0)"}`
- −10,000 then 3,000, 4,000, 5,000, 2,000 at 8 %: inputs `{"discount_rate_percent":8,"initial_investment":10000,"cash_flows":[3000,4000,5000,2000]}` → `{"npv":1646.35,"present_value_of_cash_flows":11646.35,"profitability_index":1.1646,"decision":"Accept (NPV > 0)"}`

```
GET https://tttkmbb.com/api/v1/calculate/npv?discount_rate_percent=10&initial_investment=1000&cash_flows=500%2C400%2C300
```

## Limitations

You want the rate that makes NPV zero (use irr), the time to recover the outlay (use payback-period), or a single future amount (use present-value). Cash flows occur at the end of each period and the rate is constant; the period of the rate must match the period of the cash flows (annual rate with annual flows). All values are computed from the formula above; no measurement or live data is involved.

## FAQ

**Which discount rate should I use?**

The return available on an alternative of similar risk: a company's weighted average cost of capital for projects, or a hurdle rate. A higher rate lowers NPV.

**How do I handle monthly cash flows?**

Use a monthly rate: annual_rate/12 for a nominal rate, or (1 + annual)^(1/12) − 1 for an effective one, and list one cash flow per month.

## Related

- [IRR Calculator](https://tttkmbb.com/finance/irr.md) — Rate of return that sets NPV to zero.
- [Payback Period Calculator](https://tttkmbb.com/finance/payback-period.md) — Time to recover the initial investment.
- [Present Value Calculator](https://tttkmbb.com/finance/present-value.md) — Discount a single amount.
