One backtest is one sequence of trades
The maximum drawdown in your MetaTrader report describes a single path: the one where the trades happened to arrive in that exact order. Shuffle the same trades and three losses that were spread out can land back to back. Nothing about the EA has changed, yet the drawdown can double. The number in the report is one outcome among many, not the worst case.
A Monte Carlo simulation asks the question that matters before you let an EA run: across thousands of plausible orderings, how deep a drawdown should you be ready to sit through? This tool builds between 1,000 and 10,000 paths from the trades in your report and returns the median maximum drawdown, the drawdown of the worst 5% of paths, the longest losing streak and the chance of breaching the limit you set yourself.
It also scans the report for the behaviours that make a backtest look better than the risk behind it: lot sizes that grow after losses, positions stacked against the market, a sample that is too small, rough price modelling. These are the same traps covered in our guide to spotting forex robots that are not what they seem.
How to export your strategy tester report
MetaTrader 4
- Run your EA in the Strategy Tester (Ctrl+R).
- Open the Report tab, right-click inside the table and choose Save as Report.
- MetaTrader writes a StrategyTester.htm file plus a .gif chart you can ignore. Load the .htm file.
MetaTrader 5
- When the test has finished, open the Backtest tab of the Strategy Tester.
- Right-click, then Report, and pick HTML or Open XML.
- Load the resulting ReportTester-xxxxxxx.html or .xml file.
The file is processed by your browser, on your own machine. Nothing is sent to QuantStone or anyone else, which matters because a report carries your broker's name and sometimes your account number. New to the tester? Our explainer on what an expert advisor is and how to backtest one walks through the basics.
What the red flags mean
Lot size growing after losses: martingale
A martingale increases the position size after every loss so that one winner wipes out the damage. The equity curve looks smooth right up until the losing streak the account cannot fund. The tool compares each position with the last trade that closed before it opened. When lots grow by 20% or more after losses far more often than after wins, it flags the pattern and shows the typical multiplier.
Positions stacked against the market: grid
A grid keeps adding positions in the same direction as price moves against it, often with bigger lots each time, then closes the whole basket for a small gain. Three measures are reported: the maximum number of positions open together, the share of entries added at a worse price than a position still open, and how often the lot size grows on those additions. For these EAs, positions closed at the same moment are merged into a single basket result before simulating, because they were one decision. The key point: a grid's balance stays smooth for as long as its baskets eventually close, while equity absorbs the blow. Judge a grid backtest on its equity drawdown, never on its balance curve.
Too few trades
Below a hundred trades or so, win rate and drawdown shift a lot from one sample to the next; below 30 they say very little. The simulation cannot fix that, since it only replays what the report contains. It is also why a backtest is never a substitute for a live record, as explained in our guide on how to verify a forex EA track record.
Modelling quality
In MT4, 90% is the ceiling with a broker's standard history. Below that, price action inside each bar is only roughly rebuilt, and an EA living off small moves (scalping, tight stops) can post results that could never happen live. The open prices only mode, shown as n/a, does not see inside the bars at all. In MT5, prefer a test on real ticks with history quality close to 100%.
Other checks
- Stop out: the broker closed positions for lack of margin during the test.
- Frequent small wins, rare heavy losses: a win rate of 70% or more while the average loss is at least twice the average win.
- No stop loss (MT4): if the EA, the terminal or the VPS goes down, nothing caps the loss.
- Negative expectancy: the backtest loses on average, so its drawdown keeps deepening with time.
- Short test: less than a year of data, possibly a single market regime.
How the simulation works, and what it cannot see
- Resampling: trade results from the report are drawn at random, with replacement, to build between 1,000 and 10,000 paths. By default each path is as long as the backtest; you can extend the horizon.
- Position sizing: with fixed lots, wins and losses are replayed in money; when lots track the balance, they are replayed as a percentage of it. The tool picks one from the correlation between lot size and balance, and you can override it. If you size by hand, our piece on the automated trading mistakes beginners make covers why a fixed percentage of the balance beats a fixed lot.
- Floating losses: drawdown is measured trade by trade on the balance. For grid baskets, the floating loss is rebuilt each time a position is added, at that entry price: a floor, since price may have travelled further afterwards. When the report includes MetaTrader's equity drawdown and it is deeper than the worst 5% of paths, the tool puts it at the top of the results, because that is the figure that counts.
- Independent draws: every trade is drawn on its own, which breaks the chains of trades that martingales and grids rely on. Their real risk is therefore understated, which is why they get flagged separately.
- Curve fitting: the simulation cannot detect it. An EA tuned to the past can produce a clean backtest and still fail live; an out-of-sample test followed by a demo account remains the only real check.
- Reproducible: the same data always gives the same figures, and a shared scenario link reproduces them exactly.
The recovery maths behind every drawdown
Getting back to a previous peak takes a larger gain than the loss itself, because that gain applies to a smaller balance. The formula: gain needed = loss / (1 - loss).
| Drop from peak | Gain needed to recover |
|---|---|
| 10% | 11.1% |
| 20% | 25% |
| 30% | 42.9% |
| 40% | 66.7% |
| 50% | 100% |
| 60% | 150% |
| 75% | 300% |
That asymmetry is why drawdown deserves more attention than the headline figures of a backtest. Past 30 or 40%, the road back gets long, and that is usually when people switch an EA off at the worst possible moment.