AlgoZ Smart Divergence [Trend Filtered]
Dec 12, 2025

The AlgoZ Smart Divergence [Trend Filtered] indicator is a precision entry tool that identifies market reversals by combining volume divergence analysis with multi-timeframe trend filtering. It aims to provide high-probability trade setups by ensuring signals align with the broader market momentum and institutional volume flow.
Usage
The script is designed to identify "smart" reversals where price action and volume show conflicting signals.
- Long Entries: Traders should look for a "BUY" label. For optimal probability, the user can enable the color match filter, which ensures signals only appear when the candles are colored green (indicating a bullish trend on the higher timeframe).
- Short Entries: Traders should look for a "SELL" label. When the color match filter is active, these signals will only appear during red candle periods (indicating a bearish trend on the higher timeframe).
- Trend Confirmation: The indicator paints candle bars based on a Higher Timeframe (HTF) trend. Green candles represent a bullish macro trend, while red candles represent a bearish macro trend.
- Filtering: Users can toggle the built-in EMA filter to ensure price is on the correct side of the trend, or use the optional RSI and ADX filters to avoid low-volatility environments.
Details
The script operates using a validation process involving three primary components:
- Volume Divergence Engine: It detects anomalies where volume spikes relative to price action. For example, if price makes a Lower Low but Volume hits a Higher High, a divergence is noted.
- HTF Trend Analysis: The tool monitors a Higher Timeframe (defaulting to 3 hours) and determines the trend based on breaks of previous highs and lows. This macro trend dictates the candle coloring on the chart.
- Signal Validation: To reduce noise, the script can block signals that go against the HTF trend. It also incorporates a 10-period EMA and volatility metrics (ADX/RSI) to further refine entries and ensure the market is not in a "choppy" state.
Settings
Divergence Settings
- Pivot Left: The number of bars to the left used to identify a pivot.
- Pivot Right: The number of bars to the right used to identify a pivot.
- Range Min: The minimum number of bars required between divergence points.
- Range Max: The maximum number of bars allowed between divergence points.
Candle Coloring (HTF Trend)
- Paint Candles with HTF Trend: Toggles the background coloring of candle bars based on the macro trend.
- Higher Timeframe: Sets the timeframe used to calculate the macro trend (e.g., 180 minutes, 1 day).
Signal Filters
- Only Show Signals Matching Candle Color: When enabled, buy signals only show during uptrends and sell signals during downtrends.
- Filter: Trade with Trend (EMA): Requires price to be above (for buys) or below (for sells) the EMA.
- EMA Length: Adjusts the period of the trend-filtering EMA.
- Filter: RSI Overbought/Oversold: Adds an RSI condition to the signal logic.
- Filter: Min Volatility (ADX): Filters out signals if the ADX is below the specified threshold.
- ADX Threshold: The minimum ADX value required for a signal to be valid.
FAQ
How do I access AlgoZ Smart Divergence [Trend Filtered]?
You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
What does "non-repainting" mean in this context?
This means that once a bar closes and a signal is confirmed, the signal will not disappear or move to a different bar, ensuring reliable backtesting and execution.
Can I change the trend sensitivity?
Yes, by adjusting the "Higher Timeframe" setting, you can make the trend filter more sensitive (lower timeframe) or more stable (higher timeframe) depending on your trading style.
Free indicator
Get free access to this indicator on the platforms below.
Unlock the entire LuxAlgo Library
Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.