Pro RSI Divergence Breakout Hidden Signals Filter
- Индикаторы
- Версия: 2.1
- Активации: 5
RSI Divergence Breakout Pro – Regular and Hidden Divergence + Trendline Breakout Multi-Filter for MT5
RSI Divergence Breakout Pro finds disagreement between price and RSI, then turns that setup into a visual signal on the MetaTrader 5 chart. It marks Regular and Hidden divergences, draws the connecting line, and can print a separate Breakout Buy or Breakout Sell arrow when price closes through that line.
All confirmation filters are optional and off by default. You can use raw divergence only, or enable one or more filters until the signal matches your trading style.
This product is an indicator. It does not open, close, or manage trades automatically.
PRODUCT TYPE
Type: Technical Indicator
Platform: MetaTrader 5
Chart location: Main chart window
Markets: Forex, Gold, Indices, Crypto, Oil, Stocks, and CFDs
Timeframes: All. Common working timeframes are M15, M30, H1, and H4
Trading styles: Swing, intraday, pullback, reversal, and breakout confirmation
Version: 2.01
Signals: Bullish divergence, Bearish divergence, Breakout Buy, Breakout Sell
Alerts: Popup, sound, and mobile push notification
WHAT THE INDICATOR DOES
The indicator works in three stages on one chart:
1. It detects Regular and Hidden RSI divergences on confirmed swing pivots.
2. It can draw a trendline between the two swing points so the structure is visible.
3. It watches that line and can print a Breakout Buy or Breakout Sell arrow when the last closed bar crosses it, if the selected filters still pass.
Many divergence tools only mark the pivot. The extra layer here is the second confirmation: the close through the divergence line after the setup already exists.
WHY THE FILTER MODULE MATTERS
Filters are modular. Enable only what you need. If several filters are enabled, all of them must pass at the same time.
That lets you keep the chart clean on higher timeframes, or keep more signals on lower timeframes by using fewer filters.
No indicator wins every trade. This tool organizes divergence and confirmation. Position size, stop loss, and news handling remain the trader's responsibility.
KEY FEATURES
Regular RSI Divergence
Bullish: price makes a lower low while RSI makes a higher low.
Bearish: price makes a higher high while RSI makes a lower high.
Use: weakening momentum after a push, often near a possible turn.
Hidden RSI Divergence
Bullish: price makes a higher low while RSI makes a lower low.
Bearish: price makes a lower high while RSI makes a higher high.
Use: pullback continuation in the direction of the existing move.
Pivot confirmation
A swing is accepted only after the left-side and right-side bars confirm it. This reduces many premature marks that appear on an unfinished candle.
Lookback search
The previous matching pivot is searched inside the Lookback window, so pairs stay related to recent structure.
Divergence trendlines
Optional lines connect the two price pivots. Bullish lines are lime. Bearish lines are red. Lines do not extend as a ray into the future.
Trendline breakout arrows
After a stored divergence, the line is projected to the latest closed bar. Breakout Buy needs a close above the line after the previous close was at or below it. Breakout Sell needs the opposite.
Alert system
Popup, wav sound from the MT5 Sounds folder, and push to the MetaTrader mobile app. Repeat messages on the same bar are limited.
Four separate plots
Bullish Divergence, Bearish Divergence, Breakout Buy, and Breakout Sell can be shown or hidden independently from the Colors tab.
HOW THE LOGIC WORKS
Step A. RSI is calculated with the divergence RSI period (default 8).
Step B. The engine scans completed bars and marks a pivot high or pivot low when that bar is stronger than Swing_Left bars to the left and Swing_Right bars to the right.
Step C. It searches older bars inside Lookback for the previous pivot of the same type.
Step D. It compares price against RSI to classify Regular Bull, Regular Bear, Hidden Bull, or Hidden Bear.
Step E. If the pattern is valid and the selected filters pass, an arrow is printed and the pair is stored.
Step F. If Show_Breakout is enabled, each stored pair is watched. When the newest closed bar crosses the projected line and filters still pass, a breakout arrow is printed and that pair is marked as used.
Alerts and breakout checks use closed-bar data (bar index 1), which is the correct approach for closed-bar confirmation.
VISUAL GUIDE
Aqua upward arrow: Bullish Regular or Hidden Divergence
Red downward arrow: Bearish Regular or Hidden Divergence
Dodger Blue arrow: Breakout Buy from a bullish divergence line
Magenta arrow: Breakout Sell from a bearish divergence line
Lime trendline: Bullish divergence structure
Red trendline: Bearish divergence structure
Arrow distance from the high or low is controlled by Arrow_Offset in points. Breakout arrows use a larger offset so they do not sit on top of the divergence arrow.
FULL INPUT GUIDE
Read this section before attaching the indicator to a live chart. Every name below is an input in the MT5 Inputs tab.
DIVERGENCE SETTINGS
RSI_Period
RSI length used only for divergence comparison. Default 8. Lower values react faster and create more pairs. Higher values such as 14 or 21 are smoother and usually fewer.
RSI_Price
Applied price for divergence RSI. Default PRICE_CLOSE. Close is the standard starting point.
Swing_Left
How many older bars must be weaker than the candidate pivot. Default 3. Raise to 5-7 if you want only major swings.
Swing_Right
How many newer bars must confirm the pivot. Default 3. This is the confirmation delay. Larger values mean later but cleaner pivots.
Lookback
Maximum bars searched for the previous pivot. Default 80. Too small misses valid pairs. Too large can pair a new swing with a very old unrelated swing.
Show_Regular
Master switch for classic reversal divergences.
Show_Hidden
Master switch for continuation divergences.
Show_Breakout
Master switch for Breakout Buy and Breakout Sell arrows.
Draw_Trendline
Creates chart objects named DivTL_0, DivTL_1, and so on. Turn off if the chart already has many objects or you only want arrows.
Alert_On
MT5 popup alert when a new confirmed signal is accepted.
Sound_On
Plays the selected wav file.
Sound_File
File name inside the MT5 Sounds folder. Default alert.wav. You may use any wav already installed there.
Push_On
Sends a push to the mobile app. Enable push in Tools > Options > Notifications and use a valid MetaQuotes ID.
Arrow_Offset
Distance of divergence arrows from the high or low, in points. Default 30. On Gold, indices, or crypto you may need a larger value.
RSI CROSS FILTER
Use_RSI_Cross_Filter
Off by default. When on, a buy-side signal needs RSI to cross up through Oversold. A sell-side signal needs RSI to cross down through Overbought.
RSI_Length
Period for this filter RSI. Default 14. This is separate from the divergence RSI period.
RSI_Price_Source
Applied price for the filter RSI.
Oversold
Buy cross level. Default 30.
Overbought
Sell cross level. Default 70.
Benefit: keeps signals nearer exhaustion zones instead of mid-range chop.
ADX FILTER
Use_ADX_Filter
When on, both buy and sell require ADX at or above ADX_Min_Level.
ADX_Period
Default 10.
ADX_Min_Level
Default 20. Raise to 25-30 if you only want stronger trends.
Benefit: reduces signals during flat, directionless markets.
SINGLE MA FILTER
Use_MA_Filter
Buy only if close is above the moving average. Sell only if close is below it.
MA_Period
Default 50.
MA_Method
SMA, EMA, SMMA, or LWMA. Default SMA.
MA_Shift
Forward or back shift. Default 0.
Benefit: simple trend bias against the selected average.
ICHIMOKU SENKOU SPAN B FILTER
Use_Ichimoku_Filter
Compares close with Senkou Span B only. It does not use the full Ichimoku system.
Ichimoku_SenkouB
Senkou Span B period. Default 52.
Ichimoku_Kijun
Kijun period passed into the Ichimoku handle. Default 26. Needed because MT5 builds Ichimoku with Tenkan 9, Kijun, and Senkou B.
Benefit: uses the slower cloud boundary as a bias on the same chart.
RSI 75 FILTER
Use_RSI75_Filter
Buy if the long-period RSI is above 50. Sell if it is below 50.
RSI_Filter_Period
Default 75.
Benefit: slow momentum regime filter, useful on H1 and H4.
DOUBLE MA FILTER
Use_DoubleMA_Filter
Buy if MA A is above MA B. Sell if MA A is below MA B.
MA_A_Period / MA_A_Method / MA_A_Applied / MA_A_Shift
Fast line. Default 30 EMA on close.
MA_B_Period / MA_B_Method / MA_B_Applied / MA_B_Shift
Slow line. Default 140 EMA on close.
Benefit: classic two-average trend stack.
AWESOME OSCILLATOR FILTER
Use_AO_Filter
Master switch for Awesome Oscillator. The sub-options below work only if this is true.
Use_AO_Volume_Filter
Buy needs AO greater than or equal to AO_Buy_Min. Sell needs AO less than or equal to AO_Sell_Max.
AO_Buy_Min
Default 4.0. This is in AO units of the symbol, so tune it per instrument.
AO_Sell_Max
Default -4.0.
Use_AO_Color_Filter
Buy needs AO rising versus the previous bar. Sell needs AO falling.
Use_AO_Zero_Filter
Buy needs rising AO and AO above zero. Sell needs falling AO and AO below zero.
Benefit: momentum confirmation. Start with color or zero first. Volume thresholds must be tuned per symbol.
PARABOLIC SAR FILTER
Use_SAR_Filter
Buy if close is above SAR. Sell if close is below SAR.
SAR_Step
Default 0.02.
SAR_Maximum
Default 0.2.
Benefit: short-term direction lock.
HEIKEN ASHI FILTER
Use_HeikenAshi_Filter
Buy only on a bullish Heiken Ashi candle (HA close above HA open). Sell only on a bearish Heiken Ashi candle.
The indicator builds Heiken Ashi internally from open, high, low, and close. A separate Heiken Ashi chart is not required.
CCI TREND FILTER
Use_CCI_Filter
Buy if CCI is above 0. Sell if CCI is below 0.
CCI_Period
Default 50.
CCI_Applied
Default PRICE_CLOSE.
CCI OB AND OS FILTER
Use_CCI_OBOS_Filter
Buy if CCI is above CCI_Overbought. Sell if CCI is below CCI_Oversold.
CCI_OBOS_Period
Default 14.
CCI_OBOS_Applied
Default PRICE_CLOSE.
CCI_Overbought
Default 100.
CCI_Oversold
Default -100.
Use this only if you want CCI already extended. It is not a mean-reversion filter.
RVI TREND FILTER
Use_RVI_Filter
Buy if RVI is above 0. Sell if RVI is below 0.
RVI_Period
Default 75.
RVI SIGNAL FILTER
Use_RVI_Signal_Filter
Buy if RVI main is above RVI signal. Sell if main is below signal.
RVI_Signal_Period
Default 20.
MACD SIGNAL FILTER
Use_MACD_Filter
Uses histogram = MACD main minus signal. Buy if histogram is above 0. Sell if histogram is below 0.
MACD_FastEMA
Default 12.
MACD_SlowEMA
Default 26.
MACD_SignalSMA
Default 9.
MACD_Applied
Default PRICE_CLOSE.
MACD LEV 0 FILTER
Use_MACD_Zero_Filter
Buy if the MACD main line is above zero. Sell if it is below zero. It uses the same MACD handle as the histogram filter.
SUPPORT AND RESISTANCE FILTER
Use_SR_Filter
Builds a recent range from the lowest low and highest high over SR_Period bars before the current bar. A buy needs price to touch or pierce the support zone. A sell needs price to touch or pierce the resistance zone.
SR_Period
Default 50.
SR_Zone_Points
Zone width in points. Default 80. Increase on Gold, indices, and crypto.
FIBONACCI FILTER
Use_Fib_Filter
Finds a recent swing high and swing low with a ZigZag-style search, then builds a zone between Fib_Level_1 and Fib_Level_2. Both buy and sell require the current bar to overlap that zone. If no valid swing pair is found, the filter rejects the signal.
Fib_Level_1
Default 0.382.
Fib_Level_2
Default 0.618.
ZigZag_Depth
Default 12. Size of the local high and low comparison window.
ZigZag_Deviation
Minimum improvement in points before a new extreme replaces the previous one. Default 5.
ZigZag_Backstep
Minimum bar distance between accepted extremes. Default 3.
RECOMMENDED SETUP
Do not enable every filter on the first day. That can hide almost all arrows.
Setup 1. Learn the raw engine
Show_Regular = true
Show_Hidden = true
Show_Breakout = true
Draw_Trendline = true
All Use_* filters = false
Goal: see how pivots, lines, and breakouts behave on your symbol.
Setup 2. Trend-following swing
Use_MA_Filter or Use_DoubleMA_Filter = true
Use_ADX_Filter = true
Use_MACD_Filter or Use_MACD_Zero_Filter = true
Show_Hidden = true
Optional: Use_SAR_Filter or Use_HeikenAshi_Filter
Setup 3. Reversal near exhaustion
Show_Regular = true
Use_RSI_Cross_Filter = true
Use_SR_Filter or Use_Fib_Filter = true
Setup 4. Conservative confirmation
Keep Show_Breakout = true and treat the breakout arrow as the trigger. Use the divergence arrow as a warning that a setup is building.
Timeframe hint:
M5-M15: more signals and more noise. Use at least one trend filter.
H1-H4: cleaner structure. Default pivot settings usually work.
D1: increase Swing_Left and Swing_Right if you only want major turns.
Symbol hint:
FX majors: default point offsets are usually fine.
XAUUSD, US30, crypto: raise Arrow_Offset, SR_Zone_Points, and AO thresholds.
INSTALLATION
1. Open MetaTrader 5.
2. File > Open Data Folder > MQL5 > Indicators.
3. Copy the indicator file into that folder.
4. Restart MT5 or right-click Navigator > Indicators > Refresh.
5. Drag the indicator onto a chart.
6. Set inputs and click OK.
To receive mobile push:
Tools > Options > Notifications. Enable notifications and add the MetaQuotes ID from the MT5 mobile app.
HOW TO USE THE SIGNALS
This is a usage example, not financial advice.
Bullish path
Wait for an aqua divergence arrow and a lime line.
Optional: wait for the dodger-blue Breakout Buy after a close above the line.
A common invalidation is below the divergence low or below the last higher-low structure.
Bearish path
Wait for a red divergence arrow and a red line.
Optional: wait for the magenta Breakout Sell after a close below the line.
A common invalidation is above the divergence high.
Practical rules:
Do not stack several arrows from the same swing as separate ideas.
If you are not a news trader, skip entries into major releases.
If two filters fight your plan, turn one off. The indicator uses AND logic, not a scoring system.
WHAT IS INCLUDED
MT5 indicator with four visible plots
Regular divergence, hidden divergence, and breakout modules
Optional trendline objects
Optional confirmation filters listed above
Popup, sound, and push notification helper
Input groups for faster setup
Not included:
Auto-trading Expert Advisor
Money management
Trade copier
Ready set files for every broker symbol
COMPATIBILITY AND LIMITS
Built for MetaTrader 5. It is not an MT4 file.
The calculator needs enough bars on the chart. It returns nothing until bars exceed Lookback plus the swing settings plus a safety margin.
Removing the indicator deletes objects with the DivTL_ prefix.
Filter handles are created only when that filter is enabled.
AO thresholds, S/R zone points, and Fibonacci deviation depend on the symbol. Tune them on a demo chart of the exact instrument you trade.
Closed-bar logic is used for alerts and breakouts. Do not judge a signal on an unclosed candle.
BEST PRACTICES
Start on a demo chart or in visual tester mode.
Save screenshots of settings that fit your pair.
Combine the arrows with market structure rather than using arrows alone.
If Fibonacci and Support/Resistance are both enabled, expect far fewer arrows.
Hidden divergence plus a trend filter is often cleaner than regular divergence against a strong ADX trend.
Regular divergence plus S/R or Fibonacci is often cleaner when you are hunting turns.
DISCLAIMER
Trading leveraged products involves risk of loss. Past visual signals on a chart do not guarantee future results. This product is a decision-support indicator. You are responsible for broker conditions, spreads, slippage, and your own trade decisions.
THANK YOU
Thank you for reading and for supporting this tool. Learn the raw divergence first, then add filters with purpose. Use the breakout arrow as confirmation, protect the account, and trade with a written plan.
