Volatility ChannelPine Script v6

STARC Bands Pine Script — Complete TradingView Guide

STARC Bands (Stoller Average Range Channel) are an ATR-based volatility channel indicator in Pine Script that plot three lines directly on your TradingView price chart: a 6-period Simple Moving Average as the middle band, and upper and lower channels spaced 2× ATR (15-period) above and below it. Developed by Manning Stoller in the 1980s, STARC Bands help traders identify when price is statistically expensive (touching the upper band) or cheap (touching the lower band) relative to recent true range. Unlike Bollinger Bands which use standard deviation, STARC Bands use ATR — making them smoother and more resistant to gap-driven distortions. They work across all asset classes — stocks, crypto, forex, and futures — on timeframes from 30-minute intraday charts to daily swing-trading charts. This complete guide covers the full Pine Script v6 implementation, all configurable parameters, three proven trading strategies, and step-by-step instructions for generating your customized STARC Bands script instantly with Pineify.

What Are STARC Bands?

STARC Bands are a volatility channel indicator that consists of a short-period SMA as the middle band flanked by upper and lower channels placed a multiple of ATR above and below it, used to identify when price is overextended relative to recent true range. Developed by American trader Manning Stoller in the 1980s, the indicator's name is an acronym for Stoller Average Range Channel. It was popularized through Stoller's work in the futures and equities markets and has since been included in most professional charting platforms including TradingView.

The three components are:

  • Middle Band (Basis): A 6-period Simple Moving Average of the closing price. Formula: basis = SMA(close, 6)
  • Upper Band: Basis plus ATR multiplied by the factor. Formula: upper = basis + 2 × ATR(15)
  • Lower Band: Basis minus ATR multiplied by the factor. Formula: lower = basis − 2 × ATR(15)

The ATR in Stoller's original formula is computed as SMA(TrueRange, 15) — a simple moving average of the True Range, not Pine Script's built-in ta.atr() which uses RMA smoothing. This distinction produces slightly wider, more stable bands that are less influenced by single extreme candles.

The key insight behind STARC Bands is that price touching the upper band is relatively expensive in terms of recent average true range — representing a low-risk short entry or exit point — while price touching the lower band is relatively cheap — representing a low-risk long entry or a short exit. Unlike overbought/oversold oscillators, STARC Bands adapt dynamically to current market volatility.

STARC Bands are applicable across all liquid markets: equities (stocks, ETFs), cryptocurrency (BTC, ETH, altcoins), foreign exchange (EUR/USD, GBP/JPY), and futures (ES, NQ, crude oil). They perform best on timeframes from 30-minute to Daily charts. On very short timeframes (1m, 5m), the ATR-based width may be too narrow to filter noise effectively. On weekly charts, STARC Bands define major support and resistance zones aligned with long-term volatility regimes.

Best Markets

Stocks · Crypto · Forex · Futures

Best Timeframes

30m, 1H, 4H, Daily

Overlay

Yes — plots directly on price chart

STARC Bands Pine Script Code

The Pine Script v6 code below plots the complete STARC Bands overlay — basis SMA, upper ATR channel, lower ATR channel, and a semi-transparent fill — directly on the TradingView price chart. Copy the code, open the TradingView Pine Script editor (Alt+P), paste it in, and click Add to chart. You can change the ATR length, basis basis_length, and multiplier values to suit your trading style without modifying the rest of the script.

Pine Script v6
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © Pineify

//@version=6
indicator(title="STARC Bands", overlay=true, max_labels_count=500)

// STARC Bands core calculation
// ATR is calculated using ta.sma of True Range (not ta.atr) — matching Stoller's original formula
p_ta_starc_bands(series float source, simple int length, simple int basis_length, simple float multiplier) =>
    tr = math.max(high - low, math.max(math.abs(high - source[1]), math.abs(low - source[1])))
    atr = ta.sma(tr, length)
    basis = ta.sma(source, basis_length)
    upper = basis + multiplier * atr
    lower = basis - multiplier * atr
    [basis, upper, lower]

[p_ind_1_basis, p_ind_1_upper, p_ind_1_lower] = p_ta_starc_bands(close, 15, 6, 2)

// Plot the three STARC Bands lines + band fill
plot(p_ind_1_basis, "STARC Bands - Basis", color.rgb(0, 0, 255, 0), 2)
p_ind_1_upper_plot = plot(p_ind_1_upper, "STARC Bands - Upper", color.rgb(242, 54, 69, 0), 2)
p_ind_1_lower_plot = plot(p_ind_1_lower, "STARC Bands - Lower", color.rgb(76, 175, 80, 0), 2)
fill(p_ind_1_upper_plot, p_ind_1_lower_plot, title = "STARC Bands - Band", color=color.rgb(192, 192, 192, 0))

Chart Preview

STARC Bands indicator Pine Script code example in TradingView — upper, basis, and lower ATR channels with fill

STARC Bands Parameters

