Pine Library · 2,503 open-source scripts

Free Volatility and Band Pine Scripts (page 50)

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

106 stars

This strategy plots an ATR trailing stop on the price chart. It builds the stop from the highest value of high minus a multiple of ATR over a lookback window, and colors bars green, red, or black relative to that line. It enters long when close crosses above t

Strategy v4 TrendVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of ATR Trailing Stoploss Strategy

ATR+EOM+Vortex Strat

by hasnocool
106 stars

This strategy combines ATR, Ease of Movement, and the Vortex indicator on the price chart. It enters long when ATR is above its EMA, Ease of Movement is positive, and the average of the Vortex lines is above one. It closes that long when ATR is below its EMA,

Strategy v4 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of ATR+EOM+Vortex Strat
2 stars

This indicator analyzes and visualizes the statistical price impact following specific Relative Strength Index (RSI) trigger conditions. When the RSI crosses over or under a defined threshold level, the script measures post-trigger price movements across a spe

Indicator v5 Oscillators & momentumVolatility & bands
Updated 8 months ago · None stated GitHub repository of RSI Impact Heat Map [Trendoscope]

ATR_Trade_strategy

by hasnocool
106 stars

This strategy plots daily ATR bands, an optional midline, and an exponential moving average directly on the price chart. It executes long trades when price breaks above the upper ATR band and opens short positions when price falls below the lower band, with an

Strategy v4 Volatility & bandsBreakout Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of ATR_Trade_strategy

Atrend by OTS

by hasnocool
106 stars

Atrend by OTS combines MACD histogram crossovers, RSI threshold crosses, and an ATR-based trailing trend indicator on the main price chart. The strategy triggers long entries when the MACD signal delta crosses above zero or when RSI crosses above the oversold

Strategy v4 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Atrend by OTS

Parabolic SAR

by g-moe
3 stars

This strategy overlays a smoothed moving average on price and combines it with Aroon, Chaikin Money Flow and a Chaikin oscillator to define long and short conditions. Relative Vigor Index and Parabolic SAR values are calculated for exits. Entries can be limite

Strategy v5 TrendOscillators & momentum
Updated 5 months ago · None stated GitHub repository of Parabolic SAR

3Commas Bot

by regalouisei
2 stars

This strategy draws two moving averages on the price chart and uses their bias to open long or short trades. It places the stop beyond a swing high or low using an ATR risk multiple, then sets a limit exit from the reward-to-risk ratio. An optional ATR trail c

Strategy v5 TrendMoving averages
Updated 8 months ago · None stated GitHub repository of 3Commas Bot
1 stars

This indicator plots the original simple moving average, a symmetric moving average calculated from the highest and lowest moving averages over the window length, and a dynamic midline. It generates buy signals when the deviation from the symmetric moving aver

Indicator v5 Moving averagesTrend
Updated 7 weeks ago · None stated GitHub repository of Symmetric MA Reversal Signals

An automated trend-following investment strategy designed for Bitcoin. It compares two customizable trend lines (such as TEMA, LSMA, EMA, or SMA) to detect crossovers and filters entries using an ATR-based trailing stop channel. Positions are exited when the p

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Automated Bitcoin (BTC) Investment Strategy
99 stars

This overlay indicator plots a channel of the highest high and the lowest low over a rolling lookback. It updates both extremes with a monotonic deque so each bar is handled in amortized constant time, then draws the upper and lower lines on the price chart an

Indicator v6 Support & resistanceVolatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Min-Max Channel (MMCHANNEL)

3D Sine Wave

by regalouisei
2 stars

This indicator plots a 3D sine wave in a separate pane. It calculates wave values using bar index, wave height and duration inputs. Lines form a wave shape with top, bottom, left and right fills based on coloring style. Regular or irregular shape option change

Indicator v5 Support & resistanceVolatility & bands
Updated 8 months ago · None stated GitHub repository of 3D Sine Wave

Av3

by hasnocool
106 stars

Av3 is a price-chart strategy that compares the current seven-period ATR with the average of the previous five ATR values. When ATR is above that average it buys if the open is above the prior close and sells if the open is below it; when ATR is below the aver

