Swings and candles each say something; together they say more. The swing highs lows & candle patterns indicator dots every confirmed swing high and low, and adds a signal mark only when a strong reversal candle forms right at that swing. You can drop the candle requirement to see every swing instead.
This build ships as a compiled .ex4 for MT4 and .ex5 for MT5; the screenshots below come from EURUSD H1.
| Platforms | MT4 (.ex4) + MT5 (.ex5) |
|---|---|
| Chart window | Main price chart |
| Plots | 4: Swing High, Swing Low, Buy Signal, Sell Signal |
| Alerts | popup, push notification, email, sound |
| Inputs | 12 |
Which plots exist
Two dot plots and two signal marks.
`Swing High` dots orange red with code 159.
`Swing Low` dots dodger blue with code 159.
`Buy Signal` prints lime with arrow 233.
`Sell Signal` prints red with arrow 234.
A status line reports the settings.
- Swing High: arrow, orange red, width 2, arrow code 159
- Swing Low: arrow, dodger blue, width 2, arrow code 159
- Buy Signal: arrow, lime, width 2, arrow code 233
- Sell Signal: arrow, red, width 2, arrow code 234

What the formula does
The swing
`SwingLen` `3` bars either side confirm a high or low. Every confirmed swing gets a dot, whether or not a signal follows.
The candle
`MinBodyRatio` `0.6` defines a strong candle: a body filling over sixty percent of its range, turning the right way at the swing.
The signal
With `RequireCandlePat` on, only a swing with that candle earns a mark. `SignalCooldown` `3` keeps same-side marks apart.
What the output means
Dots show every swing, marked or not.
Marks show swings confirmed by a candle.
Blue dots sit under lows, orange red over highs.
`ArrowOffsetATR` `0.6` spaces marks by range.
Swings confirm three bars late.
Warm-up needs about seventeen bars.
Alert channels in this build: popup, push notification, email and sound, one message per closed bar.
A swing confirmed by a reversal candle is what reports. `EnableAlerts` is the top switch; the popup and the sound playing `SoundFile` ship on, while push and email wait.
Every Swing Highs Lows & Candle Patterns Indicator input
Core settings
| Setting | What it does | Default |
|---|---|---|
SwingLen |
Fractal half-width (bars each side). Bars either side of a swing, `3`. | 3 |
MinBodyRatio |
Min body/range for a strong candle. Body share for a strong candle, `0.6`. | 0.6 |
ATRPeriod |
ATR period (arrow offset scale). Range window for spacing, `14`. | 14 |
RequireCandlePat |
Require a reversal candle at the swing. Demand a reversal candle, `true`. | on |
SignalCooldown |
Min bars between same-side arrows. Bars between same-side marks, `3`. | 3 |
Display settings
| Setting | What it does | Default |
|---|---|---|
ArrowOffsetATR |
Arrow offset in ATR multiples. Mark gap as a range share, `0.6`. | 0.6 |
Alert settings
| Setting | What it does | Default |
|---|---|---|
EnableAlerts |
Master alert switch. Top switch for swing signals, `true`. | on |
EnablePopup |
Popup alert. Popup, `true`. | on |
EnablePushNotify |
Push to mobile MetaTrader. Push to mobile MetaTrader, `false`. | off |
EnableEmail |
Email alert. | off |
EnableSound |
Sound alert. Sound, ships on, `true`. | on |
SoundFile |
(see inputs panel) | alert.wav |

Fitting the settings to a market
Three-bar swings with a candle filter work on most liquid charts. EURUSD H1 is the reference chart, with a few marks a day. On M5 dots crowd but marks stay sparse. On H4 each mark is a swing worth studying.
The catch
Swings confirm three bars after the fact.
A strong candle at a swing can still fail.
Dots on every swing clutter a long history.
The sound route ships on.
Copy the compiled Swing Highs Lows & Candle Patterns Indicator file into your MQL4/Indicators folder, and the MT5 build into MQL5/Indicators, then restart the terminal and drag it onto a chart. The step-by-step guide with screenshots is at how to install MT4 and MT5 indicators.
Background reading on the method behind the Swing Highs Lows & Candle Patterns Indicator: Candlestick at Investopedia, Candlestick chart on Wikipedia.
Download the Swing Highs Lows & Candle Patterns Indicator for MT4 and MT5
The zip holds the compiled Swing Highs Lows & Candle Patterns Indicator build for MT4 and MT5, plus a short README. Compiled files only, no source. Enter your email below and the download link arrives in your inbox.
Download this indicator free
Enter your email and the file is yours. You also get the full MT4 and MT5 library.
FAQ
Why do some Swing Low dots have no Buy Signal?
Because the dot marks every confirmed swing, but the signal also needs a strong reversal candle there. Swings without that candle stay as dots only.
What does MinBodyRatio 0.6 treat as strong?
A candle whose body fills more than sixty percent of its range and closes in the turning direction. Long-wicked, hesitant candles do not qualify, even when they sit right at a swing.
What changes with RequireCandlePat off?
Every confirmed swing earns a signal mark as well as a dot. That shows all the structure, at the cost of many more marks to sort through.
Why does ArrowOffsetATR follow ATRPeriod 14 instead of points?
So the gap between mark and bar suits the market’s pace. Six tenths of the 14-bar range is a wide gap in fast markets and a small one in quiet ones, so marks never sit on the candle.
Are results guaranteed?
No. Trading involves risk. Results are not guaranteed; past performance is not indicative of future results. Use the Swing Highs Lows & Candle Patterns Indicator as one input. Always backtest before trading live.
Category: this is part of our Candle Sticks collection. Browse more Candle Sticks for MetaTrader, or explore every MT4 indicator and MT5 indicator on the site.
External references
- Learn more about the underlying method in Bureau de change on Wikipedia.
- For wider market background, see Dowtheory at Investopedia.
