MetaTrader 5

Using the Journal in Strategy Tester

Short guide: where to read logs and errors

When backtesting in MetaTrader 5, the Strategy Tester includes a Journal tab that shows messages, errors, and events from your Expert Advisor (EA) or indicator. This is the first place to look when something doesn’t work.

Where to find it

  1. Open the Strategy Tester (View → Strategy Tester or Ctrl+R).
  2. Run a backtest (or start and immediately stop one) so the tester produces output.
  3. Click the Journal tab in the Strategy Tester panel to see logs for that run.

The Journal is separate from the main terminal’s log. Make sure you’re looking at the Strategy Tester’s Journal, which is specific to your backtest session.

What you’ll see

  • Initialization messages (inputs, symbol, timeframe)
  • Trade operations and events
  • Print statements from your code (e.g., Print())
  • Errors and warnings (compile/run‑time)
  • Final summary lines after the test completes

Add Print() statements in your EA or indicator to trace values and decision points. These appear in the Journal and help you debug logic.

Common issues to diagnose

  • No trades executed: conditions never met; check dates/timeframe and your entry logic.
  • “Trade disabled” or order errors: verify input parameters and trading permissions.
  • File/indicator missing: confirm paths, ensure the compiled file exists in the correct folder.
  • Parameter mistakes: review the Inputs tab and ensure types/values are valid.

Workflow suggestions

  1. Run a short backtest window to iterate quickly.
  2. Watch Visualization for context while reading the Journal.
  3. Adjust inputs or code, recompile (F4 → Compile), and re‑run.

If you see repeated errors in the Journal, fix them before trusting any performance metrics. The results can be misleading when errors occur during a test.