OPEN-SOURCE SCRIPT
UM VIX30/VIX Regime & Volatility Roll Yield

SUMMARY
A front-of-the-curve volatility indicator that compares spot VIX to a synthetic 30-day VIX (VIX30) built from VX1/VX2 futures, revealing early volatility pressure, regime shifts, and roll-yield transitions. Ideal for timing long/short volatility trades in VXX, UVXY, SVIX, and VIX futures.
DESCRIPTION
This indicator compares spot VIX to a synthetic 30-day constant-maturity volatility estimate (“VIX30”) built from VX1 and VX2 futures. The VIX30/VIX Ratio reveals short-term volatility pressure and regime shifts that traditional VX1/VX2 roll-yield alone often misses.
VIX30 is constructed using true calendar-day interpolation between VX1 and VX2, with VX1% and VX2% showing the real-time weights behind the 30-day volatility anchor. The table displays the volatility regime, the VX1/VX2 weights, spot-term roll yield (VIX30/VIX), and futures-term roll yield (VX2/VX1), giving a complete, front-of-the-curve perspective on volatility dynamics.
Use this to spot early volatility expansions, collapsing contango, and regime transitions that influence VXX, UVXY, SVIX, VX options, and VIX futures.
HOW IT WORKS
The script calculates the exact calendar days to expiration for the front two VIX futures. It then applies linear interpolation to blend VX1 and VX2 into a 30-day constant-maturity synthetic volatility measure (“VIX30”). Comparing VIX30 to spot VIX produces the VIX30/VIX Ratio, which highlights short-term volatility pressure and regime direction. A full term-structure table summarizes regime, VX1%/VX2% weights, and both spot-term and futures-term roll yields.
DEFAULT SETTINGS
VX1! and VX2! are used by default for front-month and second-month futures. These may be manually overridden if TradingView rolls contracts early. The default timeframe is 30 minutes, and the VIX30/VIX Ratio uses a 21-period EMA for regime smoothing. The historical threshold is set to 1.08, reflecting the long-run average relationship between VIX30 and VIX.
SUGGESTED USES
• Identify early volatility expansions before they appear in VX1/VX2 roll yield.
• Confirm contango/backwardation shifts with front-of-curve context.
• Time long/short volatility trades in VXX, UVXY, SVIX, and VX options.
• Monitor regime transitions (Low → Cautionary → High) to anticipate trend inflections.
• Combine with price action, Nadaraya-Watson trends, or MA color-flip systems for higher-confidence entries.
• MA red → green flips may signal opportunities to short volatility or increase equity exposure.
• MA green → red flips may signal opportunities to go long volatility, reduce equity exposure, or take short-equity positions.
ALERTS
Alerts trigger when the ratio crosses above or below the historical threshold or when the moving-average slope flips direction. A green flip signals rising volatility pressure; a red flip signals fading or collapsing volatility. These alert conditions can be used to automate long/short volatility bias shifts or trade-entry notifications.
FURTHER HINTS
• Increasing orange/red in the table suggests an emerging higher-volatility environment.
• SVIX (inverse volatility ETF) can trend strongly when volatility decays; on a 6-hour chart, MA green flips often align with attractive short-volatility opportunities.
• For long-volatility trades, consider shrinking to a 30-minute chart and watching for MA green → red flips as early entry cues.
• Experiment with different timeframes and smoothing lengths to match your trading style.
• Higher VIX30/VIX and VX2/VX1 roll yields generally imply faster decay in VXX, UVXY, and UVIX — or stronger upside momentum in SVIX.
• The author likes the 6-hour chart for short vol, and the 30-minute chart for long vol. Long vol trades are fast and furious so you want to be quick.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
David Franck
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
David Franck
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.