XAU Spot to GC Converter 📌 XAU Spot ↔ GC Converter converts OANDA:XAUUSD spot levels into COMEX:GC1! futures equivalents in real time.
If you use spot levels but execute trades on futures, this eliminates the guesswork caused by the spot-futures spread. OANDA:XAUUSD COMEX:GC1!
The tool also tracks:
- live spread,
- rolling average spread,
- Z-Score, so you know when conversion levels are statistically reliable and when the basis is stretched.
🔍 What It Does
Displays current XAUUSD and GC1! prices
Calculates the live spread (GC – Spot)
Calculates rolling average spread
Calculates spread Z-Score
Converts up to 6 custom spot levels into futures equivalents
Alerts when price crosses converted levels
Flags extreme spread conditions
⚙️ Adjustable Settings
1. Spread Avg Lookback
Controls how many bars are used to calculate the average spread and Z-Score.
– 50 = good for 1H
– 100 = good for 15m
– 20–30 = good for Daily
2. Use Avg Spread for Conversion
ON → Uses rolling average spread (more stable across sessions)
OFF → Uses live spread (tighter but noisier)
3. Z-Score Warning / Danger Thresholds
Defines when spread deviation is statistically stretched.
4. Spot & Futures Symbol Inputs
Default: OANDA:XAUUSD and COMEX:GC1!
Can be customized for your broker feed.
5. Spot Level Inputs
Add up to 6 spot levels (Support / Resistance / Key Level).
Script automatically converts and plots their futures equivalents.
📊 What the Z-Score Means
The Z-Score measures how far the current spread deviates from its rolling average.
0 = Spread is normal
±1 = Mild deviation
±2 = Statistically stretched
±2.5+ = Extreme condition
When Z-Score is extreme, converted levels may be less reliable because the basis is temporarily distorted.
Built for traders who understand that the spread matters.
goldtrader.substack.com
Pine Script® indicator






















