OPEN-SOURCE SCRIPT
ICT FVG Detector

This indicator identifies ICT Fair Value Gaps (FVGs) on any timeframe and overlays them as clean, interactive zones directly on your chart. It covers both standard imbalances and higher-timeframe (HTF) imbalances transposed onto lower timeframes — a core concept in ICT-based trading.
What it detects
BISI (Buy-side Imbalance, Sell-side Inefficiency) — bullish FVGs where a gap exists between the high of bar[2] and the low of bar[0]
SIBI (Sell-side Imbalance, Buy-side Inefficiency) — bearish FVGs where a gap exists between the low of bar[2] and the high of bar[0]
Displacement FVGs — tagged when the middle candle of the 3-bar pattern (the actual displacement candle) trades through the most recent confirmed swing high or low, signalling a genuine structure break
HTF Alignment
FVGs from the next-higher relevant timeframe are automatically transposed onto the current chart as gray-shaded zones, making it easy to identify where higher-timeframe imbalances sit without switching charts.
Valid pairs:
Chart timeframe HTF source
1m 15m
5m 1H
15m 4H
1H Daily
4H Weekly
Daily Monthly
HTF zones are visually distinct (gray fill) so they never compete with native FVGs. On unsupported timeframes, HTF zones are simply not drawn.
Features
Four draw styles: Lines + Fill, Lines Only, Fill Only, Boxes
Solid, dashed, or dotted boundary lines
Extend zones to current bar or a fixed number of bars
Mitigation tracking — zones dim or delete once price trades back through them (configurable separately for native and HTF FVGs)
Invisible hover labels positioned at the vertical midpoint of each zone — hover to instantly identify the gap type without cluttering the chart
Alerts for new BISI, SIBI, Displacement BISI, and Displacement SIBI
Settings
All inputs are grouped into five sections: FVG Detection, Swing / Displacement, Display, Mitigation, and HTF Alignment — making it straightforward to tune each layer independently.
What it detects
BISI (Buy-side Imbalance, Sell-side Inefficiency) — bullish FVGs where a gap exists between the high of bar[2] and the low of bar[0]
SIBI (Sell-side Imbalance, Buy-side Inefficiency) — bearish FVGs where a gap exists between the low of bar[2] and the high of bar[0]
Displacement FVGs — tagged when the middle candle of the 3-bar pattern (the actual displacement candle) trades through the most recent confirmed swing high or low, signalling a genuine structure break
HTF Alignment
FVGs from the next-higher relevant timeframe are automatically transposed onto the current chart as gray-shaded zones, making it easy to identify where higher-timeframe imbalances sit without switching charts.
Valid pairs:
Chart timeframe HTF source
1m 15m
5m 1H
15m 4H
1H Daily
4H Weekly
Daily Monthly
HTF zones are visually distinct (gray fill) so they never compete with native FVGs. On unsupported timeframes, HTF zones are simply not drawn.
Features
Four draw styles: Lines + Fill, Lines Only, Fill Only, Boxes
Solid, dashed, or dotted boundary lines
Extend zones to current bar or a fixed number of bars
Mitigation tracking — zones dim or delete once price trades back through them (configurable separately for native and HTF FVGs)
Invisible hover labels positioned at the vertical midpoint of each zone — hover to instantly identify the gap type without cluttering the chart
Alerts for new BISI, SIBI, Displacement BISI, and Displacement SIBI
Settings
All inputs are grouped into five sections: FVG Detection, Swing / Displacement, Display, Mitigation, and HTF Alignment — making it straightforward to tune each layer independently.
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
ᵣᵢCₕ BᵥWY
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
ᵣᵢCₕ BᵥWY
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.