Category
Risk
Difficulty
Beginner
Used in
Risk managementStrategy designBacktesting

Volatility

Volatility is the degree of price variation over time — how far price moves, not which way. Statistically it is the standard deviation of returns; inside an MT5 EA it is read as Average True Range, and it decides whether last month's stop distance is still right today.

also: market volatility, price volatility

Updated · Reviewed

In plain English

How far price tends to move, not which way. A quiet market and a violent one can end the week at the same price; volatility is the difference between the two journeys.

Why it matters

Every stop distance, target and lot size inside an EA is calibrated against some assumption about how far price moves in a session. Volatility is that assumption made explicit. When it changes after deployment, an EA that was correct becomes wrong without a single line of its logic having changed.

  • It sets the meaning of a stop. Thirty pips is a wide stop on EUR/USD in a quiet August and a tight one on GBP/JPY during a policy announcement.
  • It is the bridge between risk and position size. Risking a fixed percentage of the account means the lot size has to fall as volatility rises, which only happens if the EA measures it.
  • A backtest inherits the volatility of its window, and the window is rarely one regime. On the 22 published ledgers measured here, the most volatile quarter ran a median 2.29 times the calmest, with the same settings throughout.
  • It is the main reason live results drift from backtests without anything breaking. Spreads widen with volatility, slippage grows with it, and both land on the wrong side of the ledger.

How it is calculated

σ = standard deviation of periodic returns · annualised σ = σ_daily × √252
Periodic return
The percentage change from one bar's close to the next, on whatever timeframe the measurement uses.
√252
The scaling from daily to annual. It assumes each period is independent of the last; an intraday system scales by the bars in its horizon (√N) instead.
ATR
Average True Range over N bars — the practical proxy an EA can read directly with iATR, expressed in pips rather than percent.

The statistical definition is the standard deviation of returns, and it is the one used by the Sharpe ratio, value at risk and every risk model. The practical definition inside an EA is Average True Range, which measures the same idea in price units and needs no return series to compute. Two figures called 'volatility' are often these two different things.

What counts as high or low

  • under 0.75 × tested-window σ Calmer than the tested window — targets go unreached and repeated small costs dominate
  • 0.75–1.25 × tested-window σ The regime the settings were tuned in. On the published ledgers, 282 of 375 quarters sat here
  • 1.25–2 × Elevated — stops sized for the tested window start being hit by ordinary bars
  • over 2 × A different regime. Only 2 of 22 published ledgers had a quarter this far above their whole-window σ

Read it together with

No single number describes a strategy. These metrics change how this one should be read.

Example

A worked illustration: the same EA runs a 30-pip fixed stop through two regimes. Only the size of an ordinary hourly move changes.

Quiet regime — ATR(14) on H1
12 pips
A 30-pip stop sits 2.5 average ranges away — comfortably outside the noise.
Volatile regime — ATR(14) on H1
34 pips
The same stop is now inside a single average bar, so ordinary movement closes the trade.
ATR-based stop at 2.5 × ATR, quiet
30 pips
ATR-based stop at 2.5 × ATR, volatile
85 pips

The ATR-based version widens with the market — but the lot size must then shrink with it.

Calculation 30 ÷ 12 = 2.5 ranges · 30 ÷ 34 = 0.88 ranges

Result A fixed stop changes meaning by a factor of nearly three; an ATR-based stop does not

How to interpret it

  • Prefer volatility-scaled stops to fixed pip distances when a strategy runs unattended across years — but scale the lot size by the same measure, or a wider stop simply means a larger loss.
  • Treat a volatility spike as a spread and slippage event, not only a price event. Execution costs rise with it, and they rise fastest at exactly the moments a stop is most likely to be hit.

mt5depot EA pages state the tested window and the data source for each listing, so whether a result spans more than one regime can be read from the dates. Every measured figure on this page comes from those listings' published trade ledgers (EXP-VOL-REGIME-001), closed-trade basis.

Common mistakes

Treating volatility as direction

High volatility says price is moving a lot, not that it is moving up. Trend and volatility are separate measurements — a violent range is high-volatility and trendless at the same time.

Treating volatility as loss

On the published ledgers the most volatile quarter of an EA's daily P/L was profitable on 13 of 22, and the worst single day fell outside that quarter on 15 of 22. A filter that switches the EA off in high volatility would have sat out that quarter and still missed most of the worst days.

Widening the stop without shrinking the lot

