# XNPV

financial · from excel · excel: not yet compared · sheets: not yet compared

returns net present value for irregular cash flows

## signature

```
XNPV(rate, values, dates)
```

returns: `number`

## arguments

- rate: number: required
- values: range: required
- dates: range: required

## examples

formula and result, asserted in the engine test suite.

| formula | result | with |
| --- | --- | --- |
| `=XNPV(0.09, A1:A5, B1:B5)` | `149.81126223483471` | A1=10, A2=20, A3=30, A4=40, A5=50, B1=2, B2=4, B3=6, B4=8, B5=10 |

## errors

error values observed from the engine: each with a call that produces it.

| error | produced by |
| --- | --- |
| `#NUM!` | `=XNPV(0.05, A1:A3, DATE(2026,1,15))` |

## related

- [ACCRINT](https://deepcalc.com/docs/functions/accrint.md): accrued interest for a security paying periodic interest
- [ACCRINTM](https://deepcalc.com/docs/functions/accrintm.md): accrued interest for a security paying at maturity
- [AMORDEGRC](https://deepcalc.com/docs/functions/amordegrc.md): depreciation per period, French accounting, degressive
- [AMORLINC](https://deepcalc.com/docs/functions/amorlinc.md): depreciation per period, French accounting, linear
- [COUPDAYBS](https://deepcalc.com/docs/functions/coupdaybs.md): days from coupon period start to settlement
- [COUPDAYS](https://deepcalc.com/docs/functions/coupdays.md): days in the coupon period containing settlement
- [COUPDAYSNC](https://deepcalc.com/docs/functions/coupdaysnc.md): days from settlement to the next coupon date
- [COUPNCD](https://deepcalc.com/docs/functions/coupncd.md): next coupon date after settlement

## navigate

- [all financial functions](https://deepcalc.com/docs/functions/financial-functions.md)
- [function index](https://deepcalc.com/docs/functions.md): all 602 functions
- [error values](https://deepcalc.com/docs/errors.md) · [concepts](https://deepcalc.com/docs/concepts.md) · [limits](https://deepcalc.com/docs/limits.md)
- [everything in one file](https://deepcalc.com/llms-full.txt)

source: https://deepcalc.com/docs/functions/xnpv