Momentum-Based Fair Value Gaps
Oct 17, 2025

The Momentum-Based Fair Value Gaps indicator is a precision tool that detects Fair Value Gaps (FVG) and color-codes each zone by momentum to help traders identify which imbalances are likely to fill or power trend continuation. By integrating RSI-based momentum heatmaps, this script allows for a more nuanced interpretation of price action imbalances beyond standard gap detection.
Usage
The Usage section highlights how to leverage momentum-based gaps in various market conditions:
- Trend Continuation: Look for price to respect the near edge of a high-momentum FVG (indicated by stronger heatmap colors) before breaking away in the original direction.
- Mean Reversion: Target partial or full fills of opposing FVGs created on weak momentum, especially when they sit against the higher timeframe context.
- Risk Management: In continuation setups, invalidation is typically placed beyond the opposite edge of the active FVG. In reversion setups, invalidation sits beyond the gap attracting price.
- Structure Scanning: Use the "Min FVG Size %" filter to reduce noise and identify significant supply and demand footprints. Stacked clusters often indicate strong trends, while overlapping opposing gaps mark potential battle zones or consolidation.
Details
A Fair Value Gap is a three-candle price imbalance formed when the middle candle expands rapidly, leaving a void between the first and third candles. This script enhances this concept by measuring momentum at the time of the gap's creation using a smoothed RSI.
The tool includes advanced logic for:
- Momentum Heatmaps: Uses various palettes (Gradient, Discrete, Palette) and scientific schemes (Viridis, Plasma, etc.) to visualize the RSI signature of each gap.
- Lifecycle Management: Zones can be projected forward until filled, with an option to automatically remove filled gaps to maintain a clean chart.
- Filtering: Users can filter for specific gap sizes or restrict signals to RSI extremes (oversold for bullish gaps, overbought for bearish gaps).
Settings
Fair Value Gap Settings
- Max FVG Display: Limits the number of FVG zones on the chart for performance optimization.
- Show Bullish/Bearish FVGs: Toggles the display for specific gap directions.
- Extend Unfilled FVGs: Extends the right edge of unfilled gaps to the current bar.
- Remove Filled FVGs: Automatically deletes zones once price trades through them.
Momentum Settings
- RSI Length: The lookback period for the RSI calculation.
- RSI Smoothing: SMA period applied to the RSI for more stable coloring.
- RSI Source: Choose between Returns (percent change), Close (price), or Volume to judge the impulse quality.
Visual Settings
- Heatmap Style: Selects how colors are applied (Gradient, Discrete, Simple, or Palette).
- Palette Name: Selection of various color schemes for momentum visualization.
- Fill Transparency %: Adjusts the opacity of the FVG boxes.
- Show RSI Labels: Displays the specific RSI value at the gap's creation point.
FAQ
How do I use the momentum heatmap?
Brighter or more intense colors typically represent stronger momentum at the time of gap formation. These "high conviction" gaps are more likely to act as support or resistance, whereas weakly colored gaps are more prone to being filled quickly.
What is the benefit of the "Returns" RSI source?
The "Returns" source computes the percentage change over a short lookback, making it more sensitive to true momentum bursts and impulse quality compared to standard price-based RSI.
How can I access this script?
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.