Why an EA Takes Zero Trades: The Spread Filter That Blocks Every Bar
Ringkasan — An EA that loads but reports zero trades is usually not a broken strategy — it is a max-spread guard rejecting every bar. How the filter works, the five silent blockers behind an empty MT5 report, how to define a spread cap that survives across instruments, and an honest audit of the 12 zero-trade runs in our own catalogue.
Why an EA takes zero trades: the spread filter that blocks every bar
TL;DR — If your Expert Advisor loads but reports zero trades, the cause is usually not broken strategy logic. It is a max-spread guard rejecting every bar.
- The MetaTrader 5 tester often models spreads wider than a typical 50-point cap, so the guard rejects 100 percent of bars and returns a fake "0 net, 0 profit factor".
- Four other silent blockers give the same empty report: an unloaded second symbol, oversized lots, a missing economic calendar, and a genuine no-signal condition.
- In our catalogue, 12 of 48 one-year runs report zero trades; 8 are utilities that never trade by design. All are published as verification pending, not as losers — see the proof page.
What is a spread filter in an EA?
A spread filter is a one-line execution guard, typically named something like MaxSpreadPoints, that runs before any order is sent: it reads the current bid-ask difference in points and returns early if that is wider than a user-set cap. The intent is sound — it stops the robot paying 40 points of spread for a trade that only expects 25 points of edge. It is a cost control, not a strategy component, and never decides direction.
Why does a spread filter produce zero trades in a backtest?
Because a cap that is correct live can be permanently exceeded inside the tester. A default around 50 points is reasonable on a tight live account during liquid hours, but the MetaTrader 5 tester models spread from its own settings and symbol history, and for many instruments that modelled spread sits above 50 points on nearly every bar. The guard fires every bar, no order is ever sent, and the report returns zero trades and a profit factor of zero.
That is the trap: the output looks like a strategy that found no opportunities, when it is a filter that never let the strategy speak. Because the same guard convention appears in most of our builds, one bad default silently zeroed many tests at once.
How do you confirm which blocker is responsible?
Read the tester log before touching the strategy code. Each cause leaves a distinct fingerprint.
| Symptom in the report | Likely cause | Where to confirm | Correct fix |
|---|---|---|---|
| Zero trades, EA loaded, log otherwise clean | Max-spread guard rejects every bar | No order lines at all in the tester log | Raise the cap for testing only, keep the real cap live |
| Zero trades, header shows zero symbols | A second instrument never loaded into Market Watch | Initialisation-failed line in the log | Select every referenced symbol in code before validating it |
| Zero trades, repeated order rejections | Lot size too large for the deposit | Not-enough-money lines in the log | Fix risk per trade and stop distance so lots fit the equity |
| Zero trades on a news strategy | The tester has no economic calendar | Calendar-unavailable warning in the log | Supply manual event times and disclose the approximation |
| Zero trades, no log evidence at all | Genuine no-signal: entry conditions never met | Add a counter at each early return and compare to bar count | Re-examine the signal logic, not the settings |
The ordering matters: in four of these five cases the log already names the culprit, and reading it is far faster than instrumenting and recompiling the EA.
How should the spread cap actually be defined?
A fixed point value is the most common design and the most fragile, because points are not comparable across instruments. Three workable designs:
| Cap design | Behaviour | Failure mode | Best suited to |
|---|---|---|---|
| Fixed points, one number | Simple and predictable | A cap tuned on gold is meaningless on EURUSD, and differs per broker | Single-symbol EA on one known account |
| Multiple of the symbol's own median spread | Adapts to each instrument automatically | Needs a warm-up sample; distorted in illiquid hours | Multi-symbol portfolios |
| Fraction of the trade's stop distance | Ties cost directly to the trade being taken | Permits wide absolute spreads when stops are wide | Volatility-scaled strategies |
Whichever design you pick, a cap is only meaningful against a specific account: the same EA needs different numbers on a raw-spread account than on a standard one, which is why execution venue is part of testing — see choosing a broker for an EA and our partner list.
Does a zero-trade result mean the EA is worthless?
No, and treating it as a loss is as dishonest as treating it as a win. A zero-trade result carries no information about edge — it only says the test did not execute.
Our catalogue holds 57 backtest records, 48 with a one-year window on a 10,000 USD simulated account at 1:100 leverage, 1 August 2025 to 31 July 2026. Twelve report zero trades; eight are utilities and risk guards that never open a position by design, so a profit gate is meaningless for them. That leaves four trading builds with an unexplained empty result:
| Build | Instrument and timeframe | One-year result | Why it is reported as pending, not as a loss |
|---|---|---|---|
| FX Spread Revert | EURUSD / GBPUSD, H1 | 0 trades | Its edge is spread-sensitive by design; the guard interaction is unresolved |
| Gap Fader | FX and XAUUSD, M15 | 0 trades | Cause not yet isolated |
| Ratio Trend | XAUUSD / XAGUSD, H4 | 0 trades | Multi-symbol: the second leg is not auto-loaded in the tester |
| News Straddle | XAUUSD, M15 | 0 trades | The tester provides no economic calendar for the event schedule |
For contrast, the same harness with the tester-side cap neutralised returns populated results on builds that do execute: Aurora Gold Breakout on XAUUSD H1 recorded 235 trades, profit factor 1.74, 871.22 USD maximal drawdown; Index ORB on USTEC M15, 237 trades at 1.34; Hy3 Grid Recovery on EURUSD H1, 481 trades at 2.62. Historical simulations, not forecasts.
One disclosure belongs with those numbers: relaxing the cap makes the backtest measure the strategy rather than the filter, but it also means the tested trade count is higher than a live account with the real cap would take. The backtest is optimistic on trade frequency, and we would rather say so than ship a filter-shaped result. Compare builds on the compare page or browse the store.
FAQ
Why does my EA work on a demo chart but take zero trades in the strategy tester? Almost always a settings mismatch, not a code fault. The live chart shows a tight real spread that passes the cap, while the tester models a wider one that fails it on every bar. Check the log for order lines first: if there are none at all, the guard rejected the bars before any order existed.
Should I disable the spread filter to get more trades? Not in live trading. Paying more spread than your expected edge turns a positive strategy negative. Relax it in the tester to measure the strategy, keep it enforced live, and disclose that the tested trade count is the optimistic one. See position sizing.
Is a zero-trade backtest a red flag when buying an EA? Only if the seller presents it as a result. A zero-trade run proves nothing either way, so it must be labelled unverified. A vendor showing 0.00 drawdown next to a 0-trade sample and calling it low risk is misrepresenting an empty test. Our verdict: a zero-trade backtest is not a safe EA, it is an untested one, and the only honest label for it is verification pending.
Risk caveat: this article explains EA engineering and test methodology, not expected market outcomes. Every figure quoted comes from historical MetaTrader 5 backtests on a 10,000 USD simulated account and does not predict live results. Backtests overstate execution quality, and a relaxed spread cap overstates trade frequency. Leveraged products can lose more than your deposit. Nothing here is financial advice. Read our full risk disclosure.