Skip to content

volume indicator

MFI backtesting — Money Flow Index

The Money Flow Index (MFI) is a volume-weighted momentum oscillator, often called volume-weighted RSI, that measures buying and selling pressure on a 0–100 scale using both price and traded volume. Bringing volume into the picture means MFI can diverge from a plain price-based oscillator — whether that adds real signal on your market is a backtesting question.

Try MFI on BTC/USDT ETH/USDT SOL/USDT

How MFI works

MFI starts from typical price (the average of high, low, and close) and multiplies it by volume to get raw money flow for each candle. Candles are classified as positive or negative money flow based on whether typical price rose or fell versus the prior candle, then the ratio of positive to negative money flow over the lookback window is compressed into a 0–100 index — the same style of calculation as RSI, but weighted by volume instead of price change alone. CandleTest computes MFI with TradingView-parity math. Traders read below 20 as oversold and above 80 as overbought, the same convention as RSI but informed by volume — testable as no-code rules.

MFI settings

Lengthdefault 14

The lookback window for the positive/negative money flow ratio. Shorter lengths make MFI more reactive to recent volume-weighted price swings; longer lengths smooth it out.

Example MFI strategies to backtest

Volume-weighted oversold long

Enter long when MFI crosses above 20 (leaving oversold). Exit when MFI crosses above 80.

Overbought exit

Exit an open long when MFI crosses below 80 (leaving overbought) — a way to close out before volume-weighted momentum fully reverses.

Every rule above is buildable in the no-code strategy builder — pick conditions, press run, and get win rate, drawdown and equity curve on real exchange data with fees and leverage modeled.

MFI FAQ

How is MFI different from RSI?

RSI is calculated from price alone, while MFI folds traded volume into the same style of calculation, so a price move on heavy volume weighs more than the same move on light volume. Backtesting the same style of rule on both shows whether the volume weighting changes results meaningfully on a given pair.

Does volume make MFI more reliable than RSI?

Not automatically — it adds information, but more information does not guarantee a better signal, and MFI can still whipsaw in choppy, low-conviction markets. The only way to know is to compare backtested results between the two on your specific market and timeframe.

What MFI settings should I use for crypto?

There is no universal setting — crypto volume patterns vary a lot across exchanges and pairs, so the right length is an empirical question. Sweep a few lengths in a backtest rather than assuming a common default transfers directly.

Is CandleTest’s MFI the same as TradingView’s?

Yes — the typical-price and money-flow-ratio calculations follow TradingView conventions and are unit-tested for parity against known values.

Related indicators