Strategy v4 Volatility & bands Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Av3

Pivot Trendlines

by g-moe
3 stars

This strategy overlays two SMA lines with a cloud fill to show trend direction. It detects band reversals with Bollinger Bands and uses RSI for mean-reversion signals. Long entries trigger when the trend is bullish, price touches the lower band, and RSI is bel

Strategy v5 TrendOscillators & momentum
Updated 5 months ago · None stated GitHub repository of Pivot Trendlines

BB + ADX Strategy

by hasnocool
106 stars

The BB + ADX Strategy triggers entries when price crosses Bollinger Bands during low-trend market conditions as filtered by the Average Directional Index (ADX). It enters long when price crosses above the lower band and short when price crosses below the upper

Strategy v4 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of BB + ADX Strategy

BB+RSI+OBV

by hasnocool
106 stars

This strategy combines Bollinger Bands, the Relative Strength Index (RSI), and On-Balance Volume (OBV) to generate trade signals directly on the price chart. Long entries trigger when price is above the middle SMA band, RSI is over 50, and OBV is rising. Short

Strategy v4 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of BB+RSI+OBV

BB-strategy

by hasnocool
106 stars

This strategy executes trades based on Bollinger Bands with optional filter conditions from RSI and MACD oscillators. It overlays on the price chart and plots MACD lines directly across the bars. Entries trigger according to band interactions combined with mom

Strategy v4 Volatility & bandsOscillators & momentum Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of BB-strategy

BB9 MA200 Strategy

by hasnocool
106 stars

A trend-following strategy combining Bollinger Bands with a long-term moving average filter. It plots a 200-period EMA along with standard 21-period Bollinger Bands directly on the price chart. Long entries trigger when both the upper and lower Bollinger Bands

Strategy v4 TrendVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of BB9 MA200 Strategy
1 stars

This indicator calculates a simple moving average (SMA) alongside a zero-centered symmetrized price series and its moving average. It uses Average True Range (ATR) to create a dynamic price offset, plotting a stepline translated moving average along with an up

Indicator v5 Moving averagesVolatility & bands
Updated 7 weeks ago · None stated GitHub repository of Symmetrized MA & Dynamic Offset
106 stars

This strategy plots a volume-weighted average price, Bollinger Bands built on that VWAP, a 200-period simple moving average, and Fibonacci pivot levels in a separate pane. It opens a long position when VWAP crosses above the band basis and the close is at or a

Strategy v4 Volatility & bandsSupport & resistance
Updated 2 years ago · GPL-3.0 GitHub repository of BBofVWAP with entry at Pivot Point

BBPBΔ(OBV-PVT)BB

by hasnocool
106 stars

This strategy calculates the normalized rate of change between On-Balance Volume (OBV) and Price Volume Trend (PVT) indicators. It applies Bollinger Bands to this volume metric along with a Hodrick-Prescott filter array for time series decomposition. Displayed

Strategy v4 VolumeVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of BBPBΔ(OBV-PVT)BB

BB策略

by hasnocool
106 stars

BB策略 is an overlay strategy combining standard Bollinger Bands with candlestick pattern recognition logic, including engulfing patterns, dojis, and long upper shadows. It calculates an SMA basis line and standard deviation bands, plotting them directly on the

Strategy v4 Volatility & bandsCandlestick patterns
Updated 2 years ago · GPL-3.0 GitHub repository of BB策略

Fair value bands

by regalouisei
2 stars

This overlay indicator plots a fair value basis on the price chart and surrounds it with threshold and deviation bands. The basis can be an SMA, EMA, HMA, RMA, WMA, VWMA, median, or a VWAP anchored to a chosen timeframe, using a selectable price source and len

Indicator v5 Moving averagesVolatility & bands
Updated 8 months ago · None stated GitHub repository of Fair value bands

Big Bar Strategy

by hasnocool
106 stars

