How to Backtest an MT4 Expert Advisor (and Spot Fakes)
Key takeaways
- Run MT4 backtests on 'Every tick' modelling and check the modelling quality percentage, because low-quality tick data makes results unreliable.
- Judge EAs on profit factor, maximum drawdown, longest losing streak, and losing months together, never on win rate or absolute profit alone.
- A backtest with zero losing months, a profit factor above 3, and a win rate above 90% is statistically suspicious and likely curve-fitted.
- Walk-forward analysis, optimising on one data window and testing untouched on the next, exposes curve-fitted parameters that a single backtest hides.
- A VPS is unnecessary for backtests but essential for forward testing, since the EA must run continuously through every session to build a valid sample.
To backtest an MT4 expert advisor, load it into the Strategy Tester, select the symbol, timeframe, and date range, then run it on real-tick or 99% modelling-quality data before judging the report. But the mechanics are the easy half: each step also exposes a red flag, from missing tick data to optimised parameters that only fit history.
How do you backtest an expert advisor in the MT4 Strategy Tester?
Open the Strategy Tester with Ctrl+R or View → Strategy Tester, drop your EA's.ex5 (or.ex4 on MT4) into the Expert Advisor field, and pick the symbol and timeframe you intend to trade live. Set the date range, initial deposit, and modelling method, then hit Start. The full workflow, including where each setting lives, is documented in MetaQuotes' Strategy Tester guide.
Setting the inputs and date range
Choose "Every tick" modelling for the most realistic simulation, or "Control points" only when speed matters more than accuracy. Set the date range to cover at least two years so you capture different market regimes, and pick a deposit that mirrors your real account, not a round number that flatters the equity curve. Open the EA's Properties tab and check each input parameter against what the seller advertises; defaults that look suspiciously precise (2.837 rather than 3) deserve scrutiny later.
Reading the results tabs: graph, report, and journal
The Graph tab shows the equity curve as the test runs; the Report tab holds the numbers you will interrogate in later sections, including profit factor, drawdown, and consecutive losing trades. The Journal tab is the one most traders skip and the one that catches problems first: missing ticks, order errors, or an EA that silently stops trading mid-test. Note the modelling quality percentage in the report header, because a backtest built on poor tick data is worthless no matter how good the profit factor looks. The same discipline applies to evaluating any commercial EA, which is why every bot listed on our MT5 marketplace publishes its full month-by-month backtest rather than a single headline figure.
Which MT4 backtest settings and data quality issues distort results?
MT4's Strategy Tester runs on whatever history your broker's server has fed you, usually M1 bars generated from ticks you never saw. The "Modelling quality" figure in your report tells you how much of that history was real: 90% on "Every tick" often means the tester interpolated from M1 data, not that it replayed actual ticks. Low quality percentages, or a report that skips straight to results without one, mean the numbers are closer to fiction than measurement.
Modelling quality explained
The four modelling options, from "Open prices only" to "Every tick", trade speed for fidelity. "Open prices only" is useless for an EA that trades intrabar, yet it is fast enough that many sellers never test any other way. Before trusting any backtest of an MT4 expert advisor, run it yourself on "Every tick" and compare: if the equity curve collapses, the published result depended on loose modelling. We publish full month-by-month results plus an unseen-data run for exactly this reason (how BotGenomix compares).
Spread, commission and slippage inputs
Default testing uses fixed spread, which flatters scalping EAs on M15 charts. Set a realistic fixed spread for your broker, add commission per lot manually, and rerun. If profit factor drops from 2.0 to 1.1, the edge was the spread assumption, not the strategy.
How do you read profit factor, drawdown, and other tester reports?
Metrics that matter vs vanity metrics
Profit factor, maximum drawdown, longest losing streak, and the count of losing months tell you whether a strategy survives contact with live conditions. Win rate alone is noise: a 90% win rate with 10x losers is a martingale waiting to happen. Absolute profit is equally meaningless without the equity curve behind it. MetaQuotes' own documentation stresses testing on real ticks across multiple symbols for realistic results (MT5 testing docs).
A worked example of two EAs with the same profit but different risk
| Metric | EA A | EA B |
|---|---|---|
| Net profit (12mo) | £8,000 | £8,000 |
| Profit factor | 1.9 | 1.15 |
| Max drawdown | 9% | 34% |
| Longest losing streak | 4 trades | 17 trades |
| Losing months | 3 of 12 | 8 of 12 |
Same profit, opposite products. EA A is a candidate; EA B is one bad month from a margin call. Every bot on our track record page publishes all four metrics, losing months included, so you can run this exact comparison before buying.
What backtest red flags suggest a forex EA is a scam?
Curve-fitting signals in the inputs
Open the.ex5's or seller's published input list and count the optimised parameters. A grid-trading EA with 15 tuned inputs across two symbols is almost certainly curve-fitted: the more degrees of freedom, the easier it is to force a beautiful equity curve onto historical data. Check whether the same settings work across adjacent timeframes and symbols; a genuine edge degrades gracefully, a fitted one collapses.
Watch the monthly distribution too. A backtest with zero losing months over three years, a profit factor above 3, and a win rate above 90% is statistically suspicious for any M15-H4 strategy on FX majors or indices. Real systems show drawdowns and losing streaks. Every bot listed at https://botgenomix.com/ publishes its full month-by-month backtest including the losing months, plus robustness checks and a separate unseen-data result, all labelled simulated.
Seller-side red flags: anonymous vendors, screenshot-only evidence, refund traps
Anonymous sellers who disappear when something breaks are the oldest failure mode in this market. Demand a named vendor, a working contact route, and evidence you can reproduce in your own Strategy Tester, not screenshots.
Treat inflated marketplace reviews as noise; ratings are easy to fabricate, so only verifiable forward results count. And read refund terms before paying: on MQL5 Market (https://www.mql5.com/en/market) and most direct EA sellers, once you purchase a licence, recovering the fee is nearly impossible. Flat monthly pricing with no performance fee at least caps your downside to the subscription.
How does walk-forward analysis (including in Python) validate an MT4 backtest?
Walk-forward in plain terms
Walk-forward analysis optimises your EA on one window of data, then tests it untouched on the next window, rolling forward repeatedly. A single backtest can hide curve-fitted parameters; a system that only survives when optimised on the same data it is tested on will show it immediately. If performance degrades sharply out-of-sample, the edge was probably an artefact. Marketplaces rarely surface this: on the MQL5 Market, seller pages lean on headline backtests rather than unseen-data results, which is why we publish a separate 2025+ unseen-data run for every BotGenomix bot, labelled simulated, alongside the full month-by-month record (pricing).
Exporting tester data and running walk-forward analysis in Python
MT4 cannot do this natively. Export the tester report (or optimisation results) to CSV, then use pandas to split data into train/test windows, re-optimise per window, and stitch the out-of-sample equity curves together. The pandas documentation covers the resampling and rolling-window functions you need. Where MT5's tester gives you real-tick data, MT4's modelling quality limits how much you can trust the input, so treat degraded walk-forward results as a red flag, not noise.
How does MT4 backtesting differ from MT5's Strategy Tester and indicator testing?
MT4's tester runs one symbol per pass with modelled ticks, so a multi-pair EA needs repeated runs and stitched assumptions. MT5 tests on real recorded ticks, runs multi-symbol EAs in a single pass, and lets you optimise across threads. If your EA trades indices, FX majors, and metals together, MT5 shows the combined equity curve and drawdown, not a per-symbol approximation.
MT5 real-tick and multi-symbol testing
Real-tick data removes the biggest distortion in MT4 backtests: synthetic tick generation from M1 bars. Spread and slippage modelling are also more explicit. A result that survives real ticks plus a walk-forward retest is far harder to curve-fit than one built on MT4's modelled data.
Testing indicators with the MT5 Strategy Tester
MT5 tests indicators directly: select the indicator as the expert, and the tester plots buffer values and signals on the chart. MT4 cannot do this; you wrap the indicator in an EA stub to test it.
One caveat: most commercial EAs ship as.ex4, which only runs on MT4. An.ex5 build is the minimum requirement for real-tick validation.
Do you need a VPS to run backtests and forward tests on MetaTrader 4 or 5?
No. Backtests run entirely on your local machine, and a desktop with enough RAM handles real-tick data fine. The Strategy Tester is single-threaded per pass, so a fast CPU beats a VPS here.
A VPS earns its cost once you move to forward or demo validation. Walk-forward and out-of-sample testing only mean something if the EA runs continuously through every session, and a terminal that sleeps with your laptop kills the sample. A £10-£30/month VPS near your broker's server keeps the forward test honest and, later, execution latency low. QuantStart's walkthrough of walk-forward methodology assumes exactly this kind of uninterrupted data collection.
You do not need MetaQuotes' own VPS; any Windows VPS running your terminal works.
How do you apply this checklist before buying a multi-bot EA licence?
Run every vendor through the same steps: demand real-tick backtests with visible drawdowns and losing months, check whether parameters were optimised on the same data they were tested on, and ask for walk-forward or unseen-data results. Most MQL5 Market listings and similar storefronts fail on at least one of these.
BotGenomix publishes month-by-month backtests, drawdowns, robustness checks and a separate 2025+ unseen-data result for each bot, all labelled simulated. That transparency is the point, but the limitation is real: none of it is a live track record. A clean simulation is not proof the EA survives live spreads and slippage.
So treat the licence like a forward test. Start the Super (£149/mo) or Expert (£249/mo) tier on demo or minimum size, compare live behaviour against the published backtest, and only scale once the divergence looks acceptable.
FAQ
Can you backtest an MT4 EA without historical tick data?
Yes, but with caveats. MT4 will generate synthetic ticks from M1 bars, and the report's modelling quality percentage shows how much history was real versus interpolated. Results on modelled data can look far better than reality, so rerun anything promising on 'Every tick' with quality data before trusting the equity curve.
What is a good profit factor for an expert advisor?
Above roughly 1.5 after realistic spread and commission is a reasonable threshold, and anything above 3 deserves suspicion rather than celebration, since it often signals curve-fitting or an unrealistic spread assumption. Judge profit factor alongside maximum drawdown and losing streaks; a 1.9 with 9% drawdown beats a 2.0 built on fixed-spread optimism.
How many years of data do you need for a reliable EA backtest?
At least two years, so the test covers multiple market regimes rather than a single trend or volatility environment. Longer is better, but only if the tick data quality holds up. A decade of low-quality modelled data proves less than two years of real-tick history, so prioritise data fidelity over raw length.
Is a demo forward test better than a backtest?
Yes, because a backtest is a simulation while a demo forward test runs through live spreads, slippage, and execution in real time. The catch is speed: a forward test accumulates one day of evidence per day. Use both, backtest to filter candidates quickly, then forward test on demo before risking real money.
Can you convert an MT4 EA (.ex4) to run in MT5?
Not directly. MQL4 and MQL5 are different languages, and .ex4 files only run on MT4. Conversion means porting the source code to MQL5, which is only possible if you have it, and commercial EAs rarely ship source. If real-tick validation matters to you, look for a vendor offering a genuine .ex5 build.
Important: BotGenomix provides downloadable automated trading software for independent use. It does not provide personalised investment advice or manage customer trading accounts. Trading involves substantial risk, including the potential loss of capital. Past performance and backtested results are not reliable indicators of future performance. Full risk information
