OPEN-SOURCE SCRIPT
Likvidita ERL - Sweeps & Equal Highs/Lows CoreX

# Liquidity ERL - Sweeps & Equal Highs/Lows
**Description:**
This indicator maps External Range Liquidity (ERL) and detects liquidity sweeps confirmed by volume — swing highs/lows, equal-highs/equal-lows pools, previous day/week high-low, the Asian session range, and session VWAP, all in one script.
**What the script does**
Liquidity tends to pool at swing highs and lows, since retail stop-loss and breakout orders concentrate there. The script identifies confirmed swing points and draws them as BSL (buy-side liquidity, above price) or SSL (sell-side liquidity, below price) lines. When two or more swings form within a configurable ATR-based tolerance, they merge into a single EQH/EQL pool instead of two separate lines — the more swings merge into one level, the thicker the line gets, visually flagging it as a stronger, more significant zone.
Alongside swing-based liquidity, the script tracks Previous Day High/Low, Previous Day High/Low... wait let me continue: Previous Week High/Low, and the Asian session's high/low range (shown live as a highlighted box while the session is active, then locked in as a level once the session closes) — three classic external liquidity references used by both day and swing traders.
A liquidity sweep is flagged when price wicks through one of these levels and closes back on the original side. Not every sweep is treated as significant: the script cross-checks the sweep candle's volume against its own moving average. Sweeps backed by volume well above average are marked as "quality" sweeps (institutional absorption, likely reversal signal); sweeps on thin volume are treated as probable fakeouts / failed auctions and, by default, are hidden rather than alerted on — a deliberate design choice, since a liquidity grab without volume is a fundamentally different (and far less reliable) pattern than one with it.
**How to read it**
Line color indicates the liquidity type (see the built-in on-chart legend, togglable from settings — position and text size are configurable). A ✓ appended to a label means the sweep was volume-confirmed; a ~ means it wasn't. Once a level is swept, it either disappears (default) or turns gray and dotted, depending on your settings.
**Settings**
Configurable swing sensitivity, equal-highs/lows tolerance (ATR-based), which reference levels to show (day/week/Asia), volume MA length and the multiplier required for a "quality" sweep, session VWAP toggle, full color customization, and separate alerts for quality vs. weak sweeps.
**Disclaimer**
This indicator visualizes liquidity concepts from Smart Money / ICT methodology and is intended for analytical and educational purposes only. It does not constitute financial advice or a trading signal — all trading decisions and associated risks remain solely with the user. Note that on spot forex/CFD symbols, "volume" reflects broker tick volume rather than true traded volume; the quality filter is relative (current vs. its own average) so it remains useful, but isn't directly comparable to real exchange volume (e.g. CME futures).
**Description:**
This indicator maps External Range Liquidity (ERL) and detects liquidity sweeps confirmed by volume — swing highs/lows, equal-highs/equal-lows pools, previous day/week high-low, the Asian session range, and session VWAP, all in one script.
**What the script does**
Liquidity tends to pool at swing highs and lows, since retail stop-loss and breakout orders concentrate there. The script identifies confirmed swing points and draws them as BSL (buy-side liquidity, above price) or SSL (sell-side liquidity, below price) lines. When two or more swings form within a configurable ATR-based tolerance, they merge into a single EQH/EQL pool instead of two separate lines — the more swings merge into one level, the thicker the line gets, visually flagging it as a stronger, more significant zone.
Alongside swing-based liquidity, the script tracks Previous Day High/Low, Previous Day High/Low... wait let me continue: Previous Week High/Low, and the Asian session's high/low range (shown live as a highlighted box while the session is active, then locked in as a level once the session closes) — three classic external liquidity references used by both day and swing traders.
A liquidity sweep is flagged when price wicks through one of these levels and closes back on the original side. Not every sweep is treated as significant: the script cross-checks the sweep candle's volume against its own moving average. Sweeps backed by volume well above average are marked as "quality" sweeps (institutional absorption, likely reversal signal); sweeps on thin volume are treated as probable fakeouts / failed auctions and, by default, are hidden rather than alerted on — a deliberate design choice, since a liquidity grab without volume is a fundamentally different (and far less reliable) pattern than one with it.
**How to read it**
Line color indicates the liquidity type (see the built-in on-chart legend, togglable from settings — position and text size are configurable). A ✓ appended to a label means the sweep was volume-confirmed; a ~ means it wasn't. Once a level is swept, it either disappears (default) or turns gray and dotted, depending on your settings.
**Settings**
Configurable swing sensitivity, equal-highs/lows tolerance (ATR-based), which reference levels to show (day/week/Asia), volume MA length and the multiplier required for a "quality" sweep, session VWAP toggle, full color customization, and separate alerts for quality vs. weak sweeps.
**Disclaimer**
This indicator visualizes liquidity concepts from Smart Money / ICT methodology and is intended for analytical and educational purposes only. It does not constitute financial advice or a trading signal — all trading decisions and associated risks remain solely with the user. Note that on spot forex/CFD symbols, "volume" reflects broker tick volume rather than true traded volume; the quality filter is relative (current vs. its own average) so it remains useful, but isn't directly comparable to real exchange volume (e.g. CME futures).
Script open-source
Nello spirito di TradingView, l'autore di questo script lo ha reso open source, in modo che i trader possano esaminarne e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricordiamo che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni e le pubblicazioni non sono intese come, e non costituiscono, consulenza o raccomandazioni finanziarie, di investimento, di trading o di altro tipo fornite o approvate da TradingView. Per ulteriori informazioni, consultare i Termini di utilizzo.
Script open-source
Nello spirito di TradingView, l'autore di questo script lo ha reso open source, in modo che i trader possano esaminarne e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricordiamo che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni e le pubblicazioni non sono intese come, e non costituiscono, consulenza o raccomandazioni finanziarie, di investimento, di trading o di altro tipo fornite o approvate da TradingView. Per ulteriori informazioni, consultare i Termini di utilizzo.