Home > EA & MT5 Knowledge Base > How to Backtest

BacktestMT5

How to Run a Backtest with MT5 Strategy Tester

Updated: May 15, 2026

What is Backtesting?

Backtesting is the process of running an EA against historical market data to verify the effectiveness of a strategy. MT5 comes standard with a powerful backtest function called the Strategy Tester.

Without using real funds, you can check EA performance against years of historical data, making it an important step before running an EA on a live account.

Even if a backtest shows good results, it does not guarantee future profits. Use backtesting only as a reference.

Opening the Strategy Tester

Here's how to open the Strategy Tester in MT5.

  • Method 1:Click 'View' → 'Strategy Tester' from the top menu
  • Method 2:Use the keyboard shortcut 'Ctrl + R'
  • Method 3:Click the 'Strategy Tester' button in the toolbar

The Strategy Tester panel will appear at the bottom of the screen.

Backtest Settings

SettingRecommendedDescription
Expert AdvisorGOLD_EMA_ATR_EASelect the EA to test
Symbol (Currency Pair)XAUUSDSelect GOLD
TimeframeH1 (1 hour)Set to match the EA design
ModelEvery TickHighest accuracy (takes longer)
PeriodCustomSet the period to test (e.g., 2020-2025)
Initial Balance10000Virtual initial capital ($10,000, etc.)
CurrencyUSDMatch your account currency
Spread30-50 (XAUUSD)Set a value close to the actual spread
'Every Tick' mode is most accurate but takes longer. We recommend first checking quickly with 'Control Points', then verifying with 'Every Tick'.

Running the Backtest

  1. 1.Once settings are complete, click the 'Start' button
  2. 2.A progress bar will appear and the backtest will begin
  3. 3.After completion, a list of all trades will appear in the 'Results' tab
  4. 4.In the 'Graph' tab, you can view a chart of asset progression
  5. 5.In the 'Report' tab, you can check detailed statistical information

Reading the Results

MetricDescriptionTarget
Net ProfitTotal profit during the backtest periodShould be positive
Win RatePercentage of profitable trades out of all trades50%+ as a guideline
Profit Factor (PF)Total profit ÷ Total loss1.5+ recommended
Maximum Drawdown (DD)Maximum decline in assets10% or less recommended
Sharpe RatioReturn-to-risk ratio1.0+ desirable
Total TradesNumber of trades during the backtest periodToo few = low reliability
Max Consecutive LossesMaximum number of consecutive lossesCheck if you can tolerate this psychologically