Skip to content

Stockertim Dictionary · Technology · Investing

Backtesting

Also called backtest

In short

Testing an investment strategy or risk model on historical data to see how it would have performed, before relying on it with real money or for real decisions.

  • Intermediate
  • Process
  • Checked

In detail

A backtest replays the past. The analyst writes down the exact rules of a strategy, such as buy when the 50-day moving average crosses above the 200-day and sell when it crosses back, then applies them to years of historical prices as if trading in real time. The output is a simulated record: returns, volatility, the worst fall from a peak, the number of trades and how long losing spells lasted.

Banks backtest risk models too. A value-at-risk model that claims losses should exceed a certain level on only one day in a hundred is checked against actual trading days; if breaches happen far more often, the model is understating risk. Supervisors use the results when setting capital requirements for market risk.

Backtests are easy to get wrong in ways that flatter the result. Look-ahead bias uses information that was not available at the time, such as revised economic figures. Survivorship bias tests only on firms that still exist today, ignoring those that failed. Ignoring trading costs, taxes and the price impact of large orders inflates returns. Trying many variations and keeping the best leads to overfitting. A careful backtest uses point-in-time data, realistic costs and a test period kept apart from the one used to design the rules, and even then past results do not ensure future ones.

Worked example

A strategy backtested on ₦1,000,000 shows a gross gain of 12% over a year with 100 trades costing ₦500 each.

  1. Gross gain: ₦1,000,000 × 12% = ₦120,000
  2. Trading costs: 100 × ₦500 = ₦50,000
  3. Net gain: ₦120,000 − ₦50,000 = ₦70,000, or ₦70,000 / ₦1,000,000 = 7%

Once costs are included the simulated return falls from 12% to 7%.

In practice

Fund managers show backtests when proposing new strategies, and regulators in many countries restrict how simulated past performance may be shown to retail investors, often requiring clear labels and warnings. Risk teams run regular backtests on their models and report breaches.

Watch out

  • A backtest is a simulation, not a track record; real trading faces costs, delays and emotions the model ignores.
  • The more variations tested, the more likely the best one is luck.

Learn it properly

Official sources

Facts last checked on 1 November 2026.

Education, not advice: the Stockertim Dictionary explains what terms mean. It never recommends buying or selling anything.

English