Monte Carlo Backtesting in Forex: Simulating Trade Sequences and Drawdown Risk

Learn how Monte Carlo trade reshuffling and bootstrap resampling work, check a six-trade forex drawdown example, and understand what simulated results cannot promise.
 
Written byHenry Green
Published
Last updated

Key Takeaways

  • Monte Carlo backtesting reorders or resamples an existing trade sample to explore modeled path risk; it is not a forecast of live forex results.
  • Shuffling without replacement retains every fixed-dollar outcome and its total profit, but can change the balance path and maximum drawdown.
  • In a six-trade hypothetical sample, three alternative orders all finish at $10,050 but have maximum balance drawdowns of approximately 2.43%, 5.19% and 5.50%.
  • Bootstrap resampling with replacement can repeat or omit recorded outcomes; it can therefore change the modeled ending profit as well as the drawdown.
  • Simulation results depend on historical sample quality, costs, position sizing, independence assumptions and market regimes. More random runs do not repair flawed inputs.
  • There is no standard MT5 report metric that should be represented as a completed Monte Carlo study; the resampling rules and the tool running them must be documented.

Monte Carlo backtesting in forex investigates how different hypothetical sequences of trades could affect a trading strategy's balance, drawdown and other risk measures. It is often used after a historical backtest, because one smooth-looking equity curve may reflect the fortunate timing of winners and losers rather than a durable strategy.

Quick answer: Start with a documented set of closed trade results; repeatedly shuffle their order without replacement or resample outcomes with replacement; build account paths from the chosen starting balance; and compare the resulting drawdowns, streaks and other metrics. The technique illustrates uncertainty under the model. It does not predict future forex prices or guarantee profitability.

All monetary figures in this guide are hypothetical educational examples, not real FXGlory trades, verified platform results or broker-specific account rules. Forex and CFD trading, especially with leverage, can lead to significant losses. This guide is about interpreting backtest risk—not providing an interactive Monte Carlo trading simulator.

What Is Monte Carlo Backtesting in Forex?

Monte Carlo backtesting applies repeated random rearrangements or resamples to a trading strategy's recorded outcomes to explore how different hypothetical trade histories could behave. Instead of judging an Expert Advisor (EA) or discretionary strategy by one historical equity curve, the analyst creates many alternative paths under clearly defined assumptions. These paths can expose possible clusters of losses and deeper balance drawdowns than the original order happened to show.

It is important to separate one baseline backtest, which runs a strategy on selected historical data, from Monte Carlo analysis of that backtest, which changes selected aspects of the resulting trade data. Randomly rearranging completed trade results does not create new historical exchange rates, test new entry rules, or establish how an EA will execute in the future.

For example, a sequence of wins and losses might finish with a small gain but dip sharply along the way. A different arrangement of the same six closed trades can finish at exactly the same balance while having a smaller or larger maximum drawdown. That difference matters when evaluating risk tolerance, capital needs and assumptions about trade ordering—not because one path predicts what happens next.

What Data Should You Collect Before Running a Simulation?

Start with the underlying closed-trade list and the conditions that produced it. A headline win rate, final balance or profit factor is not enough to reconstruct a historical equity curve. Ideally retain the strategy version, instrument, timeframe, testing dates and execution model alongside the results. If your test has fewer completed trades than needed to represent different conditions, repeating the same small sample cannot manufacture missing evidence.

Inputs and assumptions to document
InputWhat to recordWhy it matters
Trade outcomesCompleted net P&L in one account currency, or explicitly defined returns / R-multiplesA dollar model and a percentage-risk model can produce different simulated paths.
Starting equity or balanceIllustrative opening capital and whether open positions are excludedDrawdown percentages need a defined balance or equity denominator.
CostsSpreads embedded in fills, commissions, swaps and separately modeled slippageMissing expenses may make results look stronger than reality.
Position and exit rulesInitial risk, partial closes, compounding, sizing adjustments and stop logicThe value of later trades may depend on earlier results.
Observations and regimeNumber of trades, dates, symbols, unusually large results and known market changesShort or selected histories may not represent adverse conditions.
Resampling designReplacement rule, number of paths, path length and reproducible random seedDifferent simulation choices answer different questions.

