INVITE-ONLY SCRIPT

XAU/USD OB Auto Zones

100
What the script does
XAUUSD Order Blocks Auto Zones automatically detects institutional order blocks and supply/demand (bid/ask) zones on the gold (XAU/USD) chart. It marks each zone, assigns a strength score, and keeps real‑time statistics and alerts. Optimized for gold’s volatility and fast intraday trading on 5 m – 10 m charts.

How it works (conceptual logic)

Swing identification – scans the last N bars (user‑set Swing Length) to find local highs/lows that mark potential origin candles.

Zone construction – when price closes beyond a swing, the body/wick of the triggering candle becomes the initial order block.

XAU/USD filters

Minimum price movement ≥ $0.5.

Volume above Volume Threshold × 20‑period SMA.

Optional London / New York session filter.

Strength score = 0.4 × volume ratio + 0.3 × relative size (ATR‑weighted) + 0.3 × session weight. OBs with score > 2.0 are flagged STRONG.

Visualization

Dynamic boxes that extend until broken (by wick or close, user selectable).

Mirrored volume bars inside each zone.

Two overlay tables:

Live OB list (max rows configurable)

Global stats (total, active vs. broken, strong count, session)

Built‑in notifications

New bullish / bearish OB created

Existing OB broken

Optional OB‑touch signal

How to use

Add to chart ➜ set timeframe (5 m – 10 m recommended).

Adjust Swing Length and Max ATR Multiplier for your session.

Read the tables: green rows = active bullish zones, red = active bearish; crossed‑out rows = broken zones.

Use the Strength column to gauge reliability; many traders wait for a retest of STRONG zones before entering.

For scalping, set Zone Count = One to display only the freshest block per direction.

Why it’s valuable

Tailored for gold’s rapid moves (tighter ATR cap, wider look‑back, volatility‑scaled filters).

Combines price action, volume analytics, and session context in one overlay – no need for multiple indicators.

Zones auto‑extend and fade after breaks; all key data (range, strength, status, volume) sits in a compact panel.

Inputs & groups

Group Key inputs Default Purpose
General Config Combine Zones · Max ATR Mult · Swing Length · Zone Count 1.5 ATR, len = 1, “Average” Core detection logic
XAU/USD Settings Min Price Move · Volume Threshold · London/NY only · Strong‑OB filter $0.5, 1 × SMA, off Asset‑specific filters
Colors & Style Bull/Bear colors · Extend Zones · Volume‑bar side XAU‑tuned palette Visual tweaks
Tables Show OB list · Max rows · Show stats on, 8, on UI elements

Disclaimer
For educational purposes only. Past performance does not guarantee future results. Trade at your own risk.

Need access?
Send me a private message on TradingView sashko86 with your TV username. Approval usually within 24 hours. Please do not request access in public comments; those are for feedback only.

Declinazione di responsabilità

Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.