Big Bar Strategy identifies unusually large candles relative to a moving average of recent bar body sizes. It executes contrarian trades by opening long positions following a large bearish bar and short positions after a large bullish bar, with an optional con

Strategy v4 Mean reversionVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Big Bar Strategy

Time Machine Pro

by morindok
1 stars

Time Machine Pro is an overlay drawing tool that reflects historical price between two user-selected price levels and two times. It measures green and red candle distances by sum, simple average, or volume-weighted average, then plots spirals or vertical lines

Indicator v5 Support & resistanceVolatility & bands
Updated 7 weeks ago · None stated GitHub repository of Time Machine Pro
1 stars

Time Machine is an overlay indicator that calculates historical price reflections using Fibonacci levels, SMA variants, Bollinger Bands, VWAP, and spiral spine methods. It plots symmetric price lines around dashed levels and dynamic indicator lines, plus area

Indicator v5 Support & resistanceMean reversion
Updated 7 weeks ago · None stated GitHub repository of Time Machine{Morindok}

Bolinger strategy

by hasnocool
106 stars

This long-only strategy combines a five-bar RSI with Bollinger percent B and bandwidth on the current close and the close three bars earlier. It opens a long when a local low around that earlier bar falls inside a bar-count window and current percent B stays i

Strategy v4 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Bolinger strategy
106 stars

The Bollinger %B Candles Strategy evaluates price volatility and momentum by calculating Bollinger Bands %B oscillator values in a separate pane. It incorporates customizable moving average filters, ATR multipliers, and optional higher-timeframe yearly high or

Strategy v4 Volatility & bandsMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger %B Candles Strategy

This strategy builds a 3x3 covariance matrix from three collinear price series (close, close*2, close*3) and evaluates its eigenvalues to detect rank deficiency via NaN propagation. It generates long entries and exits using a 9/21 EMA crossover on the price ch

Strategy v6 Moving averagesVolatility & bands
Updated 6 days ago · Apache-2.0 GitHub repository of PF typed-matrix probe 02 - eigen rank deficient
106 stars

This strategy plots a 20-period simple moving average of the close and Bollinger bands from one through five standard deviations. It draws the basis and each upper and lower band on the price chart, then fills the zones between successive bands in different co

Strategy v4 Volatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger band (band display 5σ)

Indicators Overlay

by regalouisei
2 stars

Indicators Overlay plots up to ten technical indicators directly on the main price chart using line drawings, avoiding the need for separate sub-panes. It calculates common technical metrics such as RSI, CCI, OBV, Stochastic, MFI, ATR, CMO, CMF, Stochastic RSI

Indicator v5 Oscillators & momentumVolatility & bands
Updated 8 months ago · None stated GitHub repository of Indicators Overlay
106 stars

This strategy enters long positions during a specified trading session when multiple technical indicators align. It executes a buy order when the low drops below the lower Bollinger Band while RSI and ADX exceed configurable threshold values, price closes abov

Strategy v4 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Band + RSI + ADX + MACD
106 stars

Bollinger Band Breakout is a positional strategy combining Bollinger Bands with the Relative Strength Index (RSI). It opens long positions when price crosses above the upper Bollinger Band while 14-period RSI is between 60 and 70. Short entries trigger when pr

Strategy v4 Volatility & bandsOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Band Breakout
1 stars

This Pine Script v6 strategy is a validation probe for nested method calls on a user-defined type. Each bar it feeds close, a simple moving average, and standard deviation through a method chain that returns a z-score. It enters long only when that z-score is

Strategy v6 Moving averagesVolatility & bands
Updated 6 days ago · Apache-2.0 GitHub repository of PF UDT probe 18 - method calls method

This strategy combines Volume Weighted Moving Average (VWMA) Bollinger Bands with 200-period and 50-period Exponential Moving Averages (EMAs). It identifies long trade opportunities when the 50 EMA is above the 200 EMA and price falls to or below the lower Fib

Strategy v4 TrendVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Band with Fib Golden Ratio (0.618)
1 stars

Zero-Lag Fractal KdV Smoothing is an indicator that applies fractal dimension-based smoothing to price data using a KdV-like wave equation. It computes a weighted average between the current close price and the prior filtered value, where the weights depend on