Decide whether partial exits are separate deals or part of one trade. With simultaneous positions, the balance after each close may miss substantial floating equity drawdown; simply shuffling closing P&L ignores intratrade risk. Exported MT5 tester results may require organizing individual trades and cost records before a separate Monte Carlo analysis. A standard Strategy Tester report is not itself evidence that Monte Carlo resampling was run.

Trade-Order Reshuffling vs Bootstrap Resampling

Two techniques are often described together but should not be treated as interchangeable:

How the sampling method changes the question
MethodWhat changes?What stays the same?Main caution
Shuffle without replacementThe order of the original completed tradesEvery observed outcome appears exactly once; in a fixed-dollar additive model, total P&L is unchangedExplores ordering only; cannot create unseen losses or new return magnitudes.
Bootstrap with replacementBoth order and which observed trade outcomes appearEach sampled outcome comes from the observed trade listSome trades repeat and others disappear; it still cannot model unprecedented events outside that sample.
Separate stress assumptionsCost, slippage, trade size, dependence or return distribution assumptionsOnly the inputs the analyst explicitly holds fixedNot equivalent to an ordinary trade shuffle; each assumption needs its own rationale.

Without replacement means no completed trade is omitted or repeated during a run. If its net dollar outcomes are fixed and every trade is allowed to finish, reordering cannot change their sum. It can change the intermediate peaks, troughs and drawdown. With replacement means each selection is made again from the original list; a large loss can appear twice in one simulated path and not at all in another, changing the path's total result.

These simple methods often assume trade outcomes can be rearranged or redrawn independently. That may be unrealistic for trend-following runs, clustered volatility, correlated positions or an EA whose next position depends on account equity. More complicated simulations require more careful modeling, not merely a larger number of random draws.

Six-Trade Forex Example: Same Profit, Different Drawdown

Consider a hypothetical $10,000 balance with six closed trade outcomes, all stated in account currency and already net of whatever costs were assumed in this toy data: +$300, +$200, +$100, −$250, −$200 and −$100. The six figures sum to +$50. They are not a real FXGlory performance record, a modeled spread quotation or an observed backtest.

Maximum balance drawdown is calculated from the running peak: (previous peak − later balance) ÷ previous peak × 100%. The starting $10,000 is included as the first possible peak. Drawdown is recalculated at every step and the largest percentage decline is reported for that path.

Three possible orders of the same six dollar outcomes
Illustrative orderSequenceRelevant peak → troughMaximum balance drawdownFinal balance
Interleaved+300, −250, +200, −200, +100, −100$10,300 → $10,050$250 / $10,300 = 2.43%$10,050
Winners first+300, +200, +100, −250, −200, −100$10,600 → $10,050$550 / $10,600 = 5.19%$10,050
Losses first−250, −200, −100, +300, +200, +100$10,000 → $9,450$550 / $10,000 = 5.50%$10,050

For the interleaved case, the balances progress as $10,300, $10,050, $10,250, $10,050, $10,150 and $10,050. The largest decline from a previously reached high is $250, measured from $10,300 to $10,050. In the losses-first case, the first three losses take the balance from $10,000 to $9,450, a $550 fall before any gain occurs.

Because all six numbers are different, there are exactly 6! = 720 distinct permutations. Independently checking all 720 against this fixed-dollar definition gives maximum balance-drawdown percentages ranging from approximately 2.43% to 5.50%, with the same final $10,050 in every ordering. This is an exhaustive toy ordering exercise, not a 720-run forecast or evidence of how often a future market drawdown will occur.

Interpretation: A good ending balance does not describe the route taken to reach it. The toy model deliberately fixes trade amounts and assumes all six positions complete. Position-size changes, percentage compounding, liquidation or early stopping can break that fixed-final-balance property.

How to Run a Monte Carlo Backtesting Exercise

