Blog / Strategy
Strategy

Equal Highs Shelf Breakout

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 Equal Highs Shelf Breakout is a pure price-action breakout strategy that uses no traditional indicators — no moving averages, no RSI, no ATR. Instead, it reads raw candle data (the open, high, low, and close of each bar) to locate a horizontal "shelf": a price level that the market has tested several times, leaving behind a cluster of near-equal highs (a resistance shelf) or near-equal lows (a support shelf). When a strong momentum candle closes decisively through that shelf, the strategy interprets it as committed order flow rather than a random one-bar spike.

This approach is designed for trending or breakout-prone market conditions, where price coils against a clear level before releasing in one direction. It is less suited to choppy, sideways ranges where false breaks are common. Because every decision is derived from visible structure on the chart, it makes an excellent learning tool for traders who want to understand why a level matters and how a breakout can be defined objectively, without relying on lagging indicators.

If you are studying support and resistance, structure-based stop placement, or fixed risk-to-reward targeting, this strategy gives you a clean, transparent example to dissect. Think of it as a price-action case study you can read line by line — not a shortcut to results.

How It Works

The strategy evaluates conditions only when a bar closes (it acts on completed candles, never on the still-forming bar). On each new bar, it looks back over a window of recent candles to build the shelf, then checks whether the most recently closed bar broke through it.

Building the shelf (the resistance or support level):

Entry conditions — the strategy signals a long when:

The strategy signals a short under the mirror-image conditions: a strong bearish candle closing below a support shelf that was tested the minimum number of times, by more than the buffer.

Stop-loss logic:

Take-profit logic:

Trade management:

equal highs shelf breakout EA
Illustrative example of the strategy’s entry and exit logic — not real trading results.

Strategy Parameters

Parameter Default Min Max Description
LookbackBars 30 12 60 Number of bars used to build the shelf and search for near-equal highs/lows.
MinTouches 3 2 6 Minimum number of near-equal touches required before a level qualifies as a valid shelf.
TolerancePct 0.25 0.05 0.60 How close highs/lows must be to count as "equal," expressed as a fraction of the average bar range.
BreakBufferPct 0.10 0.00 0.50 Extra cushion beyond the shelf that the candle must close past to confirm a breakout, as a fraction of average range.
BodyFraction 0.50 0.20 0.80 Minimum body size as a fraction of the breakout bar's total range, filtering weak or wicky candles.
RiskReward 2.0 1.0 4.0 Take-profit distance as a multiple of the measured risk (stop distance).
Lots 0.10 0.01 1.0 Fixed trade volume in lots.
equal highs shelf breakout EA — MQL5 source code

Recommended Chart Settings

This strategy uses a single primary timeframe and is symbol-agnostic, but it tends to be studied most cleanly on liquid instruments where horizontal levels are well respected — major forex pairs such as EUR/USD or GBP/USD, or major indices. A mid-range timeframe such as the H1 (1-hour) chart is a sensible starting point for observation: it produces enough bars to form meaningful shelves while keeping noise lower than very fast timeframes.

Because the tolerance and buffer scale to the average bar range, the logic adapts somewhat to different instruments automatically. Even so, results will vary considerably across symbols, timeframes, and market conditions. Always test any configuration on historical data and a demo account before drawing conclusions.

How to Install on MetaTrader 5

What to Consider Before Using This EA

Strengths of this approach. The logic is transparent and structure-driven — every entry corresponds to a visible, multi-touch level and a decisive close, which makes signals easy to audit on the chart. The strong-body and buffer filters are deliberate attempts to reduce false breakouts, and the structure-based stop keeps risk tied to the actual level rather than an arbitrary distance. The fixed risk-to-reward target also enforces discipline around exits.

Known limitations. Breakout strategies are vulnerable to "fakeouts," where price closes through a level only to reverse — no filter eliminates these entirely. In ranging or low-momentum markets, the strategy may take repeated losses as levels fail to hold. Because it trades only completed bars and allows one position at a time, it can also miss fast moves or sit idle during quiet periods. The fixed lot size does not adjust to account equity or volatility, so position risk in currency terms can vary from trade to trade.

Where it may underperform. Tight, news-driven whipsaws, illiquid instruments with erratic spreads, and prolonged sideways chop are all conditions where breakout logic historically struggles. Spread and slippage around the moment of a breakout can also widen the real risk versus the modeled risk. Treat this EA as a framework for studying breakout behavior, and validate it thoroughly before relying on any single parameter set.

Risk Management Tips

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

← Back to Blog