Liquidity Sweep Candlestick Pattern with MA Filter
May 31, 2025

The Liquidity Sweep Candlestick Pattern with MA Filter indicator automatically identifies price action events where the market breaches a previous candle's high or low to capture liquidity before reversing direction. This tool helps traders spot potential institutional "traps" by highlighting bullish and bearish sweeps with integrated trend filters and strictness rules.
Usage
The tool can be used to identify potential reversal points in the market. For example, a Bullish Liquidity Sweep occurs when the current candle drops below the low of the previous candle to sweep sell-side liquidity, but then closes higher, suggesting a bullish reversal. Conversely, a Bearish Liquidity Sweep occurs when price breaks above a previous candle's high before closing lower.
Traders can utilize the Moving Average filter to align signals with the prevailing trend, such as only taking bullish sweeps when the price is above a 50-period EMA. The "Strict" setting can be used to filter for higher-conviction moves where the price must close entirely beyond the previous candle's body or wick.
Details
Liquidity sweeps are a core concept in institutional price action trading. This script implements several logic layers to detect these events:
- Wick Breach: The indicator checks if the current candle's wick has exceeded the previous candle's high or low.
- Price Rejection: It verifies if the price has moved back within a specific range based on the selected strictness level.
- Trend Confluence: By integrating various Moving Average types (SMA, EMA, WMA, VWMA, RMA, HMA), the script ensures that signals are contextually relevant to the market trend.
Settings
Filtering
- Enable Moving Average Filter: Toggles the trend filter on or off.
- Moving Average Length: Sets the lookback period for the trend filter.
- Moving Average Type: Choose between SMA, EMA, WMA, VWMA, RMA, or HMA.
- Choose Condition: Determines if bull sweeps should appear above or below the MA.
- Signal Strictness: Adjusts the logic for the sweep close (Strict, Less Strict, Least Strict).
- Candle Color Filter: Filters signals based on whether the candle color changed, stayed the same, or matches the sweep direction.
Visuals
- Show Moving Average Line: Toggles the visibility of the MA on the chart.
- Label Type: Choose between "Full" labels, "Short" labels, or "None".
- Shape Type: Option to plot Triangles or Arrows on detected signals.
FAQ
How do I use the Strictness setting?
The Strictness setting dictates how aggressive the reversal must be. "Strict" requires the candle to close beyond the previous candle's high/low, while "Least Strict" only requires the wick to break the previous level.
Can I use this for scalping?
Yes, the indicator works on all timeframes, though many traders prefer using liquidity sweeps on higher timeframes (1H, 4H, Daily) to identify significant institutional turning points.
How do I access this tool?
You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
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.