For an actual strategy review, the goal is not to manufacture an impressive curve. It is to ask how sensitive historical-looking results are to the ordering and sampling assumptions. A transparent workflow can be repeated by another reviewer using the same saved inputs.

  1. Establish the baseline. Save the original completed-trade list, balance/equity convention, testing period, strategy inputs and cost basis. Confirm that the P&L sum reconciles with your report.
  2. Choose one question and one method. Use shuffling to study ordering of the same fixed outcomes; use bootstrap sampling to explore different mixes of the observed outcomes. Do not mix the interpretations.
  3. State the simulation settings. For example, use 1,000 paths of the original sample's trade count, a documented pseudo-random seed, one account currency and a fixed-dollar sizing assumption. 1,000 is an illustrative computational setting, not a quality guarantee.
  4. Construct every balance path. Start from the stated opening balance, add each modeled net trade outcome in its sampled order and retain each intermediate value. For variable percentage risk, recompute dollar sizes according to the stated rule rather than recycling fixed-dollar trades.
  5. Calculate path metrics. Record final balance, maximum peak-to-later-trough balance drawdown, loss-run length and whether a clearly defined hypothetical stopping threshold was crossed. Separately specify whether open equity was modeled.
  6. Summarize the distribution. Compare median and tail outcomes, not just the most attractive run. Repeat under independently justified adverse-cost and sizing assumptions and retain code, seed and input hashes for reproducibility.
  7. Check outside the sample. Review a genuinely untouched historical period or future observation separately. Monte Carlo replay of an overfitted in-sample trade list does not turn it into out-of-sample validation.

One can implement this in a spreadsheet or analysis program, or use a tool that documents its sampling rules. This article does not contain an interactive simulator, has not run a Monte Carlo forecast on real FXGlory trades and does not recommend a particular proprietary software product.

How to Read Monte Carlo Results and Drawdown Percentiles

A simulation batch produces a range of model-conditional outcomes, not one predicted account balance. Read every summary in the context of the baseline trade sample, resampling method and number of runs. It is especially important to distinguish a percentile of simulated maximum drawdown from a probability that an actual account will be protected.

Common outputs and the questions they can address
OutputHow to interpret itWhat it cannot establish
Median ending balanceThe middle final account value among modeled pathsA guaranteed future result or an independently verified strategy edge
Upper drawdown percentileFor example, a modeled 95th percentile maximum drawdown is exceeded by roughly 5% of included simulated pathsA 95% promise that a real account will stay within that drawdown
Losing-streak distributionHow long consecutive modeled losses lasted in the generated sequencesThe longest possible losing streak in a changing real market
Threshold crossingsThe fraction of generated paths that cross an explicitly modeled account thresholdActual broker margin calls, real regulatory protections, or a validated future ruin probability
Difference from the original backtestWhether the historical result depended strongly on the observed trade orderThat shuffling uncovered every possible risk or market regime

As an illustration of reading percentiles—not a computed result for FXGlory or the six-trade example—if a correctly labeled model reported a 95th-percentile maximum drawdown of 18%, it would mean that about 95% of those modeled paths had maximum drawdowns no greater than 18%, given their assumptions. It would not mean there is a verified 95% chance of avoiding a larger real loss. A different sample, more realistic costs, trade dependence or new market regime could produce a very different distribution.

Likewise, a higher number of simulation runs can reduce computational sampling noise but cannot correct a biased set of input trades. For very rare adverse outcomes, 1,000 draws may be too few to estimate the tail reliably. Precision on a chart is not the same as accuracy of the underlying assumptions.

What Does Monte Carlo Say About Drawdown and Risk of Ruin?

Maximum drawdown and risk of ruin answer related but distinct questions. Maximum drawdown measures the largest modeled fall from an earlier account peak. Ruin requires a clearly stated rule, such as the balance crossing a chosen capital floor or the trading process being unable to continue. Ruin is not automatically the same as a large drawdown, and different definitions of ruin produce different results.

