MT5 GUIDE · BK CORP CLUB
How to Forward-Test an Expert Advisor on a Demo Account
A backtest shows the past; a forward test shows how an EA actually behaves in live market conditions. Here is how to run a proper forward test on a demo account.
Backtesting an Expert Advisor in MT5's Strategy Tester is a valuable starting point, but it is not the same as watching an EA trade in real time. Backtests simulate what would have happened — they cannot perfectly replicate slippage, requotes, spread widening during news events, or the psychological experience of watching an open trade.
A forward test on a demo account bridges the gap between backtesting and live trading. This guide explains how to do it properly.
What is forward testing?
Forward testing (also called paper trading or demo testing) means running an EA on a demo account with live market data, in real time, without risking real money. The EA opens, manages and closes trades using actual live prices — the only difference from a live account is that the losses and gains are not real.
Forward testing tells you things a backtest cannot:
- Whether the EA connects to the broker's server reliably
- How the EA handles news events and volatility spikes
- What the actual spread costs are on this broker's live feed
- Whether the EA's average trade frequency matches what you expected from the backtest
- Whether there are any bugs or unexpected behaviours in live conditions
Step 1: Open a demo account with the same broker
Your forward test should use the same broker you intend to use for live trading. Different brokers have different spreads, execution speeds, and server conditions. An EA that runs smoothly on one broker may execute differently on another.
Most regulated brokers offer unlimited demo accounts. Open a demo with the same account type (ECN, STP, standard) and roughly the same starting balance you plan to use in live trading. If you plan to live-trade with $5,000, demo-test with $5,000 — not $1,000,000, which would let you ignore lot sizing.
Step 2: Install the EA and configure the settings
Copy the EA file to the `MQL5/Experts/` folder in MT5's data directory (File → Open Data Folder → MQL5 → Experts). Restart MT5 or refresh the Navigator panel, then drag the EA onto the chart for the instrument it trades.
Configure the settings as you intend to run them in live trading. Use the same lot size, stop loss, take profit, and other inputs. Do not use different settings for the demo test and then switch to aggressive settings for live trading.
Enable "Allow automated trading" in MT5 and confirm the EA shows a smiley face in the chart's top-right corner. This confirms it is active.
Step 3: Run the test for a meaningful period
This is the step most traders skip. Two days is not a meaningful forward test. Neither is one week.
A meaningful forward test runs for at least four to eight weeks, ideally three months. Here is why:
- Trading conditions vary across different times of month (end-of-month flows, NFP release, FOMC meetings)
- Some EAs trade infrequently — a swing EA might only take 10–15 trades per month, so a one-week test produces very few data points
- You want to observe at least one difficult period — a choppy market, a sharp reversal, or a major news event — not just the good conditions
Track the following during the test:
- Number of trades opened
- Win rate and average profit/loss
- Maximum drawdown (look at both the closed-trade drawdown and the floating/open drawdown)
- Any error messages in MT5's Journal tab (Experts tab also shows EA activity)
- Comparison of actual spread costs to what the backtest assumed
Step 4: Compare to the backtest
After the forward test period, compare the results to the backtest:
- Is the win rate broadly similar?
- Is the average trade duration similar?
- Is the drawdown within the range the backtest showed?
- Is the total profit roughly in line with what a proportional slice of the backtest would predict?
Perfect agreement is not expected — markets change and backtests have limitations. But significant divergence (the EA is losing money in the forward test while the backtest was strongly profitable, or the number of trades is vastly different) is a signal worth investigating before using real money.
Step 5: What to do if the forward test goes badly
If the EA shows unexpected losses or high drawdown in the forward test:
- Check whether you set up the EA correctly (correct instrument, correct timeframe, correct settings)
- Check the Journal tab for error messages
- Consider whether the market conditions during your test period are outside the range the EA was designed for
- Contact the EA provider if you rented the EA and ask for guidance
Do not move to a live account if the forward test has not met your expectations.
A note on demo vs live execution
One limitation of demo testing is that demo accounts may execute orders slightly differently from live accounts. Demo fills are typically instant without slippage; live accounts may experience re-quotes, partial fills or slippage during fast markets. This means a demo test may slightly overstate performance compared to live trading, particularly for scalping EAs.
This does not make demo testing less valuable — it still tells you far more than a backtest alone. Just be aware that live performance may be modestly lower than demo performance.
Running an EA on a demo account does not guarantee the same results on a live account. All trading involves risk.
Related reading: How to backtest an Expert Advisor in MT5 · Risk management before automation
Educational content only, not financial advice. Trading involves risk and losses are possible. Automated trading does not guarantee profits.
