Disclaimer: This article is for educational and informational purposes only. It does not constitute financial or investment advice. Trading forex and CFDs carries significant risk of loss. Past performance of any strategy — including backtests — does not guarantee future results. Never trade with money you cannot afford to lose.
What Is This Strategy?
The Atr Scaled Momentum Shift is a volatility-normalized momentum strategy that combines a rate-of-change momentum reading with the Average True Range (ATR) — a common measure of how far price typically moves in a given period — and an Exponential Moving Average (EMA) trend filter. Instead of asking "how many pips has price moved?", it asks a more portable question: "how many average ranges has price travelled?" This is why the word "scaled" appears in its name — raw momentum is divided by current ATR so the signal means the same thing whether you are looking at a quiet range or a fast-moving trend.
This normalization matters because a 30-pip move is a big deal in a calm session but barely noticeable during a volatile news-driven day. By expressing momentum in ATR units, the same numeric threshold stays meaningful across FX majors, gold (XAUUSD), and index CFDs, and across quiet versus volatile regimes. The strategy follows a trend-following momentum-continuation style: it only arms a directional trade when normalized momentum thrusts through a threshold and price agrees with the EMA trend direction.
As a learning tool, the Atr Scaled Momentum Shift is well suited to traders who want to understand how volatility scaling, trend filtering, and ATR-based risk controls fit together in a single automated system. It was designed with M15 to H1 majors and XAUUSD in mind, though the timeframe is never hardcoded — it uses whatever chart you attach it to. This article is a strategy analysis intended to explain the mechanics, not a profit opportunity.
How It Works
The Atr Scaled Momentum Shift evaluates its logic only on closed bars (it is non-repainting), using the currently forming bar solely to detect when a new bar has opened. Here is how the strategy signals and manages a trade, step by step.
Calculating the core signal:
- On each newly closed bar, the strategy computes the EMA (trend filter), the ATR (volatility), and the net price change over the momentum lookback period.
- It divides that net price change by the current ATR to produce normalized momentum — momentum expressed in "ATR units."
- It compares this reading against the previous bar's reading to detect a crossing through the threshold, rather than simply being above or below it.
Long entry conditions (all must be true):
- Normalized momentum crosses up through the positive threshold (
+MomThreshold). - The last closed price is above the EMA trend filter (trend agrees to the upside).
- No position is currently open, the cooldown period has elapsed, and ATR is above the optional dead-market floor.
Short entry conditions (all must be true):
- Normalized momentum crosses down through the negative threshold (
-MomThreshold). - The last closed price is below the EMA trend filter (trend agrees to the downside).
- The same one-position, cooldown, and ATR-floor filters are satisfied.
Stop-loss and take-profit logic:
- When a trade opens, the stop-loss is placed at a distance of
SlAtrMult × ATRfrom entry, and the take-profit atTpAtrMult × ATR. With the defaults (1.8 and 3.0), this creates a fixed reward-to-risk structure of roughly 1.67:1. - Because both levels scale with ATR, the strategy automatically widens its stops in volatile conditions and tightens them in quiet conditions.
Trailing-stop logic:
- Once an open trade moves in your favor by at least
TrailStartMult × ATR, an ATR trailing stop activates. - The trailing stop is set
TrailAtrMult × ATRbehind price and only ratchets in the favorable direction — it never loosens. A small buffer prevents it from being nudged by tiny fluctuations.
Trade management rules:
- Only one position at a time is allowed.
- A cooldown of a configurable number of bars must pass between entries to avoid churn.
- Position size uses a fixed base lot, with optional gentle equity compounding when
RiskPercentis greater than zero.