The six-trade exercise holds every trade fixed and assumes all six can be completed. It therefore illustrates sequence-driven balance drawdown only. It does not model margin requirements, intratrade equity paths, liquidation, forced stops or actual FXGlory account rules. A separate path-stopping rule would have to be specified and evaluated honestly to study any threshold-crossing question.

Even a trade list with positive historical expectancy can experience a long losing run. Conversely, simulating the order of a negative-expectancy trade sample will not make its underlying average favorable. Use Monte Carlo to investigate fragility and uncertainty; use the actual backtest, a cost audit and independent testing to investigate whether the strategy premise is credible.

Limitations: What Monte Carlo Cannot Tell You

Monte Carlo output can look scientific because it contains many charts and precise percentages. That appearance can be misleading if the input trades are unrepresentative. A strategy tuned repeatedly on the same dates may have an attractive trade list because of selection bias. Shuffling those selected outcomes thousands of times does not remove that bias.

  • New regimes and rare shocks: Resampling old trades does not necessarily represent price gaps, liquidity interruptions, changed volatility or a loss worse than anything observed.
  • Dependent or overlapping trades: Clusters of losses, hedged or correlated positions and concurrent exposure are not recreated by blindly treating each completed trade as independent.
  • Path-dependent position sizing: Compounding, drawdown-based size changes, margin limits and stopping rules can make later outcomes depend on earlier balance changes.
  • Historical execution: Spread, commission, swap, slippage and market impact must be represented consistently; no simulation can guarantee a future stop fill.
  • Sample and modeling uncertainty: A small, cherry-picked, short or unstable trade history cannot support tight future-risk conclusions simply because the simulator generated many paths.
  • Metric scope: Closed balance outcomes may understate equity drawdown from open positions. Historical balance-path results must not be described as complete account-risk limits.
Financial-risk note: Leverage can magnify forex and CFD losses, and an ordinary stop-loss order may execute at a different price than expected. Monte Carlo output is conditional stress analysis, not assurance of survival, minimum profit or a maximum possible loss.

Monte Carlo vs MT5 Backtesting, Forward Testing and Walk-Forward Testing

These methods support one another, but each answers a different question. In particular, the standard MT5 Strategy Tester report is a historical backtest report; a separate Monte Carlo analysis requires a defined resampling process or an independently verified tool or workflow. Do not label MT5's standard report fields as a built-in Monte Carlo forecast. Refer to the official MetaTrader 5 Testing Report documentation for the platform's stated metrics.

Different ways to evaluate a trading-system hypothesis
MethodCore questionTypical limitation
Baseline historical backtestWhat would the stated rules have done on a specific historical dataset and cost model?Modeling, look-ahead errors and parameter fitting can distort the result.
Monte Carlo trade resamplingHow sensitive would modeled trade paths be to specified random changes in order or observed outcomes?Cannot introduce future market conditions not captured by its assumptions.
Holdout or forward observationHow does the strategy behave on different dates or subsequently observed prices?Historical holdouts and live/demo observations have their own sample and execution limitations.
Walk-forward testingWhat happens when a rule or model is repeatedly fitted on earlier windows and tested on later untouched windows?Window selection and repeated tuning can still create selection bias.

An MT5 historical forward segment remains a test on past prices; it should not be confused with observing actual future conditions on a demo or real account. For methodological details on resampling and its assumptions, the AmiBroker Monte Carlo guide explicitly describes sampling with replacement, while Quantpedia's method comparison discusses both sampling variants. These external sources explain techniques; they are not FXGlory performance endorsements.

Practical Monte Carlo Review Checklist

Before using Monte Carlo output to help assess a forex strategy, verify the following. The checklist helps document assumptions; it does not certify a strategy or make trading suitable for a particular person.

  1. Confirm the source backtest and save its EA/rule version, dates, market symbols and execution settings.
  2. Reconcile every completed-trade outcome with the report, including costs already reflected in fill prices.
  3. Keep the starting balance, currency, account-value basis and sample length visible.
  4. Choose explicitly between shuffling without replacement and bootstrap sampling with replacement.
  5. Write down the random seed, number of paths, position-size rules and any capital or stop conditions.
  6. Check maximum drawdown from each path's running peak; don't divide every drop by the initial balance.
  7. Review multiple adverse percentiles and scenarios instead of selecting the smoothest equity curve.
  8. Reassess plausible unmodeled spread, commission, swap and slippage without deducting known costs twice.
  9. Check that assumed independence, regime stability and concurrent positions are defensible.
  10. Keep a separate untouched-period or subsequent observation check and do not interpret simulated percentiles as promises.