Indicator v5 Moving averagesVolatility & bands
Updated 7 weeks ago · None stated GitHub repository of Zero-Lag Fractal KdV Smoothing
106 stars

This strategy plots RSI in a separate pane and combines it with Bollinger Bands calculated on the selected source. It opens a long when RSI is below 30 and price is below the lower band, then closes that long when RSI rises above 70. Percentage take-profit and

Strategy v4 Oscillators & momentumVolatility & bands Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Band with RSI
106 stars

This strategy plots Bollinger Bands on the price chart using the middle band as a simple moving average and standard deviation bands. It signals long entries when the close price crosses below the middle band combined with Aroon up trending above 90 and within

Strategy v4 Moving averagesVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger bands And Aroon Scalping
99 stars

This indicator plots the Pretty Good Oscillator in a separate pane. It subtracts a simple moving average of the selected source from the source and divides the difference by an exponential average of true range. A period input sets both the moving-average leng

Indicator v6 Oscillators & momentumVolatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Pretty Good Oscillator (PGO)
106 stars

This strategy combines Stochastic RSI and a normalized Bollinger Bands calculation into a composite oscillator named MIX, plotted in a separate pane. Long positions are entered when the MIX line crosses above the oversold threshold of 20. The strategy utilizes

Strategy v4 Oscillators & momentumVolatility & bands Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands and RSI Mix with DCA

Price Channel (PC)

by mihakralj
99 stars

This indicator plots a price channel on the price chart. It finds the highest high and lowest low over a chosen lookback, then draws the upper band, the lower band, and a middle line at their midpoint, with a translucent fill between the outer bands. The lengt

Indicator v6 Support & resistanceVolatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Price Channel (PC)
106 stars

This strategy calculates a simple moving average basis flanked by three upper and three lower volatility bands scaled using Fibonacci ratios of the Average True Range. It enters long when the bar intersects a chosen target band and enters short when price touc

Strategy v4 Volatility & bandsMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands Fibonacci Ratios

Bollinger Bands Filter

by hasnocool
106 stars

This strategy plots Bollinger-style bands on the price chart from a simple moving average and a standard-deviation offset. It treats a close above the upper band as a long condition and a close below the lower band as a short condition, then colors the basis b

Strategy v4 Volatility & bandsBreakout
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands Filter

PineForge Archive Map Presence

by pineforge-4pass
1 stars

This strategy generates trading signals on the price chart using a regime-based RSI indicator. It selects an RSI threshold from an internal map based on the chosen regime or falls back to a configurable value. Long entries occur on RSI crossover above the thre

Strategy v6 TrendOscillators & momentum
Updated 6 days ago · Apache-2.0 GitHub repository of PineForge Archive Map Presence
106 stars

This strategy plots customizable Bollinger Bands directly on the price chart using eleven selectable moving average types, including VAR, DEMA, ZLEMA, Hull, and Tillson T3. It generates long entry stop orders when price crosses above the lower band and short e

Strategy v4 Volatility & bandsMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands Strategy (MA type)

This strategy plots Bollinger Bands on the price chart using an EMA or SMA basis and a matching standard-deviation calculation. It enters long when price crosses back above the lower band and short when price crosses back below the upper band. An optional Intr

Strategy v4 Volatility & bandsMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands Strategy with Intraday Intensity Index

This strategy plots Bollinger Bands and an exponential moving average on the price chart. It enters long when price touches the lower band above the EMA and a bearish candle is followed by a bullish candle, and enters short on the mirrored upper-band setup. Ex

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands Trending Reverse Strategy
3 stars

Pro In Out Divergence is a lower-pane oscillator indicator that combines normalized stochastic layers, triple exponential moving averages (TEMA), and DMI/ADX state calculations. It tracks momentum shifts and inflow or outflow states relative to zero lines and

Indicator v5 Oscillators & momentumMoving averages
Updated 5 months ago · None stated GitHub repository of Pro In Out Divergence

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