Expert Advisors • Indicators • Scripts • Libraries

MQL.RobotFX.org is the biggest collection of MetaTrader expert advisors (MT5 & MT4), indicators, scripts and libraries that can be used to improve trading results, minimize risks or simply automate trading tasks

Metatrader 5 Expert Advisor | Easy Range Breakout EA - MT5 | Source Code Included

Fresh MQL5 code release – perfect for enhancing your MT4/MT5 strategies.

The EA continuously manages the trading session by calculating the start, end, and closing times each day, resetting its variables, and preparing the range for breakout detection. During the defined range period, it collects minute‑based highs and lows, determines the maximum and minimum values, and updates a rectangle object on the chart to visually represent the consolidation zone.


Once the range period ends, it checks the close of the most recent candle (different from the range end time) against the calculated boundaries, and if a breakout is detected, it automatically places a buy or sell order with a take‑profit equal to the size of the range and a stop at the opposite boundary.

Example

Classic MACD strategy made fully automatic – the MACD Expert Advisor for MT4 handles it all. Check it out.

Image for Easy Range Breakout EA - MT5

EURUSD 2026.01.01 - 2026.03.03

Range Start Hour 5

Range End Hour 11

Trading End Hour 22

Image for Easy Range Breakout EA - MT5

Build better strategies with RobotFX professional tools – check them out.

71460

Best MetaTrader Indicators + Profitable Expert Advisors