A Monte Carlo study is most valuable when it identifies assumptions that could break, not when it gives a reassuring number. The results should lead to clearer questions about trade data, potential drawdowns and real execution—not a claim that future performance has been established.

Key Takeaway

Monte Carlo backtesting in forex is a way to stress-test how a given trade sample behaves under specified random changes. With additive fixed-dollar outcomes, the order of the same completed trades can alter drawdown without altering the ending profit. Bootstrapping with replacement also changes the mix of outcomes, so the ending result can vary.

Neither technique makes a backtest predictive on its own. Record the sample, sampling method, account-value basis, costs and sizing rules; examine the range of modeled outcomes; and verify conclusions outside the original development data before drawing practical lessons from a simulated strategy.

Frequently Asked Questions

What is Monte Carlo backtesting in forex trading?

It is a method of running repeated hypothetical sequences generated from a documented forex trade sample under specified randomization rules. The result shows how modeled outcomes such as drawdown may vary; it does not predict market prices or guarantee the strategy will work.

Does Monte Carlo reshuffling change the total profit of a forex backtest?

Not when the same fixed-dollar net trades are included exactly once and all are completed: their sum is unchanged. Reordering can still change the interim balance curve and maximum drawdown. Compounding, stopping rules or path-dependent position sizing can change that conclusion.

What is the difference between reshuffling and bootstrap resampling?

Reshuffling without replacement changes the order but uses every recorded trade exactly once. Bootstrap resampling with replacement draws from the observed list repeatedly, so some trades can appear several times and others not at all; both the ending P&L and drawdown can then change.

How many Monte Carlo simulations should I run?

There is no universally sufficient number. A batch of 1,000 runs can illustrate the process, but estimating rare events may require many more runs, and even millions of runs cannot fix biased or unrepresentative input data. Report the method, sample size, random seed and simulation count.

Does MetaTrader 5 include Monte Carlo results in a standard Strategy Tester report?

The standard Strategy Tester report documents a historical test and its metrics; it should not be described as a Monte Carlo resampling result. A Monte Carlo study requires a separately specified simulation or independently verified tool. Check any software integration and version before assuming it supports a particular method.

Can Monte Carlo simulation predict maximum forex drawdown or risk of ruin?

It can produce model-conditional distributions of simulated maximum drawdown and threshold crossings if the inputs and any stopping rule are defined. Those distributions do not establish real-world limits, account protection or reliable future probabilities, especially when market conditions or execution costs change.

Should I include spread, commissions and slippage in a Monte Carlo backtest?

Yes, apply a consistent cost convention. If recorded trade P&L already includes bid/ask fills or commission, do not deduct those costs twice. Separately stress-test plausible unmodeled expenses and execution differences and label the added assumptions.

Related Contents

How to Backtest on MT5Build and check a reproducible MetaTrader 5 baseline test before examining randomized trade paths.
How to Read an MT5 Backtest ReportInterpret modeled net results, balance/equity drawdown and performance statistics in a standard report.
What Is Drawdown in Forex Trading?Review the running-peak drawdown formula and the arithmetic of recovering from losses.
Risk of Ruin in Forex TradingDistinguish statistical survival assumptions from historical and simulated drawdown results.
Trading Expectancy ExplainedUnderstand what a completed-trade sample says about average net profit or loss per trade.

Review the risks before making trading decisions

A simulated strategy or favorable Monte Carlo result is not proof of future profit or a limit on losses. Assess costs, possible drawdowns and the risks of leveraged trading before considering an account.

Open an FXGlory Account