ParameterDefault ValueDescriptionRecommended Range
length15The number of bars used to calculate the SMA of True Range (the ATR period). Higher values produce smoother, wider bands; lower values make the bands more reactive to sudden volatility spikes.8–20 (15 is Stoller's standard)
basis_length6The number of bars for the SMA that forms the middle band (basis). A shorter period keeps the basis close to price; a longer period smooths out noise and acts more like a trend line.5–20 (6 for intraday, 10–15 for swing)
multiplier2.0The ATR factor that determines how far the upper and lower bands sit from the basis. A higher multiplier widens the channel, reducing the frequency of band touches; a lower multiplier tightens the channel.1.5–3.0 (2.0 standard; 1.5 for scalping)
sourcecloseThe price series used for the basis SMA calculation. Most traders use close; some use hlc3 (typical price) for a smoother basis.close (standard) or hlc3

Tuning Guide by Trading Style

  • Scalping (5m–15m charts): length 8, basis_length 5, multiplier 1.5 — tighter bands give faster mean-reversion signals
  • Day trading (30m–1H charts): length 15, basis_length 6, multiplier 2.0 — Stoller's original settings
  • Swing trading (4H–Daily charts): length 15, basis_length 10, multiplier 2.5 — wider channel filters out intraday noise
  • Position trading (Daily–Weekly charts): length 20, basis_length 15, multiplier 3.0 — slow, wide bands for major support/resistance zones

STARC Bands Trading Strategies

STARC Bands generate three categories of signals: mean-reversion trades when price tags the outer bands, channel breakout entries when price closes outside the channel, and trend-continuation signals using the basis SMA as dynamic support/resistance. The following strategies use numbered conditions for precise implementation in TradingView Pine Script.

Strategy 1 — Upper/Lower Band Mean Reversion

Market environment: ranging / sideways markets · Best timeframe: 30m, 1H

Manning Stoller designed STARC Bands specifically for mean-reversion entries — buying at the lower band when price is cheap relative to ATR and selling at the upper band when it is expensive. Combine with ta.rsi(close, 14) to confirm oversold/overbought conditions.

  1. Confirm ranging market: ADX(14) < 25 (no strong trend present)
  2. Long entry: close touches or crosses below the lower STARC band AND RSI(14) < 35
  3. Short entry: close touches or crosses above the upper STARC band AND RSI(14) > 65
  4. Target: the basis SMA (middle band)
  5. Stop loss: 1× ATR(15) beyond the entry band

Strategy 2 — STARC Channel Breakout

Market environment: trending / breakout conditions · Best timeframe: 1H, 4H, Daily

When price closes above the upper STARC band on above-average volume, it signals a genuine volatility breakout rather than a mean-reversion extreme. This strategy rides the breakout momentum. Pair with ta.macd() histogram to confirm momentum direction.

  1. Confirm uptrend context: price above EMA(50) on the same timeframe
  2. Long entry: close > upper STARC band AND MACD histogram > 0 AND volume > 20-bar average volume
  3. Short entry: close < lower STARC band AND MACD histogram < 0 AND volume > 20-bar average volume
  4. Exit: close crosses back through the basis SMA
  5. Stop loss: 1.5× ATR(15) from entry price

Strategy 3 — Basis SMA Trend Pullback

Market environment: strong trending markets · Best timeframe: 4H, Daily

In trending markets, the 6-period basis SMA acts as a dynamic support (in uptrends) or resistance (in downtrends). Price pulling back to the basis without reaching the lower band provides a low-risk trend-continuation entry. Pair with a 200-period EMA for overall trend context.

  1. Confirm uptrend: close > EMA(200) on the daily chart
  2. Entry trigger: price pulls back to the basis SMA (within 0.2× ATR) without touching the lower band
  3. Confirmation: the next bar closes above the basis SMA with RSI(14) > 45
  4. Target: the upper STARC band
  5. Stop loss: below the lower STARC band

Disclaimer: The strategies above are for educational purposes only and do not constitute investment advice. Past performance does not guarantee future results. Always apply proper risk management and position sizing.

How to Generate STARC Bands in Pineify

  1. 1

    Open Pineify

    Go to pineify.app and sign in — a free account gives full access to the AI Coding Agent. No credit card required.

  2. 2

    Click "New Indicator"

    Select "Indicator" as the script type from the creation menu. Pineify will open the AI coding workspace.

  3. 3

    Describe your STARC Bands setup

    Type a prompt such as: "Add STARC Bands with ATR length 15, basis SMA length 6, and multiplier 2." You can also request variants like a tighter multiplier of 1.5 for scalping or an EMA-based ATR smoothing.

  4. 4

    Copy the generated script to TradingView

    Click "Copy to TradingView" to copy the full Pine Script v6 code, then paste it into the TradingView Pine Script editor (Alt+P) and click "Add to chart" to see the STARC Bands live on your chart.

  5. 5

    Adjust parameters in TradingView settings

    Open the indicator settings panel in TradingView to change the ATR length (default 15), basis length (default 6), and multiplier (default 2.0) without editing code. Try multiplier 1.5 for scalping or 3.0 for position trading.

Frequently Asked Questions

Build Your STARC Bands Script in Seconds

Skip the manual coding. Pineify's AI Coding Agent generates complete, ready-to-use Pine Script STARC Bands indicators — including custom ATR periods, multipliers, and basis SMA lengths — instantly for free.

Try Pineify Free