FX NOOKAI CODE LAB
Loading

MT5 Strategy Tester Not Working: Causes and Fixes

By FXNook Lab team

Trading desk set up for troubleshooting an MT5 strategy test

If the MT5 Strategy Tester is not working, first identify whether it will not start, stalls or fails during a run, completes without trades, or finishes with unexpected results. Those symptoms have different causes: the EA or test configuration can block a launch, missing history or a tester agent can interrupt a run, and a completed test with no trades often points to the EA’s rules or order requests rather than a broken tester.

Start with a short, single test and use the Strategy Tester’s Journal to see what happened. Then change one setting at a time. This makes it easier to tell whether the problem is the symbol, date range, data, agent, or EA itself instead of changing several things and losing the clue.

Identify what “not working” means

Open the Strategy Tester with Ctrl+R or from the View menu. Select the EA, symbol, timeframe and test dates, then run a single test rather than an optimization. The symptom-to-check table below gives you a useful first step before you change anything else.

SymptomFirst place to lookLikely next action
The test will not startTester Settings and JournalVerify the EA, symbol, dates and selected testing mode.
The test starts but stalls or stopsTester Journal and Agents tabTry a shorter period with one available local agent.
The test completes with no tradesTester Journal, EA inputs and trading logicFind out whether the EA reached an entry and whether an order was rejected.
The result looks wrongModeling mode, history and EA inputsRepeat a controlled test with the same data and settings.

A tester problem means the run could not initialize, load its required data, or complete as expected. A test that completes normally but shows zero trades is a different case: the EA may have run correctly and simply found no entry under the tested conditions. Keep that distinction in mind while reading the log.

Check the EA, symbol, timeframe and date range

In Tester Settings, make sure the selected Expert Advisor is the one you intend to test. If it is missing from the list, compile the correct .mq5 file in MetaEditor, resolve any compilation errors, and return to the tester. A successful compile only means MetaEditor accepted the code; it does not show that the EA’s trading logic will produce trades.

Select a symbol that is available in your broker’s MT5 terminal and a timeframe the EA is designed to use. Some EAs trade the chart symbol, while others read additional symbols or timeframes in their code. If the EA requires those extra series, an unavailable symbol or missing history on that series can prevent the expected calculations or signals.

Choose a date range that is valid and not wider than necessary for the first run. Make sure the end date is after the start date and that the broker has usable history for that period. A range far back in time may have incomplete tick or bar data, while a very long test can take much longer to process than a short diagnostic run.

Also inspect the EA’s Inputs tab. A date filter, trading session, maximum spread, minimum volatility, or other filter may rule out every entry in the selected period. For example, an EA that only trades during a particular server-time window may show no activity if the chosen dates or symbol history do not contain qualifying conditions during that window.

For a first diagnostic run, use one symbol and one timeframe, leave the EA’s normal input values in place, and choose a short period where the symbol has data. If that test starts and completes, broaden the date range later. If it does not, the Journal can help distinguish a configuration problem from an EA initialization problem.

Fix history, download and modeling problems

MT5 can test using different price models, and the selected mode affects both the data needed and how the EA is evaluated. Depending on the tester setup, the modeling choices include Every tick based on real ticks, Every tick, 1 minute OHLC, and Open prices only. Use a mode appropriate to the EA’s logic: a strategy that reacts to intrabar price changes cannot be meaningfully checked with a model that only evaluates bar opens.

Open the tester’s Journal and look for messages about missing history, ticks, or a symbol that cannot be synchronized. Also check that the symbol is selected and visible in Market Watch. If the broker provides history for the period, opening the relevant chart and requesting or loading more bars can help the terminal obtain it; then rerun the test and inspect the Journal for data-loading messages.

A test may take time before the first tick or bar is processed while MT5 obtains and prepares data, especially for a long period or a tick-based model. Give a short test a reasonable chance to initialize, but do not treat an indefinite stall as proof that the tester is still working. The Journal and agent status provide better evidence than the progress display alone.

Incomplete history can produce a test that fails to cover the intended period, or a result that differs when the missing data becomes available. Different modeling modes can also produce different simulated entries and exits. When comparing runs, keep the symbol, dates, EA inputs and modeling mode the same, and record any change you make so the results are comparable.

If the selected period still has data problems, shorten it to a recent interval that the broker supports and run again. Once that test completes, extend the period in stages. This helps isolate whether the problem is tied to a particular historical segment or to the tester configuration as a whole.

Check tester agents and resource settings

MT5 uses tester agents to execute tests. In the Strategy Tester, open the Agents tab and see whether local agents are available and active. If there is no usable local agent, or an agent appears to stop responding, a test may remain idle or fail to progress even though the EA and test settings are valid.

For diagnosis, choose a single test rather than an optimization and reduce the workload. Turn off visual mode for the initial run, use a short date range, and disable unused tester agents if the agent list or settings allow it. Then start the test again and watch both the Journal and Agents tab.

Optimization multiplies the work because MT5 runs the EA repeatedly with different input combinations. A wide date range, tick-based modeling, many input combinations and a large number of agents can put a heavy load on the computer. If an optimization appears stuck, stop it and first establish that one ordinary test completes with the same EA, symbol and period.

Other software or a system with limited free resources can also slow test execution. Close unnecessary visual charts or heavy applications and retry the small test. If the single-agent test completes but an optimization does not, the problem is more likely workload or agent configuration than a basic inability to run the EA.

Use the Journal and Experts tabs to find the cause

The Strategy Tester’s Journal is the main place to trace a run from setup through initialization and execution. Read the messages around the time the test was started, not just the last line: an earlier message may explain why a later step failed. For details about EA activity, the tester’s Experts output and the terminal’s Experts tab can also be useful, depending on the MT5 build and where the message was written.

Agent-specific messages are available from the Agents tab. When a message names an agent or reports a load or execution problem, compare it with the main tester Journal. This helps separate an EA error from a problem starting or using the agent that runs the test.

Log clueWhat it can indicateNext check
EA failed to initialize or initialization returned failureThe EA stopped during its setup routine.Inspect the EA’s startup logic, required inputs, symbol data and any initialization messages it prints.
Cannot load or open the Expert AdvisorThe selected program may be unavailable, incorrectly compiled or not the file you expected.Compile the intended .mq5 file and select that EA in Tester Settings.
History or tick data is unavailableThe tester may not have the required price series for that symbol or period.Load available history, shorten the test period, and rerun with a suitable modeling mode.
Agent stopped, disconnected or failed to executeThe test worker may have stopped or run out of available resources.Try one local agent, a single test and a shorter date range.
Order request rejectedThe EA ran far enough to request a trade, but the request did not pass a trading rule or broker constraint.Read the rejection details and inspect volume, stops, filling mode, trading permissions and symbol constraints.
Test completed with no dealsThe EA may not have generated a valid entry during that test.Review inputs, filters and the EA’s entry conditions before treating the tester as failed.

Not every error line means the Strategy Tester itself is broken. For example, an order rejection usually means the EA submitted a request that did not meet the applicable conditions. In MT5, the reason may involve the symbol’s volume limits or step, stop-distance requirements, the order filling mode, or whether trading is permitted for that EA in the test.

Look for the first relevant error, then follow the messages that come after it. A later “test finished” line does not erase an earlier initialization or order error. Conversely, a normal completion message with no error and no trades points you toward the EA’s rules and tested conditions, not a failed test engine.

If the test runs but opens no trades

A completed test with no trades is often a trading-logic issue, not a tester failure. The EA may not have found a signal, or one of its filters may have rejected every candidate entry. Compare the inputs with the tested symbol and period, then look for conditions such as trading hours, spread limits, trend filters, minimum bars, or required indicator values that may never have been met.

Check whether the EA is allowed to trade in its tester properties, particularly if it relies on algo trading permissions or other features controlled by the test configuration. Then inspect the EA’s log messages for evidence that the entry logic was reached. If there is no message or trace indicating that a signal was evaluated, the code may be returning before it reaches the trade request.

If an order request appears in the log but no position or deal follows, treat it as an execution or request issue. The tester may report that a request was rejected because the EA used a volume outside the symbol’s permitted range, placed stops too close, selected an unsupported filling mode, or otherwise failed a trading condition. The EA’s request and the returned result need to be read together; a call to a trade function does not by itself prove that an order was accepted.

For a deeper guide to an EA that compiles but does not trade, see MT5 EA Not Taking Trades: Checks, Causes, and Fixes. If you need to trace the conditions inside your own program, the FXNook EA debugger can follow the entry logic and explain what blocks it; it can also make a requested fix as a new version.

Verify the fix with a controlled rerun

After changing a setting or correcting an EA problem, rerun the same small test before restoring a larger workload. Keep a note of the original settings and change only one variable at a time. If the symptom changes, you have a stronger indication of which adjustment mattered.

  1. Use one EA, one symbol and one timeframe. Make sure the EA selected in Tester Settings is the compiled program you intend to run.
  2. Choose a short, supported date range. Confirm that the broker has history for the selected period and that the start and end dates are valid.
  3. Run a single test on one local agent. Turn off optimization and visual mode until the basic test completes.
  4. Keep the modeling mode and EA inputs consistent. Choose a mode suited to the strategy and avoid changing inputs during the diagnostic comparison.
  5. Read the result and logs together. Confirm that the run completed, then inspect the deals and Journal to see whether the EA initialized, evaluated entries, and submitted or rejected any requests.
  6. Restore broader settings gradually. Extend the period, enable visual mode if needed, or return to optimization only after the controlled run behaves as expected.

A reliable diagnosis comes from matching the symptom to the evidence: tester startup messages for a launch failure, data and agent messages for a stalled run, and EA or order messages for a completed test without trades. If the code itself does not compile, use MetaEditor to fix that first; the MQL4/MQL5 error fixing page explains how the Lab handles compile errors and verifies the resulting code.

Your practical next step is to run the short, single-agent test and read the Journal from the first startup message onward. Once that test completes, you can expand the dates or workload with a clear baseline; tested results do not guarantee future trading results.

Questions

Why does the MT5 Strategy Tester stop before the test starts?

The usual causes are an incorrect or unavailable EA selection, invalid test dates, missing symbol history, or no working tester agent. Open the Strategy Tester Journal and Agents tab to find which setup stage failed, then retry with a compiled EA, a short supported date range, and one local agent.

Why does my MT5 backtest finish but show no trades?

The tester can complete normally even when the EA never finds a qualifying entry. Review its inputs, date and session filters, symbol and timeframe assumptions, and Journal messages for rejected trade requests; zero trades alone does not show that the tester failed.

Where can I find Strategy Tester error messages in MT5?

Start with the Journal in the Strategy Tester, which records setup and run messages. For EA activity, inspect the tester’s Experts output or the terminal’s Experts tab, and use the Agents tab when the log points to a local tester agent.