### 🤔 The Confusion

You sold a stock at profit. Your bank balance increased. But your app now shows a **lower XIRR**. Did the app break?

No — this is how XIRR is supposed to work.

## XIRR 101: It's About Timing, Not Just Profit

XIRR (Extended Internal Rate of Return) measures your **annualized return considering when money** **went in and out**. It's not just "profit divided by investment."

When you withdraw money, you're fundamentally changing the cash flow timeline. This can increase _or_ decrease your XIRR depending on timing.

## Example: Why Selling at Profit Can Lower XIRR

### Scenario: Portfolio Before Withdrawal

| Date       | Action             | Amount       |
|------------|--------------------|--------------|
| Jan 2023  | Invested           | -₹1,00,000   |
| Dec 2024  | Current Value      | +₹1,40,000   |

XIRR: ~18.3% (money growing for 2 years)

### Scenario: After Partial Withdrawal

| Date       | Action                      | Amount       |
|------------|-----------------------------|--------------|
| Jan 2023  | Invested                    | -₹1,00,000   |
| Jun 2024  | Withdrew (profit booking)   | +₹50,000     |
| Dec 2024  | Current Value               | +₹70,000     |

XIRR: ~15.8% (money left portfolio earlier)

### 💡 What Happened?

Total return is still ₹20,000 profit. But when you withdrew ₹50,000 mid-way, that money **stopped compounding**. XIRR accounts for this — your effective annual growth rate is lower because part of the money "left early."

## When Withdrawals INCREASE Your XIRR

Withdrawals don't always lower XIRR. If you withdraw money that was about to lose value, your XIRR goes UP:

- **Selling before a crash** — Money that exits before losses = higher XIRR
- **Profit booking in a volatile stock** — Locking in gains can improve XIRR
- **Rebalancing out of underperformers** — Moving money to better stocks helps

## Why This Matters for Your Portfolio

### ✅ Good Insight

XIRR tells you the **true rate at which your money grew**, accounting for when you actually had it invested. It's honest.

### ⚠️ Don't Panic

A lower XIRR after withdrawal doesn't mean you made a bad decision. You still made a profit — just track both your absolute gains AND XIRR.

## How to Track Withdrawal Impact

- **Compare before/after** — Calculate XIRR with and without the withdrawal
- **Check timing** — Was withdrawal near market peak or bottom?
- **Use TrueXIRR** — See exactly which transactions affected your returns most

### See How Withdrawals Affected Your XIRR

Upload your tradebook and understand exactly how each sell impacted your returns.

[Analyze My Portfolio →](/content/site-root.html)
