What XIRR measures and why dates matter
XIRR answers one question: what constant annual rate, compounded continuously through the calendar, would have turned your actual payments into your actual receipts? It is a money-weighted return, which means a dollar invested for three years counts three times as heavily as a dollar invested for one year.
That weighting is exactly what ordinary IRR cannot do. IRR assumes every cash flow lands at a regular interval — end of year 1, end of year 2, and so on. Real accounts do not behave that way. You top up a brokerage account in February, sell part of a holding in September, get a dividend in December. Feeding those into a periodic IRR forces you to pretend they all happened at period ends, and the error grows with how uneven the timing is.
The convention this calculator follows is Excel's: the exponent for each flow is the actual number of days since the first flow, divided by 365. Leap years are not treated specially — 366 real days simply produce an exponent of 366/365. That is a simplification, and it is the one every spreadsheet, portfolio system and fund administrator you will ever compare against also makes, which is worth far more than a marginally more accurate day count nobody else uses.
How the equation is solved
The defining equation sets net present value to zero. Each cash flow is divided by (1 + r) raised to the number of years, fractional, that separate it from the first flow. Because r appears in a fractional exponent in several terms at once, there is no algebraic solution for anything beyond two cash flows; the rate has to be found numerically.
This calculator brackets the answer between −99.99% and +10,000% and bisects until the present value is essentially zero. Bisection is slower than the Newton iteration Excel uses, but it cannot diverge and it does not need a starting guess, which is why an initial guess field is not offered here. If no rate in that very wide bracket works, the calculator says so rather than returning a plausible-looking wrong number.
Two conditions must hold for a solution to exist at all. First, at least one flow must be negative and at least one positive; a list of payments with no receipts has no rate of return. Second, the flows must not all share a single date, because annualizing across zero elapsed time is undefined. When cash flows change sign more than once — you invest, withdraw everything, then invest again — the polynomial can have several real roots, and the calculator flags that rather than pretending its answer is unique. The modified IRR is the standard escape from multiple roots because it collapses the problem to a single sign change by construction.
Worked example: a staggered $15,000 investment
You put $10,000 into a private deal on 15 January 2023, add $5,000 on 1 June 2023, take a $2,000 distribution on 20 February 2024, another $3,000 on 5 November 2024, and receive $12,000 on final exit on 30 September 2025. Those are the calculator's defaults.
- Convert dates to day counts from the first flow. 15 Jan 2023 is day 0. 1 Jun 2023 is 137 days later (16 remaining days of January + 28 + 31 + 30 + 31 + 1). 20 Feb 2024 is day 401. 5 Nov 2024 is day 660. 30 Sep 2025 is day 989.
- Write the equation. −10,000 − 5,000/(1+r)137/365 + 2,000/(1+r)401/365 + 3,000/(1+r)660/365 + 12,000/(1+r)989/365 = 0.
- Bracket and bisect. At r = 0 the left side is 15,000 paid in against 17,000 received, so the expression is +2,000 — positive. At r = 50% the discounting is severe enough to drive it negative. The root therefore lies between them.
- Read the answer. The solver returns roughly 5.8% a year. The result panel above shows the exact figure, and the schedule table shows each flow's discount factor and present value; those present values sum to zero, which is the definition being satisfied.
- Compare with the simple return. Net gain is 17,000 − 15,000 = $2,000 on $15,000 paid in, or 13.33%. Spread across a holding period of 989 days — 2.71 years — a simple 13.33% is consistent with a single-digit annual rate. Whenever the annualized figure and the simple figure disagree in that direction, the money was invested for longer than a year.
How to read your XIRR
Compare XIRR against the return you could have got elsewhere over the same period, not against a headline index number. Because XIRR is money-weighted, it rewards you for having had more capital deployed when returns were good — which is partly skill and partly luck of timing. A fund manager is normally judged on a time-weighted return instead, precisely because they do not control when investors add money.
Three sanity checks catch most errors. First, the sign: if net gain is positive over a period longer than a day, XIRR must be positive too, and if it is not you have a date entered wrongly. Second, the magnitude: for holding periods under a month, annualizing multiplies a small percentage into a large one, and a 2% gain over 10 days annualizes to over 100% without meaning anything. Third, the direction against simple return: over a period longer than a year the annualized rate should be smaller in magnitude than the simple return, and over a period shorter than a year it should be larger. Both statements follow from compounding and hold for gains and losses alike.
For a project appraisal rather than a portfolio, remember that a rate on its own decides nothing. Pair XIRR with net present value at your actual cost of capital, and with the profitability index if your capital budget is constrained.
What a given total gain annualizes to, by holding period
| Total gain | 90 days | 182 days | 365 days | 730 days | 1,825 days |
|---|---|---|---|---|---|
| +5% | 21.88% | 10.28% | 5.00% | 2.47% | 0.98% |
| +10% | 47.19% | 21.06% | 10.00% | 4.88% | 1.92% |
| +25% | 147.18% | 56.44% | 25.00% | 11.80% | 4.56% |
| +50% | 417.67% | 125.49% | 50.00% | 22.47% | 8.45% |
| −10% | −34.77% | −19.05% | −10.00% | −5.13% | −2.09% |
| −25% | −68.86% | −43.83% | −25.00% | −13.40% | −5.59% |
Read across a row to see how the same total gain looks under annualization. The 365-day column always equals the total gain, which is the check that the table is right.
Mistakes that produce a wrong XIRR
- Getting the signs the wrong way round. Money leaving your pocket is negative. If every amount is positive there is no solution, and if you flip all of them the rate is unchanged — which means a consistent sign flip hides the error rather than exposing it.
- Forgetting the closing value. For a position you still hold, the last row must be today's date with today's market value as a positive amount. Omit it and XIRR reports the return on a position you have implicitly written down to zero.
- Annualizing a very short period. Two weeks of results tell you almost nothing about an annual rate. Read the simple return for short holds.
- Comparing XIRR to a fund's published return. Published fund returns are time-weighted and deliberately strip out the effect of investor timing. Your XIRR and the fund's stated return will differ whenever you added or withdrew money, and neither is wrong.
- Assuming a unique answer when signs alternate. Invest, fully exit, reinvest, exit again, and the equation can have more than one root. The calculator warns when this is possible.
- Entering dates in a local format. Use YYYY-MM-DD. 03-04-2024 is ambiguous and this calculator will not guess.
XIRR, IRR and time-weighted return
Three return measures get confused with each other constantly. IRR solves the same zero-NPV equation but on evenly spaced periods; it is the right tool for a project modelled in annual or quarterly columns. XIRR is IRR with real dates, and reduces to IRR exactly when the dates happen to be a year apart. Time-weighted return chains sub-period returns together and is deliberately insensitive to the size and timing of contributions, which is why it is the standard for reporting manager performance under the Global Investment Performance Standards.
Use XIRR when you want to know what you earned, IRR when the cash flows are genuinely periodic, and a time-weighted return when you want to judge an investment decision independently of when you funded it. For a project that also needs a payback answer, pair this with discounted payback; when the reinvestment assumption embedded in IRR is doing too much work, the MIRR makes it explicit. And if you are appraising a corporate project rather than a portfolio, the rate you compare against should be your weighted average cost of capital.
Why the day count is 365 and not 365.25
Excel's XIRR divides actual elapsed days by a fixed 365, and every mainstream implementation copies it. Over a two-year span containing one leap day, that convention treats 731 days as 2.0027 years rather than 2.0000, which shifts the reported rate by a few thousandths of a percentage point. It is a real approximation, but changing it would make your result disagree with every spreadsheet anyone checks it against, so this calculator keeps the convention and names it.
