XIRR Calculator

Measure the real annualized return on an investment funded by deposits and withdrawals on different dates. Add each dated cash flow, then press Calculate to get the XIRR.

Written by TopicDrill Editorial Team·Updated June 2026

Share this calculator

Your cash flows

Use negative amounts for money you put in and positive amounts for money you take out.

$
$
$
$

Annualized XIRR

10.47%

over 1095 days (3.0 years)

Total invested$20,000
Total received$26,000
Net gain$6,000

Cumulative cash position

Running net
$-20.0k$-13.5k$-7.0k$-500$6.0kJan 21Jul 21Jan 22Jan 24

Advertisement

How the XIRR calculator works

XIRR answers a question a simple percentage cannot: when you fund an investment with several deposits and pull money out at different times, what single yearly rate ties the whole story together? The tool treats every line you enter as a dated cash flow and finds the rate at which all of them, discounted back to the first date, cancel out to zero.

Because the timing of each flow is built into the math, a dollar invested early counts more than a dollar invested late. The cumulative chart below the results traces your running cash position, starting deep in the negative as you invest and climbing above zero once the inflows arrive.

A worked example

Suppose you invest 10,000 dollars at the start of 2021, add 5,000 dollars that July and another 5,000 dollars in January 2022, then redeem the whole holding for 26,000 dollars in January 2024. You put in 20,000 dollars and took out 26,000 dollars, but because the money went in at three different times the plain 30 percent total gain does not describe the yearly rate. The XIRR works out to roughly 14 percent a year, which is the figure you can fairly compare against other investments.

Things to keep in mind

XIRR assumes any returned cash could be reinvested at the same rate, so for very lumpy cash flows treat it as a comparison tool rather than a literal forecast. For the formal definition of internal rate of return, see this overview of IRR. If your contributions are equal and evenly spaced, our future value calculator may be a simpler fit.

Frequently asked questions

What is XIRR and how is it different from CAGR?

XIRR is the extended internal rate of return. It is the single annualized rate that makes the present value of every dated cash flow add up to zero. Unlike CAGR, which only looks at a starting and ending value, XIRR accounts for the exact timing and size of each deposit and withdrawal, so it works when you invest at many different dates.

Why are some amounts negative and others positive?

Money that leaves your pocket and goes into the investment is an outflow, entered as a negative number. Money that comes back to you, such as a redemption, dividend or sale, is an inflow, entered as a positive number. You need at least one negative and one positive amount for a return to exist.

How does this calculator find the XIRR?

It discounts each cash flow back to the first date using an actual divided by 365 day count, then searches for the rate that drives the total to zero. It uses the Newton method first and falls back to a bisection search if needed, so even unusual cash-flow patterns resolve to a stable answer.

Can XIRR be negative or very large?

Yes. If you received back less than you put in, the XIRR is negative. If gains arrived quickly relative to the money invested, the annualized figure can be large. A short holding period magnifies the rate in both directions because the result is always expressed on a yearly basis.

Related guides

View all →

Advertisement