Calculators
Time-weighted return calculator (TWR vs MWR)
Calculate time-weighted (TWR) and money-weighted (MWR, IRR) return from deposits and withdrawals. Example: +5.83% TWR but −2.14% MWR on the same account.
Enter a withdrawal as a negative number. Month counts from the start of the period (6 = halfway through a year); amount 0 = no cash flow.
- TWR for the whole period
- +5.83%
- TWR per year
- +5.83%
- MWR (IRR) per year
- -2.14%
- MWR for the whole period
- -2.14%
- Sub-period returns
- +10.0% · -9.7% · +6.5%
- Gain in money
- -$500
- Deposits minus withdrawals
- +$15,000
TWR: (1 + r₁) × (1 + r₂) × … − 1, where r = value just before a flow ÷ value after the previous one − 1. MWR: the IRR of the cash flows, timing in months ÷ 12. Periods shorter than a year are not annualized.
You start the year with $10,000. In April, after a 10% gain, you add $20,000. The market drops, and in September you take $5,000 out. By December 31 the account is worth $24,500. Did you make money? Your investments returned +5.83% — that is the time-weighted return (TWR). Your money earned −2.14% — that is the money-weighted return (MWR). You are also $500 down on what you put in. All three numbers are right; they answer different questions. The calculator above computes them from a start value, up to two deposits or withdrawals, and an end value.
How to use the calculator
- 1
Enter the start value
The portfolio's value on the first day of the period, cash included.
- 2
Enter each deposit or withdrawal
The amount (withdrawals with a minus sign) and the month it happened, counted from the start: 3 means three months in. Leave the amount at 0 if there was only one flow.
- 3
Enter the value just before each flow
What the portfolio was worth on that day before the money arrived or left. This is the number TWR can't do without.
- 4
Enter the end value and the length of the period
The value on the last day, and the period in months (12 for a calendar year).
The headline result is the TWR for the whole period. Below it: TWR per year (shown only when the period is 12 months or longer), MWR per year and for the whole period, the return of each sub-period, the gain in dollars, and net deposits.
The formulas
Time-weighted return
TWR cuts the period at every external cash flow, measures each piece on its own, and chains them:
r = value just before the flow ÷ value right after the previous flow − 1
TWR = (1 + r₁) × (1 + r₂) × … × (1 + rₙ) − 1
Because each piece starts after the money has moved, the size and timing of your deposits drop out. What is left is how the investments themselves did — the number you can put next to an index or a fund. The CFA Institute's overview of the Global Investment Performance Standards (GIPS) says time-weighted returns are required for all portfolios except a narrow group where the firm controls the cash flows, such as closed-end or fixed-life funds.
For periods over a year, the calculator also shows TWR per year: (1 + TWR)^(12 ÷ months) − 1. For shorter periods it shows a dash. GIPS is explicit: "Returns for periods of less than one year must not be annualized" — a 4% quarter is not a 17% year.
Money-weighted return
MWR is the internal rate of return (IRR) of your cash flows: the yearly rate at which the start value and every deposit, compounded to the end, exactly equal the end value plus withdrawals. There is no closed formula; the calculator finds the rate numerically. It answers "what did my money earn?", so a large deposit right before a fall pulls it down and one right before a rally pushes it up.
Worked example 1: the defaults
$10,000 at the start; +$20,000 in month 3, when the portfolio was worth $11,000; −$5,000 in month 8, when it was worth $28,000; $24,500 at the end of month 12.
| Sub-period | Starts at | Ends at (before the flow) | Return |
|---|---|---|---|
| Months 0–3 | $10,000 | $11,000 | +10.0% |
| Months 3–8 | $11,000 + $20,000 = $31,000 | $28,000 | −9.7% |
| Months 8–12 | $28,000 − $5,000 = $23,000 | $24,500 | +6.5% |
TWR = 1.10 × 0.9032 × 1.0652 − 1 = +5.83%. The calculator also shows:
The gain in dollars is $24,500 − $10,000 − ($20,000 − $5,000) = −$500. The investments made money in two of three stretches, but most of the money arrived just in time for the −9.7% stretch and some of it left before the +6.5% one. TWR doesn't care about that; MWR does. The 7.97-point gap is the cost of the timing, not of the holdings.
Worked example 2: two and a half years
A longer period with deposits during a dip. Enter $50,000 at the start; +$12,000 in month 10 with the portfolio at $46,000; +$12,000 in month 22 with the portfolio at $58,000; $84,000 at the end; period 30 months.
| Result | Calculator |
|---|---|
| Sub-period returns | −8.0% · 0.0% · +20.0% |
| TWR for the whole period | +10.40% |
| TWR per year | +4.04% |
| MWR (IRR) per year | +6.28% |
| MWR for the whole period | +16.44% |
| Gain in money | +$10,000 |
Here MWR is higher than TWR: the two $12,000 deposits went in at lower prices and caught the +20% stretch at the end. The investor's money did better than the investments, because of when it was added. That is a fact about the cash flows, not about skill at picking holdings.
TWR or MWR: which one to look at
| Question | Use | Compare it with |
|---|---|---|
| Did my holdings beat the S&P 500 (or a fund)? | TWR | the index's total return over the same dates |
| What yearly return did my money earn? | MWR | your target, a savings rate, or the index's MWR with the same cash flows |
| Am I up or down on what I put in? | gain in money | — |
With no deposits or withdrawals at all, TWR and MWR are the same number, and for a multi-year period both reduce to the CAGR calculator's result.
Common mistakes
- Using the value after the deposit. Enter what the portfolio was worth before the money arrived. Using the value after it counts the deposit as a gain and inflates the sub-period return.
- Skipping a flow. Dividends that stay in the account are not cash flows — they are part of the return. Money moved in from your bank, or out to it, is. Transfers between two of your own brokerage accounts are flows for each account but cancel out for the combined portfolio.
- Annualizing a short period. A +8.39% half-year is not a +17% year. The calculator leaves TWR per year blank below 12 months for this reason.
- Reading MWR as a verdict on stock picking. A low MWR with a decent TWR says the deposits were badly timed, not that the holdings were bad.
- Approximating values on flow days. TWR is only as accurate as the valuations on the days money moved. Month-end values are a common approximation; with frequent deposits, it can drift.
Methodology
The calculator runs in your browser. TWR chains sub-period returns as above. MWR solves Σ CFₜ × (1 + i)^(−months ÷ 12) = 0 by bisection, with deposits as negative flows and withdrawals and the end value as positive ones; fed day counts ÷ 365 instead of months, the same solver reproduces Microsoft's documented XIRR example (37.34%). Every number in the worked examples was produced by the calculator. No taxes, fees or currency conversion are modeled. For a real portfolio with many trades, GetHossa computes a daily-chained TWR next to the S&P 500 on the portfolio vs S&P 500 page, from your imported broker history.
Educational tool, not investment advice.
Frequently asked questions
How do you calculate time-weighted return?+
Split the period at every deposit and withdrawal. For each piece, divide the value just before the next flow by the value right after the previous one and subtract 1. Multiply all the (1 + r) together and subtract 1. Example: +10%, −9.7% and +6.5% chain to 1.10 × 0.9032 × 1.0652 − 1 = +5.83%.
Why is my money-weighted return lower than my time-weighted return?+
Because more of your money was invested during the weaker stretches — for example, a large deposit shortly before a decline. MWR weights each period by the money in it; TWR weights every period equally.
Is IRR the same as money-weighted return?+
Yes. Money-weighted return is the internal rate of return of the portfolio's cash flows. Excel's and Google Sheets' XIRR compute it from exact dates; this calculator uses months, so results can differ slightly.
Can I annualize a return for less than a year?+
Performance standards say no: GIPS states that returns for periods of less than one year must not be annualized, because doing so projects a short result onto a full year. The calculator shows TWR per year only for periods of 12 months or more.
Which return should I compare with the S&P 500?+
Your time-weighted return, against the index's total return (with dividends) over the same dates. MWR depends on your own deposit timing, which the index doesn't have.
Sources
This article is for information and education only. It isn't investment or tax advice. Rules and broker practices change — check the current rules or talk to a tax advisor.
See your portfolio next to the S&P 500
Import your Interactive Brokers history or add trades by hand — GetHossa shows your real return, your TWR and your lead over the S&P 500.
Create account