Backtesting

How to Backtest a Trading Strategy (Without Fooling Yourself)

Backtesting is easy to do badly and hard to do honestly. A strategy that looks incredible on historical data usually has one of a handful of hidden flaws — here's how to actually validate an edge instead of fooling yourself into one.

Part 1. Step 1: Define the Rules Completely, Before Looking at Results

Every entry condition, exit condition, stop placement, and position sizing rule needs to be written down in full before you run a single test. If you're adjusting rules while watching the equity curve improve, you're not backtesting — you're curve-fitting to noise.

Part 2. Step 2: Watch for Lookahead Bias

The most common silent killer: using data that wouldn't have actually been available at the time of the trade (e.g., using the day's closing price to trigger a signal earlier in the day). If your backtest engine isn't strictly bar-by-bar sequential, double-check every signal against what was truly knowable at that timestamp.

Score Your Next Setup Before You Take It

TRADZY's Void Engine rates every setup 0-100 in seconds. Free to start.

Try the Void Engine Free →

Part 3. Step 3: Test Across Multiple Market Regimes

A strategy backtested only on a strong trending period will look artificially great and fail immediately in a chop-heavy range. Split your test data into trending, ranging, and high-volatility segments and evaluate performance in each separately.

Part 4. Step 4: Beware Overfitting

If your strategy needs 6 finely-tuned parameters to work, it's very likely fit to historical noise rather than a real, repeatable edge. A simpler strategy with fewer parameters that performs decently across many periods is more trustworthy than a complex one that performs perfectly on one period.

Part 5. Step 5: Account for Realistic Costs

Slippage, spread, and commissions are often left out of backtests entirely, and they disproportionately hurt high-frequency strategies. Build in a conservative cost estimate per trade before trusting the results.

Part 6. Step 6: Forward Test Before Committing Real Size

A backtest that passes should move to paper trading or small-size live trading for a meaningful sample (generally 30+ trades minimum) before scaling up. This is the step most impatient traders skip, and it's the one that catches issues a backtest can't — real execution slippage, real emotional response to real drawdowns.

Part 7. Step 7: Journal the Forward Test Like Any Other Trade

Score each forward-test setup the same way you would a live trade, and compare the setup score distribution against your historical backtest assumptions. If your live scores are consistently lower than what the backtest assumed, the strategy's real-world opportunity set is smaller than the historical data suggested.

Part 8. Forward Test It Inside TRADZY

Once a backtest passes the sanity checklist, here's how to validate it live without guessing:

  1. Define the mechanical rules exactly as backtested, then log every forward-test trade in TRADZY tagged with the strategy name.
  2. Score each live setup with the Void Engine and compare the score distribution to what your backtest assumed — a mismatch here means the historical opportunity set doesn't match reality.
  3. Track win rate, R:R, and drawdown for just this tag, separate from your regular trading, so a bad week doesn't get blended into your overall stats.
  4. Only size up once the forward-test sample (30+ trades) confirms what the backtest promised.

Part 9. A Quick Backtest Sanity Checklist

A strategy that survives all five checks isn't guaranteed to keep working forever — markets change — but it's earned enough trust to size up gradually instead of all at once.

FAQ

How many trades do I need for a valid backtest?

There's no universal number, but fewer than 100 trades across varied market conditions is generally too small to draw firm conclusions.

What is lookahead bias?

Using information in a backtest that wouldn't have actually been available at that point in time — one of the most common ways backtests overstate performance.

Should I forward test before going live?

Yes — forward testing (paper or small real size) catches execution and psychological factors a backtest can't simulate.

Stop Guessing. Start Scoring.

TRADZY scores every setup 0–100 before you enter, then journals what actually happened. Free to start.

Try TRADZY Free →