Pine Library · 2,503 open-source scripts

Free Volatility and Band Pine Scripts (page 29)

Open-source Pine scripts that measure how far price moves: Bollinger Bands, Keltner Channels, ATR stops and trailing lines, and squeeze indicators.

Pine scripts2,503
Code shown here1,334open licence
Updated in a year1,667
No repaint flag2,180

Volatility & bands: Indicators, Strategies and Libraries

EMA-Flat

by riegodavid-git
1 stars

A separate-pane indicator that measures how flat an exponential moving average is. It takes the absolute one-bar change of the EMA and divides it by the ATR, then plots that ratio as a histogram. Bars are teal when the ratio is below a flat threshold and orang

Indicator v5 TrendVolatility & bands
Updated 4 months ago · None stated GitHub repository of EMA-Flat

MA+SQZ+STO V1

by gabriel-klettur
1 stars

This strategy combines exponential moving averages, a Stochastic oscillator, and Squeeze Momentum calculations to identify long trade entries on the price chart. It enters long positions when the Stochastic K line crosses above D in oversold territory while pr

Strategy v5 TrendOscillators & momentum
Updated 7 months ago · None stated GitHub repository of MA+SQZ+STO V1
1 stars

This indicator combines Volume Weighted Bands, a Keltner Hull Suite, High Volume Nodes, and Supply and Demand Zones directly on the main price chart. It calculates a smoothed volume-weighted trend line surrounded by ATR-based bands to define market bias and hi

Indicator v6 TrendVolatility & bands
Updated 7 months ago · None stated GitHub repository of Keltner Hull Suite Integrated

Double EMA Crossover

by Basant1Saini
1 stars

The Double EMA Crossover strategy plots a fast 9-period EMA and slow 21-period EMA on the price chart with a 200-period trend EMA filter. It generates long signals on golden crosses when price exceeds the trend EMA and MACD is bullish, and short signals on dea

Strategy v5 TrendMoving averages
Updated 8 months ago · None stated GitHub repository of Double EMA Crossover

MegaBarAlgo

by Tradehook-org
1 stars

A Pine v5 script that detects unusually large candles on the price chart. A mega bar is one whose high-to-low range exceeds a multiple of its recent average range, optionally with volume above a multiple of average volume. Bullish bars get a green triangle and

Indicator v5 Volatility & bandsBreakout
Updated 8 months ago · None stated GitHub repository of MegaBarAlgo
1 stars

This indicator identifies market trends and projects dynamic price targets directly on the price chart. It calculates high and low bands using simple moving averages offset by a smoothed Average True Range buffer. Bullish and bearish trend signals trigger when

Indicator v5 TrendMoving averages
Updated 9 months ago · None stated GitHub repository of Target Trend [BigBeluga]

BB Volume

by nvFede
1 stars

A Pine v4 indicator that plots volume multiplied by VWAP as columns, coloured by where the bar midpoint sits against Bollinger Bands on price. Blue columns mean the midpoint is between the middle and upper band, red between the middle and lower band, and a pal

Indicator v4 VolumeVolatility & bands
Updated 3 years ago · None stated GitHub repository of BB Volume
257 stars

This overlay strategy is built for ES futures on the one-minute chart. It plots a volume-weighted moving average of price opens and standard-deviation bands at Fibonacci ratios, plus a second longer volume-weighted average from a higher-timeframe open. Call an

Strategy v5 Volatility & bandsMoving averages
Updated 7 weeks ago · None stated GitHub repository of ES Futures 1M No Repaint

Dynamic Linear Regression

by TradersPost
228 stars

Dynamic Linear Regression calculates and plots linear regression trendlines and standard deviation channels directly on the price chart over a user-selected time period. Traders can configure static channels locked at the end time, dynamic channels that contin

Indicator v6 TrendSupport & resistance
Updated 3 months ago · None stated GitHub repository of Dynamic Linear Regression
114 stars

This indicator plots a dynamic step trendline directly on the price chart using Kaufman Efficiency Ratio (ER). It blends short and long standard deviations based on price efficiency to construct adaptive step thresholds. Trend flips trigger buy and sell signal

Indicator v4 TrendVolatility & bands
Updated 1 year ago · None stated GitHub repository of Efficient Trend Step Mod
46 stars

This indicator calculates and plots standard deviation projection levels based on historical session ranges. It draws the session open line alongside positive and negative standard deviation bands (0.5, 1.0, 2.0, 3.0, and 4.0 SD) directly on the main chart, ac

Indicator v6 Sessions & timeVolatility & bands
Updated 8 weeks ago · None stated GitHub repository of Session Standard Deviations with Stats
29 stars

