CAGR to XIRR Converter — Annualized Return for Dated Cash Flows
XIRR (extended internal rate of return) is the annualized rate that makes the net present value of all your dated cash flows equal zero: NPV = Σ [CFᵢ / (1 + r)^(dᵢ/365)] = 0. Unlike CAGR, it handles multiple investment dates, SIP contributions, partial withdrawals, and dividend reinvestment. This calculator solves for r using Newton’s method and shows how XIRR compares with a simple CAGR on the same cash flows.
Client-side
Timing-adjusted annualized return
Before you calculate
XIRR (extended internal rate of return) is the annualized rate that makes the net present value of all your dated cash flows equal zero: NPV = Σ [CFᵢ / (1 + r)^(dᵢ/365)] = 0. Unlike CAGR, it handles multiple investment dates, SIP contributions, partial withdrawals, and dividend reinvestment. This calculator solves for r using Newton’s method and shows how XIRR compares with a simple CAGR on the same cash flows.
Best forSIP investments with monthly contributions, portfolios with mid-period top-ups or withdrawals, dividend-reinvestment plans, and any analysis where each cash flow has its own date. Not needed when there is only one initial investment and one final value — use CAGR instead.InputOne dated cash flow per row in the format YYYY-MM-DD, amount. Investments (money out of pocket) are negative; withdrawals and final portfolio value are positive. Minimum: one negative and one positive row.OutputEstimated XIRR as an annualized percentage, net cash flow (sum of all rows), total cash invested, number of rows, and a side-by-side CAGR estimate for comparison.
Three things XIRR does that CAGR cannot
XIRR's power comes from discounting every cash flow to its actual date — a calculation that CAGR structurally cannot perform.
Newton's method
XIRR solves iteratively, not algebraically
There is no closed-form solution for r in Σ[CFᵢ/(1+r)^(dᵢ/365)] = 0 when there are more than two cash flows. XIRR starts with a guess (10%), evaluates the NPV, adjusts r up or down, and repeats until |NPV| < 0.0001. This typically converges in 20–50 iterations. The same algorithm runs inside Excel's =XIRR() function.
SIP timing effect
Why SIP investors see XIRR below fund CAGR
Suppose a fund returns 15%/yr CAGR. A SIP investor contributes $500/month for 5 years (60 contributions). The last $500 installment has only 1 month to compound; the first has 60 months. The average time in the market per dollar is roughly 30 months — far less than 60. So the investor's XIRR will be well below 15%/yr unless all contributions hit at the bottom of a rally.
Sign convention
Negative = money out, positive = money in — always
Every cash flow must follow the investor's perspective. You invest (cash leaves) → negative. You receive or your portfolio is worth something (cash value returns to you) → positive. If all entries are the same sign, the NPV equation has no solution. In Excel: =XIRR(values, dates) — the values array must contain at least one negative and one positive number.
When to use XIRR versus CAGR: four concrete situations
Each row shows the inputs, the correct metric, and what the wrong metric would have produced.
Situation
Input
Best next move
Why
Single purchase: $1,000 → $1,750 in 5 years (no interim flows)
BV = $1,000, EV = $1,750, n = 5
Use CAGR = 11.84%/yr ✓
No interim flows. XIRR would give the same result but requires extra date entry — CAGR is simpler and equivalent.
SIP: $500/month for 5 years, final value $38,000
60 dated rows: −$500 each, then +$38,000
Use XIRR → ~12–15%/yr depending on growth path
CAGR on first installment: (38,000/500)^(1/5) − 1 = 133%/yr — meaningless for recurring investment.
$1,000 invested, $500 top-up 17 months later, $1,850 received after 3 years
3 dated rows: −1000, −500, +1850
XIRR = 8.59%/yr ✓
Naïve CAGR = 22.7% ignores the $500 entirely — overstates true return by 14 percentage points.
Partial withdrawal mid-period: invest $2,000, withdraw $500 in Year 2, final value $2,200
3 rows: −2000, +500, +2200
XIRR accounts for the early cash-out
CAGR on $2,000 → $2,200 over 3 years = 3.2%/yr — ignores the $500 already returned in Year 2.
Step-by-step: how to use this calculator correctly
01
Decide the sign convention: money you pay out (investments, top-ups) = negative; money you receive (withdrawals, final portfolio value) = positive. Every row must follow this rule.
02
Enter one row per cash-flow event in the format: YYYY-MM-DD, amount. Rows can be in any order — the calculator sorts by date automatically.
03
Ensure at least one row is negative (cash out) and at least one is positive (cash in). Without both signs, XIRR has no solution to solve for.
04
Enter the most recent portfolio value as a positive amount on today’s date (or the valuation date) — this represents closing out the position.
05
Read the XIRR result as the annualized return adjusted for exactly when each dollar was invested or withdrawn. Compare it with the CAGR estimate to see the impact of timing.
Three cash flows, three years: XIRR = 8.59% vs naïve CAGR = 22.7%
Given
2021-01-01: −1,000 (initial investment) | 2022-06-01: −500 (top-up after 516 days) | 2024-01-01: +1,850 (final portfolio value after 1,096 days)
XIRR = 8.59%/yr. The $500 added on day 516 only had 580 days to compound (1.6 years), so it contributed far less growth per dollar than the original $1,000. CAGR of 22.7% treats the $500 as if it were there from day 0 — overstating the true return by 14 percentage points.
Takeaway
When you add money mid-period, CAGR always overstates the return on the additional capital. XIRR corrects for this by discounting each cash flow to its actual date. The later the top-up, the larger the gap between XIRR and CAGR.
XIRR versus CAGR versus other return metrics: which is correct for your cash flows
XIRR is the only metric that correctly annualizes returns when money enters or leaves on different dates. CAGR is correct for single lump-sum positions. Neither is a substitute for the other.
Method
Best for
Watch for
Example
XIRR
Any investment with multiple dated cash flows: SIP contributions, dividends reinvested, partial withdrawals, top-ups.
Requires at least one negative (invested) and one positive (received) cash flow. All-same-sign inputs have no solution.
Single lump-sum investments: one beginning value, one ending value, one time span.
Wrong for SIPs and recurring investments. For the same cash flows above, naïve CAGR = 22.7% — 14 pp too high.
Index fund NAV: 100 → 280 over 10 years → CAGR = 10.84%/yr (no interim flows, CAGR is correct).
Simple gain / absolute return
Showing how much money you made or lost in total, without annualizing.
Does not adjust for time or timing. A $350 gain in 1 year and a $350 gain in 10 years look identical.
Total invested: $1,500. Final value: $1,850. Net gain = $350 (23.3% absolute return, no annualization).
Time-weighted return (TWR)
Measuring fund manager performance independent of when investors added or withdrew money.
Requires sub-period valuations at every cash-flow date. More data-intensive than XIRR.
A fund returned 15%/yr TWR even though investor XIRR was 9%/yr because they added money just before a down year.
Cash-flow timeline: $1,000 → $500 top-up → $1,850 received
Each bar shows the cash flow on its actual date. XIRR discounts each by (days from first date / 365). The $500 top-up at day 516 has only 580 days left — less than 1.6 years to compound vs the $1,000 which had 1,096 days (3 full years).
2021-01-01-1,000
2022-06-01-500
2024-01-01+1,850
XIRR solver: 4 steps from cash-flow table to annualized rate
Σ[CFᵢ/(1+r)^(dᵢ/365)] = 0. For our example: −1,000/(1+r)^0 + (−500)/(1+r)^1.414 + 1,850/(1+r)^3.003 = 0 → r = 8.59%.
01Parse
Read each (date, amount) row. Convert dates to days elapsed from the earliest date. Our earliest date: 2021-01-01 = day 0.
->02Guess
Start with r = 10%. Compute NPV: −1,000 + (−500)/1.1^1.414 + 1,850/1.1^3.003 = −1,000 − 454 + 1,385 = −69 (negative, so r is too high).
->03Iterate
Newton's method: adjust r down. Try r = 8%: NPV ≈ +12 (positive). Bracket found between 8% and 10%. Continue until |NPV| < 0.0001.
Why timing changes your annualized return: the early vs late contribution effect
Invest $1,000 on Jan 1 of Year 1. If you add $5,000 on Dec 31 of Year 3 (one day before the final valuation), that late $5,000 has only 1 day to grow — almost no contribution to return. Yet naive CAGR would treat it as if $5,000 had compounded for 3 years alongside the original $1,000. XIRR corrects this: it discounts the late $5,000 by only 1 day, so it carries almost zero weight in the return calculation. This is why SIP investors (who invest equal amounts monthly) typically see XIRR significantly below the CAGR of the fund itself: later SIP installments have had less time to compound.
XIRR versus CAGR: when each metric is accurate
CAGR is accurate when there is exactly one beginning value and one ending value with no interim flows. Example: index fund NAV grew from 100 to 280 in 10 years → CAGR = 10.84%/yr. XIRR is accurate when cash flows happen on different dates. Example: SIP of $500/month for 5 years (60 contributions) with final value $38,000 → XIRR might be 12–15%/yr depending on the return path, while CAGR on the first contribution would be (38,000/500)^(1/5) − 1 = 133%/yr — a completely meaningless number for a recurring investment.
Three XIRR input mistakes that cause wrong results or solver failure
XIRR is numerically sensitive. Each mistake below either produces an incorrect rate or prevents the solver from converging.
Watch for
Using the same sign for all cash flows
If all entries are negative (or all positive), NPV = 0 has no solution — the calculator cannot converge. Every real investment has money going out (negative) and value coming back (positive). Add your current portfolio value as a positive entry on today's date.
Watch for
Omitting the final portfolio value
XIRR treats an open position as if it returns zero. If your $1,500 invested is now worth $1,850, add '2024-01-01, +1850' as the closing row. Without it, XIRR will solve for a deeply negative rate (implying you lost everything).
Watch for
Entering the date in the wrong format
The parser requires YYYY-MM-DD (ISO 8601). '01/06/2022' is ambiguous (Jan 6 or Jun 1?). '2022-06-01' is unambiguous: June 1, 2022. Wrong dates change dᵢ/365 and shift the XIRR result by several percentage points.
Keep going
Related calculators and reference guides
Continue with the Statistics hub, compare this result against a related method, or open a guide that covers the same data pattern in more depth.
Why are investment amounts entered as negative numbers?
XIRR follows the cash-flow sign convention used in finance and Excel. Negative = cash leaving your account (you pay it). Positive = cash entering your account (you receive it). A negative entry on 2021-01-01 means you invested on that date. A positive entry on 2024-01-01 means you received that amount. The solver finds the rate where these discounted flows balance to zero.
Is this the same as Excel’s XIRR function?
The formula and logic are identical: both solve Σ[CFᵢ/(1+r)^(dᵢ/365)] = 0 for r. Excel’s XIRR uses Newton’s method with a default guess of 10% and a tolerance of 0.000001. This calculator uses the same approach. Small differences (typically <0.01%) may appear due to rounding in the day-count calculation or solver tolerance.
Can XIRR be negative?
Yes. If the total cash returned is less than the total invested — adjusted for timing — XIRR will be negative. Example: invest $1,000 (2021-01-01) and $500 (2022-01-01), receive only $1,200 (2024-01-01). Net cash flow = −$300. XIRR < 0 because you lost money on a time-value-adjusted basis.
Why do dates matter so much for XIRR?
Each cash flow is discounted by (1+r)^(dᵢ/365). A 1-day difference in a large cash flow changes (1+r)^(dᵢ/365) by a small but non-zero amount. Over many rows, date errors compound. More importantly, the timing of early vs late contributions dramatically shifts the effective annual rate — which is exactly the problem XIRR is designed to capture.
What date should I use for the final portfolio value?
Use the date the valuation was taken. If you are checking your portfolio today (2024-06-05), enter today's date with your current balance as a positive number. This represents hypothetically liquidating the position today. If you actually sold, use the settlement date.
Why might XIRR fail to converge?
Three common causes: (1) All cash flows have the same sign — no IRR exists. (2) The cash-flow pattern has multiple sign changes (invest, withdraw, invest again) — multiple IRRs may exist and Newton's method picks one arbitrarily. (3) The return is extreme (very high or near −100%) — the solver's initial guess is too far from the solution. In these cases, try re-entering with cleaner sign conventions or simpler cash-flow groupings.