Strategy Parameters
| Parameter | Default | Min | Max | Description |
|---|---|---|---|---|
| TrendPeriod | 50 | 20 | 200 | EMA period for the trend filter. Higher values track slower, longer-term trends. |
| AtrPeriod | 14 | 7 | 30 | Lookback for the ATR volatility measure used in normalization and risk sizing. |
| MomPeriod | 10 | 3 | 40 | Number of bars over which net price change (momentum) is measured. |
| MomThreshold | 1.0 | 0.3 | 3.0 | Momentum thrust threshold in ATR units. Higher values require stronger moves to trigger. |
| SlAtrMult | 1.8 | 0.8 | 4.0 | Stop-loss distance as a multiple of ATR. |
| TpAtrMult | 3.0 | 1.0 | 6.0 | Take-profit distance as a multiple of ATR. |
| TrailStartMult | 1.2 | 0.3 | 4.0 | Profit in ATR units required before the trailing stop activates. |
| TrailAtrMult | 1.5 | 0.5 | 4.0 | Trailing-stop distance behind price, as a multiple of ATR. |
| CooldownBars | 2 | 0 | 20 | Minimum number of bars to wait between entries. |
| Lots | 0.10 | 0.01 | 2.0 | Base trade volume in lots. |
| RiskPercent | 0.0 | 0.0 | 5.0 | Equity compounding factor. 0 keeps lots fixed; higher values scale gently as equity grows. |
| MinAtrPoints | 0.0 | 0.0 | 50.0 | Dead-market ATR floor. 0 disables it; otherwise entries are skipped when ATR is too low. |

Recommended Chart Settings
The Atr Scaled Momentum Shift was designed with M15 to H1 timeframes on FX majors and XAUUSD (gold) in mind, and its volatility normalization makes the same threshold meaningful on index CFDs as well. That said, the timeframe is never hardcoded — the EA operates on whatever chart you attach it to, so you are free to test other combinations. Because momentum-continuation systems behave very differently across trending, ranging, and news-driven conditions, results will vary considerably across symbols, timeframes, and market regimes. Always test any configuration on your own broker's data before drawing conclusions.
How to Install on MetaTrader 5
- Download the
AtrScaledMomentumShift.ex5file from the link below - Copy it to your MT5
MQL5\Expertsfolder - Restart MetaTrader 5 or refresh the Navigator panel
- Drag the EA onto a chart matching the recommended symbol and timeframe
- Configure the input parameters and enable Algo Trading
What to Consider Before Using This EA
Like every approach, the Atr Scaled Momentum Shift has strengths and limitations that are worth understanding before you rely on it.
Strengths of this approach:
- Cross-market consistency. Expressing momentum in ATR units keeps the threshold meaningful across different instruments and volatility regimes, which is harder to achieve with raw pip-based momentum.
- Built-in risk framework. ATR-scaled stops, a fixed reward-to-risk structure, and a one-way trailing stop are integrated rather than bolted on afterward.
- Non-repainting design. Decisions use only closed bars, so a signal seen in a backtest reflects what would have been available live.
Known limitations:
- Whipsaws in ranging markets. Momentum-continuation systems can generate false crossings when price chops sideways around the EMA. The cooldown and ATR floor reduce, but do not eliminate, this.
- Trend-filter lag. The EMA reacts to price after the fact, so entries may arrive later than a discretionary trader would prefer, and sharp reversals can catch the filter offside.
- Single-position exposure. Trading one position at a time is disciplined but means the strategy may sit out of otherwise valid setups while a trade is open.
- Parameter sensitivity. Thresholds, multipliers, and periods that historically suited one symbol may not transfer to another. This is a tool for study and testing, not a set-and-forget solution.
The strategy may underperform during low-volatility drift, choppy consolidations, and abrupt sentiment reversals — conditions where momentum signals frequently misfire.
Risk Management Tips
Sound risk management matters more than any single entry rule. Consider these general principles as part of your education:
- Risk a small fraction per trade. Many educators suggest risking no more than 1–2% of account equity on any single position, so that a string of losses does not threaten your capital.
- Size positions deliberately. Use the
LotsandRiskPercentinputs thoughtfully, and understand how ATR-based stops translate into actual monetary risk on your account and instrument. - Test on a demo account first. Run the EA in a demo environment across different market conditions before considering any live use.
- Understand drawdown. Every strategy experiences losing streaks. Know the historical drawdown of your configuration and ask whether you could tolerate it emotionally and financially.
- Never risk money you cannot afford to lose. Leverage magnifies both gains and losses.
Risk Warning
Trading foreign exchange, CFDs, and other leveraged financial instruments involves substantial risk of loss and is not suitable for all investors. The strategies and tools discussed on this page are provided for educational purposes only and do not constitute financial advice, investment recommendations, or solicitation to trade. Always consult a qualified financial adviser before making trading decisions. Past backtest performance is not indicative of future results.
Downloads
- Expert Advisor: AtrScaledMomentumShift.ex5 (0 downloads)
- Source Code: AtrScaledMomentumShift.mq5 (1 downloads)
- Documentation: AtrScaledMomentumShift.pdf (1 downloads)