This indicator calculates the current bar's high-minus-low range in points, excluding overnight gaps. It then computes a simple moving average of that range over a user-set length and the ratio of the current range to that average. The length input defaults to

Indicator v5 Volatility & bands
Updated 2 weeks ago · MIT GitHub repository of Average Bar Range Stats
16 stars

This strategy enters long or short when price breaks a Keltner channel built from an exponential moving average and an ATR multiple. It sizes each unit from a fixed equity risk percentage and an ATR stop, then can add units as price moves in the trade directio

Strategy v6 TrendVolatility & bands
Updated 12 months ago · None stated GitHub repository of Seykota Alt 23: Keltner Channel
8 stars

MA ATR ADX PP Strategy combines customizable moving averages with Average True Range (ATR) and Average Directional Index (ADX) filters to generate trade entries and exits on the main chart. The script supports eight moving average types, including SMA, EMA, Hu

Strategy v4 Moving averagesTrend
Updated 4 years ago · None stated GitHub repository of MA+ATR+ADX+PP Strategy
7 stars

This indicator plots a standard Relative Strength Index calculated from closing prices alongside a dynamic volatility band derived from the high and low price RSIs. The upper and lower bands envelope the main RSI line to highlight intrabar price extremes relat

Indicator v6 Oscillators & momentumVolatility & bands
Updated 3 months ago · None stated GitHub repository of RSI Divergence (Close inside Band)

Candlestick RSI

by suyons
7 stars

Calculates individual Relative Strength Index (RSI) values for price open, high, low, and close to render RSI as candlesticks in a separate pane. Users can toggle between candlestick and line displays. It includes customizable overbought and oversold threshold

Indicator v5 Oscillators & momentumVolatility & bands
Updated 4 months ago · None stated GitHub repository of Candlestick RSI
6 stars

This indicator classifies price action into four distinct market regimes: Trend, Expansion, Compression, or Mean Reversion. It determines states using a simplified Hurst exponent estimate, ADX slope thresholds, and realized volatility measurements. Based on th

Indicator v6 TrendVolatility & bands
Updated 2 months ago · MIT GitHub repository of Capital41 Regime Matrix v3

This indicator plots multi-timeframe Exponential Moving Averages alongside double Bollinger Bands directly on the price chart. It calculates three EMAs (short, medium, and long term) fetched from configurable higher timeframes, alongside two sets of Bollinger

Indicator v4 TrendVolatility & bands
Updated 3 years ago · Apache-2.0 GitHub repository of Bollinger Bands Squeeze / Trend + EMAs

TRCD + Scaled RLI

by InNoobWeTrust
4 stars

This indicator draws in a separate pane and combines a true-range component with a scaled relative liquidity index. The liquidity reading applies RSI to ATR and can tint a gradient background between low and high liquidity colors. Optional tables show an ATR-b

Indicator v6 Volatility & bandsOscillators & momentum
Updated 2 days ago · None stated GitHub repository of TRCD + Scaled RLI
4 stars

This strategy trades E-mini and Micro E-mini S&P 500 futures on the price chart. It enters long when a fast EMA crosses above a slow EMA during New York regular trading hours, and enters short on the opposite cross unless long-only mode is on. Each entry place

Strategy v6 TrendMoving averages
Updated 2 months ago · MIT GitHub repository of ES S&P500 Strategy [trugurpala]
4 stars

This strategy plots Bollinger Bands on the price chart using a simple moving average basis and a standard-deviation multiplier. Optional RSI, long-period Aroon, and EMA or SMA filters are present but stay disabled unless a password enables the PRO path. Long e

Strategy v4 Volatility & bandsOscillators & momentum

YORUKALIEFE

by Kalumur
4 stars

This indicator plots multiple exponential moving averages on weekly and monthly timeframes, including 14-period weekly EMA, 8-period monthly EMA, and 14-period monthly EMA. It also displays a Kijun line derived from the midpoint of high and low over 20 periods

Indicator v5 Moving averagesVolatility & bands
Updated 2 years ago · None stated GitHub repository of YORUKALIEFE
3 stars

The River Strategy with SuperScalper plots custom Bollinger Bands to form a price channel on the main chart overlay. It identifies breakout conditions when price bars clear the channel boundaries to generate entry, stop loss, and multi-tier take profit levels.

Indicator v5 Volatility & bandsSupport & resistance Repaints
Updated 12 months ago · None stated GitHub repository of River Strategy with SuperScalper by Leo

This indicator computes standard deviation as a proxy for entropy and plots three smoothed, normalized oscillator lines in a separate pane. It calculates fast, medium, and slow simple moving averages of price dispersion, then normalizes each using a Z-score sc

Indicator v5 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Pseudo-Entropy Oscillator with Standard Deviation
2 stars

