Indicator · Pine Script v6 · On the chart

Nested FVG Pro

by abhinaynatraj· code credited to nested_fvg_indicator

An indicator for a 1-minute chart that finds 5-minute fair value gaps and looks for a smaller 1-minute gap forming inside them.

View on GitHub

GitHub stars1on the repository
Pine versionv6current
Lines of code1,471
Settings40inputs
LicenceNone stated
Last update3 months ago4 Jul 2026

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
  2. 2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
  3. 3Paste over the templateCreate a new indicator, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart, then adjust the settings with the gear icon next to its name.

Source Code

The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.

Overview

A nested gap triggers a bullish or bearish label and a trade plan with entry, stop, partial target, main target and extended target set as percentages of price. The entry can be immediate or placed at the near edge, middle or far edge of the gap, and new signals are blocked while a trade is open. Alerts cover the signal, partial, stop and target. It also shows position size from a dollar value per point.

Details

Published by

abhinaynatraj on GitHub

Code credit

nested_fvg_indicator, as written in the script's header

Type

Indicator, Pine Script v6

Draws

On the price chart

Category

SMC / ICT / price action, Scalping

Markets

Indices

Timeframes

M1-M5

Risk Notes

No repainting, lookahead or stacked entries were found in its code or README. That says nothing about how well it works: test it first.

Settings

The inputs you can change from the gear icon on the chart. Defaults are the author's.

SettingTypeDefaultVariable
Show 5-min FVGsbooltruefvg5_show
5-min Bullish Colorcolorcolor.new(#06b6d4, 88)fvg5_bull_col
5-min Bearish Colorcolorcolor.new(#f87171, 88)fvg5_bear_col
Remove 5-min FVG When Mitigatedbooltruefvg5_mitigated
5-min FVG Min Size (basis points)float0.15fvg5_min_bp
Show 1-min Nested FVGsbooltruefvg1_show
1-min Bullish Colorcolorcolor.new(#06b6d4, 72)fvg1_bull_col
1-min Bearish Colorcolorcolor.new(#f87171, 72)fvg1_bear_col
1-min FVG Min Size (basis points)float0.15fvg1_min_bp
1-min FVG Entry SpotstringImmediatefvg1_entry
Bullish Label Colorcolorcolor.new(#06b6d4, 0)sig_bull_col
Bearish Label Colorcolorcolor.new(#f87171, 0)sig_bear_col
Show all 40 settings
SettingTypeDefaultVariable
Alert on Nested FVGbooltruealert_on_nest
Alert on Partial/BE Hitbooltruealert_partial
Alert on Stop Hitbooltruealert_stop
Alert on Target Hitbooltruealert_target
Cooldown Between Signals (bars/mins)int30cooldown_bars
Invalidate If Partial Hit Before Entrybooltrueinvalidate_partial
Show R/R Levelsbooltruerr_show
Show R/R Pills (price tags)boolfalserr_show_pills
Show Position Size badgebooltruerr_show_size
R/R Label Sizestringtinyrr_label_size
Stop Loss (% of Price)float0.10rr_stop_pct
Partial Target (% of Price)float0.10rr_partial_pct
Main Target (% of Price)float0.15rr_target_pct
Extended Target (% of Price)float0.30rr_ext_pct
Dollar Value Per Full Pointfloat2.0val_per_point
Stop Colorcolorcolor.new(#f87171, 0)rr_stop_col
Entry Colorcolorcolor.new(#fbbf24, 0)rr_entry_col
Target Colorcolorcolor.new(#06b6d4, 0)rr_target_col
Partial Colorcolorcolor.new(#38bdf8, 0)rr_partial_col
Extended Target Colorcolorcolor.new(#fbbf24, 0)rr_ext_col
Max Dollar Risk per Trade ($)float480.0max_trade_risk_usd
Move Stop to Break-Even at Anchor/Partialbooltruepos_be_at_partial
Show Trade Tracker Tablebooltruetbl_show
Table PositionstringBottom Righttbl_pos
Table Text Sizestringnormaltbl_size
Max Rows to Displayint10tbl_max_rows
Tracker Time ZonestringAuto (Chart/Exchange)tbl_tz_opt
Today Onlybooltruetbl_today_only
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.

Similar Pine Scripts

Apex Protocol v3.3

by alboogycOdR
6 stars

Apex Protocol v3.3 is a Smart Money Concepts trading indicator that plots order blocks, fair value gaps, BOS and MSS markers, auto Fibonacci levels, area of interest zones and external internal structures on the price chart. It supports multiple killzone sessi

Indicator v5 SMC / ICT / price actionScalping Repaints
Updated 7 months ago · None stated GitHub repository of Apex Protocol v3.3

A price-chart overlay for gold that extends the earlier version of this scalping tool with stricter confirmation rules. It combines pivot market structure, liquidity sweeps, candlestick confirmation, breakout and retest logic, a higher-timeframe filter and a q

Indicator v5 SMC / ICT / price actionSupport & resistance
1 stars

Marks order block zones on the price chart for gold. A displacement candle is one whose range is at least 1.2 times ATR on above-average volume; the last opposite-colour candle before it becomes the zone. Each zone is scored on five checks such as clean body,

Indicator v5 SMC / ICT / price actionScalping
Updated 4 months ago · None stated GitHub repository of Krishna Simple OB Scalper - XAUUSD
1 stars

An indicator that shows an adaptive True Strength Index in a separate pane while projecting signals onto the price chart. It detects the instrument type, such as gold, silver or major indices, and the timeframe to pick parameters, adapts reactivity to ATR, and

Indicator v6 Oscillators & momentumScalping
Updated 6 months ago · None stated GitHub repository of TSI Adaptive Scalper v4.2 OVL-SP

More indicators

Trade Your Charts With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers