Strategy Tester vs Live: Why MT5 Results Do Not Match
Short answer: The MetaTrader 5 Strategy Tester simulates history with assumptions (ticks, spread, fills). Live trading adds real spread widening, slippage, latency, and broker rules. If your EA looks perfect in backtest but fails on a real account, the gap is usually settings or execution, not “bad luck.” Fix tick mode, spread, forward validation, and Demo — before changing strategy logic.
Related guides: Backtest EA in Strategy Tester · Deploy and Maintain EA · EA Risk Management · MT5 Error 10016 · Why Learning MQL5 Is Hard
Short Answer: Why Results Differ
Per MetaTrader 5 Help — testing: "The entire operation of the Strategy Tester is based on historical quotes. During testing, the Expert Advisor goes through the accumulated quotes and performs virtual transactions according to its algorithm."
That sentence explains the core issue: the tester is historical simulation, not your broker’s live server at 8:30am with widening gold spread.
| Factor | Strategy Tester | Live / Demo account |
|---|---|---|
| Spread | Often fixed or averaged | Widens in news, rollover, low liquidity |
| Fills | Idealized at test prices | Slippage, requotes, partial fills |
| Latency | None | VPS, internet, broker execution |
| Stops level | May be ignored in rough tests | Enforced — 10016 invalid stops |
| Emotions | None | Manual interference, disabling EA |
Spread, Slippage, and Execution
Scalping and gold EAs are especially sensitive. A backtest with tight spread can show profit while live spread eats edge — see Scalping EA for MT5 and Gold EA (XAUUSD).
What to do:
- Enable current or realistic spread in tester settings when available.
- Add a spread filter in code (or in Strategy Builder filters step).
- Increase
deviationinOrderSendmodestly for volatile symbols — log retcodes in Journal.
Tick Mode and Data Quality
The fastest test modes are the least trustworthy:
| Mode | Speed | Realism |
|---|---|---|
| Open prices only | Fastest | Lowest — skips intrabar path |
| 1 minute OHLC | Medium | Moderate |
| Every tick / real ticks | Slower | Best for scalping and tight stops |
For EAs that trade on M1/M5 or use intrabar SL/TP, Every tick based on real ticks is the baseline — detailed steps in backtest guide.
Download enough history: Tools → History Center — incomplete data creates false signals.
Overfitting and Optimization
Genetic optimization can find parameters that fit noise in one period. Symptoms:
- Amazing backtest, poor forward segment
- Hundreds of trades only in one year
- Extreme input values (period 3, SL 2 points)
Fix: Use forward testing in Strategy Tester; require stable results on the forward window; avoid trusting a single optimized set without Demo validation.
Broker and Symbol Differences
- Symbol suffix —
EURUSDvsEURUSD.a— EA attached to wrong symbol trades nothing or wrong specs. - Stops level — live broker may reject stops that backtest “accepted.”
- Margin and lot step — use
SymbolInfoDoublefor volume — risk management. - Prop firms — daily loss and news rules not modeled in standard tester — prop firm EA rules.
Checklist Before Going Live
| Step | Action |
|---|---|
| 1 | Re-run backtest with Every tick (real ticks if available) |
| 2 | Compare spread settings vs typical live session |
| 3 | Run forward or out-of-sample period |
| 4 | Forward test on Demo 2–4+ weeks (your criteria) |
| 5 | Journal clean — no repeated 10016 / 134 / 10004 |
| 6 | VPS if EA must run 24/7 — VPS for EA |
| 7 | Start live with minimum lot and risk caps |
Mobile vs Desktop Testing
Desktop: run Strategy Tester, optimization, and full Journal review in MetaEditor.
Mobile: use the MT5 app to monitor Demo/live (equity, open trades, alerts) — do not rely on phone for tick-mode backtests. Design and backtest on desktop; verify execution on Demo from mobile if you travel.
Next Steps
- Master tester settings: Backtest EA in MT5
- Fix live order errors: Common MQL5 EA Errors
- Build logic without coding: Strategy Builder → Build EA Without Coding
- Go live safely: Deploy and Maintain EA
A good backtest is necessary — Demo validation is what bridges the gap to live.