Calculates the Relative Strength Index oscillator in a separate pane with configurable overbought and oversold thresholds. Includes options for smoothing the RSI line using various moving averages or Bollinger Bands, gradient fill zones, and regular divergence

Indicator v6 Oscillators & momentumVolatility & bands
Updated 12 days ago · MIT GitHub repository of RSI = Relative Strength Index

Volume Price Analysis

by TamTH-Dev
2 stars

The Volume Price Analysis (VPA) indicator computes the Rate of Flow (RoF) from price and volume data using selected moving average types. It applies smoothing and signals for analysis, with normalization for subjective value levels. Plots appear in a separate

Indicator v6 VolumeMoving averages
Updated 6 weeks ago · None stated GitHub repository of Volume Price Analysis

Alpy

by avatar-lavventura
2 stars

This strategy calculates a Volume-Weighted Moving Average (VWMA) sourced from a 60-minute timeframe to generate upper and lower channel bands based on user-defined percentage offsets. It incorporates RSI and Williams Fractals logic to evaluate potential entry

Strategy v4 Moving averagesTrend Repaints
Updated 7 months ago · None stated GitHub repository of Alpy

Pinbar Strategy

by Web3Degenerate
2 stars

This strategy identifies pin bar candlestick patterns, specifically hammer and shooting star candles, to trigger trade entries. It detects candle shapes based on a customizable Fibonacci threshold. Signals can be filtered using minimum and maximum ATR candle s

Strategy v5 Candlestick patternsTrend
Updated 2 years ago · None stated GitHub repository of Pinbar Strategy
2 stars

This overlay indicator combines a ZigZag swing plot, Fibonacci retracement levels, and a linear regression channel on the price chart. Pivot points use an ATR-based deviation multiplier and a minimum depth, and optional lines can extend left or right with pric

Indicator v4 TrendVolatility & bands Repaints
Updated 3 years ago · None stated GitHub repository of LinReg with RSI and Zigzag

P Synthetic Conditional Calls

by GammaExpansion
1 stars

This indicator in Pine Script v6 calculates and plots three lines on a separate pane. It uses an input to choose between EMA or SMA of close over 10 periods for the main line. The second line applies RSI of close over 14 periods only when close exceeds open. T

Indicator v6 Moving averagesOscillators & momentum
Updated 7 days ago · MIT GitHub repository of P Synthetic Conditional Calls
1 stars

This strategy compares Bollinger Bands and Keltner Channel to detect volatility regimes. It plots the bands and their difference along with the RSI of the difference on the price chart. Entries and exits occur on transitions in the volatility state, controlled

Strategy v5 Volatility & bandsOscillators & momentum
Updated 8 days ago · None stated GitHub repository of Penguin Volatility State Strategy
1 stars

Reversal RSI Stochastic ATR is an indicator that prints a reversal label when RSI is beyond its oversold or overbought level and the stochastic K line crosses D inside its own extreme zone. On each signal it draws stop loss and take profit lines at an ATR mult

Indicator v6 Mean reversionOscillators & momentum
Updated 4 months ago · MPL-2.0 GitHub repository of Reversal RSI Stochastic ATR
1 stars

This indicator combines Volume Weighted Bands, a Hull Moving Average with Keltner Channels, and a Swing Profile directly on the price chart. It calculates volume-weighted trend lines, ATR volatility bands, and swing structures to plot dynamic support and resis

Indicator v6 TrendMoving averages
Updated 7 months ago · None stated GitHub repository of Keltner Hull Swing Profile

EMA Ribbon

by Basant1Saini
1 stars

The EMA Ribbon strategy plots six exponential moving averages (periods 8, 13, 21, 34, 55, 89) on the price chart to form a visual ribbon. It detects trend direction using full stack alignment, partial alignment (at least 4 of 6 consecutive pairs), or fast EMA

Strategy v5 TrendMoving averages
Updated 8 months ago · None stated GitHub repository of EMA Ribbon
1 stars

A Pine v5 strategy that trades a breakout from a narrow range bar. A bar is narrow when its range is below a set fraction of the average range. Its high and low are stored and drawn as levels, and a close above the high opens a long while a close below the low

Strategy v5 BreakoutVolatility & bands
Updated 8 months ago · None stated GitHub repository of NRBOAlgo Narrow Range Breakout
1 stars

Target Trend is a trend-following overlay indicator that determines market direction using ATR-adjusted simple moving average bounds. It calculates upper and lower channel boundaries based on SMA calculations of high and low prices offset by a smoothed ATR val

Indicator v5 TrendSupport & resistance
Updated 9 months ago · None stated GitHub repository of Target Trend [BigBeluga]

EMA Strategy

by capissimo
114 stars

