OPEN-SOURCE SCRIPT
Liquidity Heatmap [Eหฃ]

๐ง Liquidity Heatmap - Free Indicator
Overview
The Liquidity Heatmap reveals where stop losses are clustered in the market - the hidden liquidity zones that smart money targets. This indicator automatically identifies Buy-Side Liquidity (BSL) above price and Sell-Side Liquidity (SSL) below price, showing you exactly where institutional traders are likely to hunt for stops before major moves.
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ฏ What This Indicator Does
Identifies Liquidity Zones:
โข [color=red]Buy-Side Liquidity (BSL)[/color] - Stop losses from SHORT positions clustered above price
โข [color=green]Sell-Side Liquidity (SSL)[/color] - Stop losses from LONG positions clustered below price
โข Automatically clusters nearby levels into high-probability zones
โข Shows liquidity strength (1-5+) - higher numbers = more stops = bigger target
โข Removes swept liquidity in real-time as price takes out stops
Visual Display:
โข ๐ด [color=red]Red Zones Above Price[/color] = Buy-Side Liquidity (shorts' stops)
โข ๐ข [color=green]Green Zones Below Price[/color] = Sell-Side Liquidity (longs' stops)
โข Thicker/Darker Zones = Higher liquidity concentration
โข BSL/SSL Labels = Show exact strength count
โข Triangle Markers = Liquidity sweep alerts (when price takes stops)
Smart Features:
โข Auto-removes old liquidity (customizable lookback period)
โข Clusters nearby levels to reduce noise
โข Tracks liquidity strength and age
โข Updates in real-time as new swing points form
โข Alerts when major liquidity zones are swept
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ How To Use This Indicator
Understanding Liquidity Concepts
What is Liquidity?
Liquidity refers to clusters of stop loss orders sitting in the market. These stops represent:
โข Long traders' stop losses (below support) = [color=green]Sell-Side Liquidity[/color]
โข Short traders' stop losses (above resistance) = [color=red]Buy-Side Liquidity[/color]
Why Does This Matter?
โข Institutions NEED liquidity to fill large orders
โข Price often "sweeps" liquidity zones before reversing
โข Major liquidity = major target for smart money
โข Understanding liquidity = understanding market maker behavior
The Liquidity Cycle:
1. Retail traders place stops at obvious levels (swing highs/lows)
2. Smart money identifies these clusters
3. Price is pushed to sweep the stops (liquidity grab)
4. Institutions fill their orders with this liquidity
5. Price reverses in the opposite direction
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ก Trading Strategies
Strategy 1: Liquidity Sweep Reversals
Best For: Swing trading, catching reversals
Timeframes: 15min, 1H, 4H, Daily
Entry Setup:
1. Identify strong [color=green]Sell-Side Liquidity (SSL)[/color] zone below price
2. Wait for price to sweep down into the SSL zone
3. Look for rejection/reversal candle pattern (pin bar, engulfing)
4. Enter LONG after sweep and reversal confirmation
5. Stop loss: Below the swept liquidity zone
6. Target: Opposite liquidity zone or key resistance
Why It Works: Smart money sweeps stops to fill buy orders, then pushes price higher
Example:
โข SSL zone at $45,000 with strength 3
โข Price drops to $44,950, sweeps the SSL
โข Strong bullish reversal candle forms
โข Enter long at $45,100
โข Target: BSL zone at $47,000
Strategy 2: Liquidity-to-Liquidity Runs
Best For: Day trading, scalping
Timeframes: 5min, 15min, 1H
Entry Setup:
1. Price sweeps [color=green]Sell-Side Liquidity[/color] below and reverses up
2. Identify [color=red]Buy-Side Liquidity[/color] zone above
3. Enter LONG targeting the BSL zone above
4. Exit near/at the BSL zone (don't wait for sweep)
5. Stop loss: Below recent swing low
Why It Works: Price moves from liquidity pool to liquidity pool
Variation - Reverse for Shorts:
โข BSL sweep above โ Look for SSL zone below
โข Enter short targeting lower liquidity
Strategy 3: Liquidity Avoidance (Stop Placement)
Best For: Improving win rate on existing strategies
Timeframes: All
Rules:
1. NEVER place stops exactly at obvious liquidity zones
2. Place stops beyond the liquidity zone with buffer
3. Or place stops before the liquidity zone (tighter, riskier)
4. Monitor liquidity strength - avoid zones with strength 3+
Why It Works: Market makers hunt obvious stop clusters
Example:
โข Trading long, swing low at $100 (SSL zone, strength 4)
โข Bad: Stop at $99.50 (will get swept)
โข Better: Stop at $98.50 (beyond the liquidity)
โข Alternative: Stop at $100.50 (tighter, before sweep zone)
Strategy 4: Confluence Trading
Best For: High probability setups
Timeframes: 1H, 4H, Daily
Entry Setup:
1. Find liquidity zone that aligns with:
โข Major support/resistance level
โข Fibonacci retracement (0.618, 0.786)
โข Trendline
โข Round psychological number ($50,000, $2,000, etc)
2. Wait for sweep of this high-confluence zone
3. Enter on reversal with multiple confirmations
4. Larger position size justified by confluence
Why It Works: Multiple factors = institutional interest = higher probability
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ๏ธ Settings Explained
Core Settings
Swing Detection Length (Default: 10)
โข Number of bars left/right to identify swing highs and lows
โข Lower values (5-8): More sensitive, more liquidity zones, more noise
โข Higher values (12-20): Less sensitive, only major swings, cleaner chart
โข Recommended: 8-10 for intraday, 10-15 for swing trading
Liquidity Lookback Bars (Default: 100)
โข How many historical bars to track liquidity zones
โข Lower values (50-75): Shows only recent liquidity
โข Higher values (100-200): Shows longer-term liquidity clusters
โข Zones older than this are automatically removed
โข Recommended: 100-150 for most timeframes
Zone Proximity % (Default: 0.5)
โข Percentage threshold to group nearby levels into single zone
โข Lower values (0.2-0.4): Keeps levels separate, more zones
โข Higher values (0.6-1.0): Aggressive clustering, fewer zones
โข Recommended: 0.4-0.6 for crypto, 0.3-0.5 for forex, 0.5-0.8 for stocks
Visualization Settings
Show Buy-Side Liquidity
โข Toggle ON/OFF red zones above price
โข Turn OFF if only interested in downside liquidity
Show Sell-Side Liquidity
โข Toggle ON/OFF green zones below price
โข Turn OFF if only interested in upside liquidity
Show Liquidity Labels
โข Toggle BSL/SSL labels with strength numbers
โข Turn OFF for cleaner chart appearance
โข Keep ON to see exact liquidity strength
Display Style
โข Boxes: Filled rectangular zones (best for visualizing strength)
โข Lines: Horizontal dashed lines (minimal, clean look)
โข Both: Boxes + Lines (maximum visibility)
Color Intensity
โข Low: 85% transparency (subtle, less distracting)
โข Medium: 75% transparency (balanced visibility)
โข High: 65% transparency (bold, maximum visibility)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ฑ Info Panel Guide
Located in the top-right corner, the info panel provides real-time liquidity statistics:
Buy-Side Zones
โข Count of active BSL zones above current price
โข Higher number = More upside targets for price
Sell-Side Zones
โข Count of active SSL zones below current price
โข Higher number = More downside targets for price
Total Zones
โข Combined count of all active liquidity
โข Useful for gauging overall market structure
Nearest BSL
โข Distance in % to closest Buy-Side Liquidity above
โข Example: +2.5% means BSL is 2.5% above current price
โข Quick reference for next upside target
Nearest SSL
โข Distance in % to closest Sell-Side Liquidity below
โข Example: -1.8% means SSL is 1.8% below current price
โข Quick reference for next downside target
Liquidity Bias
โข โฌ๏ธ [color=green]Bullish[/color]: More BSL than SSL (upside targets dominate)
โข โฌ๏ธ [color=red]Bearish[/color]: More SSL than BSL (downside targets dominate)
โข โ๏ธ Balanced: Equal liquidity on both sides (range-bound)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ Understanding Liquidity Strength
What Do The Numbers Mean?
Strength 1: Single swing point
โข Light liquidity, minor target
โข Can be ignored in trending markets
โข Useful in ranging/choppy conditions
Strength 2-3: Moderate liquidity cluster
โข Multiple nearby swing points merged
โข Decent target for intraday moves
โข Watch for potential sweeps
Strength 4-5: Strong liquidity cluster
โข Major cluster of stops
โข High-probability target for institutions
โข Expect reactions when swept
Strength 6+: Extreme liquidity pool
โข Massive stop cluster (rare)
โข Critical zone - high probability of sweep
โข Often marks major support/resistance
โข Ideal for confluence setups
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ฑ Alert Setup
This indicator includes 2 powerful alert types:
1. Buy-Side Liquidity Sweep
โข Triggers when price sweeps BSL zone above
โข Shows potential bullish reversal opportunity
โข Often precedes upward continuation after sweep
2. Sell-Side Liquidity Sweep
โข Triggers when price sweeps SSL zone below
โข Shows potential bearish reversal opportunity
โข Often precedes downward continuation after sweep
To Set Up Alerts:
1. Click the "Alert" button (clock icon) in TradingView
2. Condition: Select "Liquidity Heatmap"
3. Choose alert type: BSL Sweep or SSL Sweep
4. Configure notification method (push, email, webhook)
5. Click "Create"
Pro Tip: Set alerts for both BSL and SSL sweeps to catch opportunities in both directions
โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ Pro Tips & Best Practices
โ
DO:
โข Wait for confirmation - Don't enter immediately on sweep, wait for reversal pattern
โข Combine with trend - SSL sweeps in uptrends = higher probability longs
โข Check multiple timeframes - 1H liquidity + 4H liquidity = strongest zones
โข Monitor strength - Focus on zones with strength 3+
โข Use proper risk management - Liquidity sweeps can go further than expected
โข Watch for re-sweeps - Sometimes liquidity zones get swept multiple times
โข Consider volume - High volume sweeps = stronger reversal potential
โ ๏ธ DON'T:
โข Don't fade strong trends - In strong trends, sweeps often continue rather than reverse
โข Don't overtrade - Not every sweep is a tradeable setup
โข Don't ignore context - Check broader market conditions and news
โข Don't use alone - Combine with price action, support/resistance, and other analysis
โข Don't place stops at liquidity - Your stops will be hunted
โข Don't expect perfection
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Ready to upgrade and get the exact signals I use? Unlike 99% of indicators, my system acts on real structure, trend strength & risk logic.
Get Market Solver Pro โก๏ธ patreon.com/marketsolverpro
Get Market Solver Pro โก๏ธ patreon.com/marketsolverpro
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Ready to upgrade and get the exact signals I use? Unlike 99% of indicators, my system acts on real structure, trend strength & risk logic.
Get Market Solver Pro โก๏ธ patreon.com/marketsolverpro
Get Market Solver Pro โก๏ธ patreon.com/marketsolverpro
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.