PROTECTED SOURCE SCRIPT

IFVGs [NINE]

57
Overview

The IFVG Indicator is a precision-engineered tool designed to identify and display Inversion Fair Value Gaps (IFVGs), a powerful price action concept rooted in ICT (Inner Circle Trader) methodology. This indicator automatically detects when price closes through an existing Fair Value Gap, causing the zone to "invert" and flip its directional bias, signaling potential areas of institutional interest for future price reactions.

What is an Inversion Fair Value Gap?

A Fair Value Gap (FVG) is a three-candle pattern where a gap exists between the wicks of the first and third candles, representing an imbalance in price delivery. These zones often act as magnets for price to return and "fill" the inefficiency.

An Inversion Fair Value Gap (IFVG) occurs when price doesn't just tap into an FVG, it closes through it with a candle body. This "inversion" transforms the zone:

A Bullish FVG that gets closed through becomes a Bearish IFVG (potential resistance/supply zone)

istantanea

A Bearish FVG that gets closed through becomes a Bullish IFVG (potential support/demand zone)

istantanea

IFVGs represent areas where the market has shown its hand — institutional order flow has aggressively moved through a prior inefficiency, and the inverted zone now becomes a point of interest for potential reversals or continuations.

Key Features

Automatic IFVG Detection

The indicator continuously monitors for Fair Value Gaps and automatically converts them to IFVGs when price body closes through the zone. No manual identification required.

Multiple Display Styles

Choose from four distinct visualization modes to match your chart aesthetic:

Level — Clean, minimal single line at the IFVG extreme (top for bullish, bottom for bearish)

istantanea

Normal — Filled zone with dashed borders and dot label

istantanea

Minimalist — High/low boundary lines with connecting link

istantanea

Classic — Filled box with 50% midline only

istantanea

Full Customization

Independent colors for bullish and bearish IFVGs
Adjustable transparency for zone fills
Optional 50% midline (Consequent Encroachment level)
Flexible label styles: "IFVG" or "+/−" notation
Multiple label sizes: Tiny, Small, Normal, Large

Smart Extension Options

Extend to Current Bar — Zones dynamically extend as price progresses
Extend to Confirmation — Zones end at the bar where inversion occurred
Manual Offset — Fine-tune extension length in bars

Clustered IFVG Filter

Prevents chart clutter by ensuring only one IFVG per direction forms within a 5-bar cooldown period. When a single candle closes through multiple FVGs, only the first IFVG of that directional series is displayed — eliminating redundant signals and keeping your chart clean.

FVG Lookback Control

Limit which FVGs can become IFVGs based on their age. Options include 10, 50, 100, 200, or 300 bars. This filters out old, stale FVGs that may create less relevant inversions.

Session Time Filters

Optional time-based filtering allows you to focus on specific trading sessions:

Configurable session windows (e.g., 9:30 AM - 12:00 PM)
Support for two independent session filters
Multiple timezone options including New York, London, Tokyo, and more

Volume Imbalance Detection

Optionally include Volume Imbalances (VIs) — gaps between candle bodies rather than wicks — expanding the scope of detectable inefficiencies.

istantanea

Invalidation Tracking

IFVGs are automatically invalidated when price closes back through the zone in the opposite direction, with optional display of invalidated zones.

istantanea

How to Use

Entry Confirmation

IFVGs serve as areas for trade entries. When price returns to a confirmed IFVG:

Bullish IFVG — Look for long entries as price taps the zone from above

Bearish IFVG — Look for short entries as price taps the zone from below


Settings Reference

Inversion Fair Value Gaps

Show IFVGs? — Master toggle for IFVG display
Style — Level, Normal, Minimalist, or Classic
Transparency % — Zone fill opacity (0-100)
Historical Display — Maximum IFVGs to show per direction
Bullish/Bearish Colors — Independent color selection
Show Invalidated? — Display IFVGs that have been invalidated
Extend IFVGs? — Enable dynamic zone extension
Extension Mode — Current Bar or Confirmation
Manual Offset — Additional bars to extend
High/Low Lines — Show boundary lines (Minimalist style)
50% Midline — Show Consequent Encroachment level
Show Labels? — Display zone labels
Label Style — IFVG or +/− notation
FVG Lookback — Maximum age of FVGs that can invert
Clustered Filter — Prevent multiple same-direction IFVGs in quick succession
Volume Imbalances — Include body gaps in detection

Session Filters

Enable 1st/2nd Time Filter — Activate session filtering
Session Times — Define active trading windows
Timezone — Reference timezone for session calculations


Disclaimer

This indicator is provided for educational and informational purposes only. It is not financial advice, and nothing contained herein constitutes a recommendation, solicitation, or offer to buy or sell any securities, options, or other financial instruments.

Trading involves substantial risk of loss and is not suitable for all investors. Past performance is not indicative of future results. You should carefully consider your investment objectives, level of experience, and risk appetite before making any trading decisions.

The developer of this indicator makes no representations or warranties regarding the accuracy, completeness, or reliability of the information provided. You are solely responsible for your own trading decisions and any profits or losses that may result.

Always conduct your own research and consider seeking advice from a licensed financial professional before trading.

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.