Calculates a central Exponential Moving Average with upper and lower channel bands offset by a fixed pip distance, inspired by LazyBear's Pip Collector script. Generates buy and sell signals when price interacts with the envelope bands, with an optional ATR vo

Indicator v4 TrendMoving averages
Updated 1 year ago · None stated GitHub repository of EMA Strategy

SuperTrend & Pivots

by dcaoyuan
55 stars

This overlay indicator plots a SuperTrend line on the price chart using a fixed ATR length of 10 and a factor of 3. When the trend direction is up it draws a green line and a light green fill toward the candle midpoint; when down it draws a red line and a ligh

Indicator v6 TrendVolatility & bands
Updated 6 months ago · Apache-2.0 GitHub repository of SuperTrend & Pivots

Bollinger Bands

by TWODS-CAPITAL
37 stars

This indicator calculates and plots standard Bollinger Bands directly on the price chart. It computes a central basis line using a simple moving average of the selected price source over a user-defined period. Upper and lower bands are constructed by adding an

Indicator v5 Volatility & bandsMoving averages
Updated 3 years ago · MIT GitHub repository of Bollinger Bands

Stochtaker

by benso87
24 stars

Stochtaker combines a Stochastic oscillator and Bollinger Band Width Percentile (BBWP) into a single separate pane indicator. It calculates BBWP across a configurable lookback period and length, displaying volatility conditions using a dynamic color spectrum o

Indicator v5 Oscillators & momentumVolatility & bands
Updated 4 years ago · MPL-2.0 GitHub repository of Stochtaker

This strategy trades Donchian breakouts on the price chart and sizes each unit from a percentage of equity. It allows long and short entries, places an ATR initial stop, trails with a chandelier stop, and can add units as price moves by a multiple of ATR, up t

Strategy v6 TrendVolatility & bands
Updated 12 months ago · None stated GitHub repository of Seykota Alt 24: Vol-Adjusted Targets

Commodity Heat Reversal plots score-based mean-reversion reversal markers on the price chart for commodity futures, aimed at the four-hour timeframe. It builds separate long and short heat scores from ATR distance to a mean moving average, ATR expansion, RSI e

Indicator v6 Mean reversionVolatility & bands
Updated 3 days ago · MIT GitHub repository of Commodity Heat Reversal [WavesUnchained]

Cerebr Wave

by jerryinyang
5 stars

Cerebr Wave is an overlay indicator that combines multi-timeframe Keltner Channels with a Wave Trend oscillator to analyze market structure and momentum. It calculates higher-timeframe and lower-timeframe Keltner Channels alongside Wave Trend crossover signals

Indicator v4 TrendOscillators & momentum
Updated 2 years ago · None stated GitHub repository of Cerebr Wave

Bollinger Squeeze STEPFUN

by eltonaguiar
4 stars

This strategy detects Bollinger Band squeezes by measuring band width against a threshold. It waits for a confirmed breakout in either direction when bands expand, using optional volume confirmation. Long and short signals trigger on breakout after squeeze. Po

Strategy v5 Volatility & bandsBreakout
Updated 2 days ago · None stated GitHub repository of Bollinger Squeeze STEPFUN

More Pine Script Categories

Browse the whole Pine Library

Third-party code. ForexR lists open-source Pine scripts from GitHub; it did not write, test or endorse them, and their summaries are generated automatically from each script's code and README. Indicators describe the past, and a strategy's backtest can look better than live trading. Check a script on a demo account before you rely on it. CFDs and leveraged forex are complex instruments with a high risk of losing money rapidly.

Learn to Use Pine Scripts

Free, plain-English guides: add a script to TradingView, read what it does, test it and avoid the common traps.

  1. 1Using this librarySearch, filters, licences and what the badges mean.
  2. 2Add a script to TradingViewCopy, paste into the Pine Editor, save and add to chart.
  3. 3Indicators, strategies and librariesWhat each type does and how to tell them apart.
  4. 4Spot a script that repaintsWhy some signals change after the bar closes.
  5. 5Backtest a strategyStrategy Tester settings that keep results honest.
  6. 6Send alerts to MT4 or MT5From a TradingView alert to an order in MetaTrader.
  7. 7What Pine Script isThe language, what it can and cannot do, and where to start.
  8. 8Write your first indicatorA complete script, line by line, in the Pine Editor.
  9. 9Read a script before you trust itA routine for checking inputs, logic and red flags.
  10. 10Edit a script safelyChange colours and lengths, add a filter or an alert.
  11. 11Pine Script alertsalertcondition(), alert(), placeholders and webhooks.
  12. 12Build a crossover strategyAn EMA cross strategy with an ATR stop, ready to test.

Trade Your Charts With a Regulated Broker

Compare regulated brokers on platforms, spreads, minimum deposit and leverage.

Compare brokers