An ATR-based stop that triples in a volatile regime triples the money at risk unless position size falls with it. The adaptive stop only helps when it is paired with adaptive sizing.

In depth

Where volatility enters the MT5 Strategy Tester

The tester never prints a volatility figure. Three of its settings decide how much of it reaches the report.

Modelling. Every tick based on real ticks replays the recorded path inside each bar, so a stop inside an ordinary bar is hit when it would have been hit. Every tick generated from M1 bars interpolates that path, and Open prices only discards it. A strategy whose stop is narrower than the bar range cannot be judged on either — see tick data and modelling quality.

Spread. Strategy Tester → Settings → Spread offers Current or a fixed number of points. Both pin one value across years, so the widening that arrives with a volatility spike is absent from a generated-tick test. On real ticks the spread is whatever the tick file carried.

Inputs. An ATR-sized stop exposes two inputs on the Inputs tab, the period and the multiplier. A multiplier that works at 2.0 but not at 1.8 or 2.2 has been fitted to one window’s retracements, not to volatility. In MQL5 the handle is created once with iATR(_Symbol, PERIOD_CURRENT, 14) in OnInit. The value is read from the last completed bar, index 1, so the stop distance does not depend on when the signal fired. The ATR entry has the settings.

What 22 published ledgers show

Each listing carries its closed-trade list, so the σ of an EA’s own daily P/L can be measured by calendar quarter and compared with the whole window. Two of 24 listings never reach 10 active days in any quarter and were skipped, not padded.

Measure (closed-trade basis, quarters with 10+ active days)Median across 22 EAsRange or count
Qualifying quarters per EA15.5375 in total
Regime span: most volatile quarter σ ÷ calmest quarter σ2.29×1.25× to 5.33×
EAs whose regime span exceeds 2×15 of 22
Quarters within ±25% of the whole-window σ78.76%282 of 375
Worst single day inside the most volatile quarter7 of 22
Most volatile quarter lost money9 of 22
Last qualifying quarter σ ÷ whole-window σ0.91×below 1 on 17 of 22

Two rows contradict what a volatility filter assumes. The worst day landed outside the most volatile quarter on 15 of 22 EAs, and that quarter made money on 13 of 22. A single bad day is not a regime, and a rolling measure does not see it coming.

The widest span belongs to Murmuration: a quarterly σ of 4.591% in 2026-Q1 against 0.862% in the next quarter, 5.33 times apart with identical settings. Its worst day, 9.579% on 2020-03-18, sat six years earlier in a calmer quarter.

What to do with the number

Read the regime, not the level: compare today’s ATR with the ATR over the tested window, on the timeframe the EA trades.

  1. Take the tested window’s start and end dates from the listing, and the timeframe the EA runs on.
  2. Attach Average True Range, period 14, to a chart of that timeframe and read the last completed bar. That is the deployment ATR.
  3. For the window average, read the same indicator across the tested dates with CopyBuffer(handle, 0, 1, bars, array) and average the array.
  4. Divide. Inside 0.75–1.25 the published figures apply; past 2 you are in a regime the tested window may not contain — only 2 of 22 ledgers here had a quarter that far above their whole-window σ.

Running a backtest in MT5 covers the settings above, and parameter optimisation the neighbouring-values check for an ATR multiplier. How a spike turns into money is the subject of position sizing, slippage and maximum drawdown.

Frequently asked questions

How does volatility affect an MT5 EA?
It changes the meaning of every distance the EA uses. Stops and targets set in fixed pips become tight when volatility rises and loose when it falls, so the same settings produce a different strategy in a different regime. Spread and slippage grow with it too.
What is a normal volatility level for a strategy?
There is no useful absolute number; the reading that matters is current conditions against the window the strategy was tested in. On the 22 published ledgers, a median 78.76% of quarters sat within 25% of the whole-window figure. The rest is the part of the backtest a fixed setting was not tuned for.
Does the MT5 Strategy Tester model volatility?
It replays it; it does not model it. 'Every tick based on real ticks' replays the recorded intra-bar path, while the generated-tick modes interpolate inside each bar and the open-prices mode discards intra-bar movement. The spread setting matters as much. 'Current' pins one value across the whole test, so the widening that arrives with a spike is absent from the report unless the tick file carried it.
Is high volatility good or bad for EAs?
It depends on the strategy. Breakout and trend systems generally need movement to work and stall in quiet markets, while mean-reversion and grid systems prefer calm and are damaged by sustained trends. The problem for both is a change in regime after the settings were fixed.