Strategy

How to Backtest a Scalping Strategy

Scalping backtests fail for one reason above all others: they leave out the costs. When you are hunting a few pips at a time, spread and commission are not a rounding error - they are the difference between an edge and an illusion.

Backtesting a scalping strategy is harder than backtesting slower systems because the tiny profit target means transaction costs consume a large share of every trade. A spread that barely dents a swing trade can quietly turn a winning scalp into a losing one - so realistic costs are the single most important thing to get right.

Why costs dominate a scalper

Imagine a scalp that targets 6 pips with a 4-pip stop. If your spread is 1 pip and commission adds another, roughly a third of your average winner is gone before the market moves your way. The same costs against a 60-pip swing target are trivial. This is the core reason so many scalping strategies look brilliant on a raw chart and lose money live: the backtest measured gross pips, not net.

Same cost, very different bite1 pip cost, two targets
6-pip scalp
~33% eaten
20-pip intraday
~10% eaten
60-pip swing
~3% eaten

The smaller your target, the more of it your costs consume. For a scalper, cost modeling is not optional.

Rule one: bake in realistic costs

Every trade in your test must carry the full spread plus any commission - and use the spread you will actually face in your session, not a best-case number. Spreads widen around news and in quiet hours, so a scalper tested only on the calmest data flatters itself. If your strategy is not clearly profitable after realistic costs, it is not profitable. Read how commission works to model it correctly.

Rule two: respect execution limits

Scalping leans hard on things a backtest cannot fully reproduce - slippage on entries and stops, fill quality, and speed. A manual backtest cannot promise you would have gotten the exact price, so be conservative: assume you get filled at the worse edge of the candle, not the perfect tick. Building that pessimism in keeps the result honest.

Important: the one advantage scalping gives you is volume. Because you take so many trades, you reach a statistically meaningful sample far faster than a swing trader - often several hundred trades in a focused testing session. Use that to demand a large sample before trusting the edge.

Rule three: test your actual session

Scalping is intensely session-dependent. A strategy that prints during the volatile London-New York overlap can bleed in the thin Asian range where every move stalls. Test the specific hours you will trade, across both busy and quiet days, so the numbers reflect your real conditions rather than one lucky afternoon.

Build the sample fast

In the simulator you can replay a fast timeframe, take scalp after scalp with spread and commission applied automatically, and reach hundreds of trades quickly. Then read the report on a net basis: expectancy after costs, profit factor, and drawdown. If the edge survives realistic costs across your session, you have something the raw-pips crowd never gets to see.

Scalping backtest FAQ

Why is backtesting a scalping strategy harder?

The tiny profit target means spread, commission, and slippage make up a large share of each trade - costs that barely matter to a swing trader can flip a scalp negative.

How do I account for spread?

Apply the full spread and commission to every trade using realistic figures for your session, not a best-case spread - for a scalper they can be a third of the target.

How many trades do I need?

Several hundred is achievable because scalpers trade so often. Make sure the sample covers your actual hours and a range of volatility, not one calm session.

Risk disclaimerTrading foreign exchange, CFDs, and other leveraged products carries a high level of risk and is not suitable for every investor — losses can exceed your deposits. Everything on this page is educational content, not financial advice. Backtest and simulator results are hypothetical: they do not represent live trading and past performance does not guarantee future results.