Pine Library · 4,643 open-source scripts

Free Pine Script v5 Scripts (page 60)

Scripts written for Pine Script version 5. They still run in TradingView as they are, and the Pine Editor can convert them to version 6.

Pine scripts4,643
Code shown here2,378open licence
Updated in a year2,687
No repaint flag4,051

Pine Script v5: Indicators, Strategies and Libraries

Simpleton Stepfun

by eltonaguiar
4 stars

This indicator plots signals on the price chart for crypto trading. It computes RSI-2, MACD crossover, Bollinger Band squeeze, volume spikes, Triple EMA alignment and Ichimoku Cloud to produce confluence signals. Each indicator can be toggled with adjustable w

Indicator v5 Oscillators & momentumVolatility & bands
Updated 2 days ago · None stated GitHub repository of Simpleton Stepfun

MACD + ATR13

by jash-git
3 stars

This indicator plots a standard MACD oscillator alongside an average true range line in a separate pane. It calculates the MACD line, signal line, and histogram using customizable fast, slow, and smoothing periods. It also computes a 13-period ATR plotted with

Indicator v5 Oscillators & momentumVolatility & bands
Updated 4 weeks ago · None stated GitHub repository of MACD + ATR13

CSW Indicators

by g-moe
3 stars

CSW Indicators combines eight technical analysis tools into a single overlay plotted directly on the main price chart. It features automated power support and resistance levels derived from pivot points, distance perimeter bands, a linear regression channel, R

Indicator v5 TrendSupport & resistance Repaints
Updated 5 months ago · None stated GitHub repository of CSW Indicators

Estimations-10min

by IAMATOMIC001
3 stars

This overlay strategy estimates trend with a selectable TEMA, Hull, or ALMA basis and optional higher-timeframe or Heikin Ashi sources. It plots a regression estimator with ATR near and far boundaries, can color bars by trend, and can show order blocks. Entrie

Strategy v5 TrendMoving averages Repaints
Updated 12 months ago · None stated GitHub repository of Estimations-10min

This indicator estimates realized volatility in a separate pane. It computes log returns from the current price and the previous daily close, then annualizes the standard deviation over short, medium, and long lookbacks. It also plots a quicker estimate that m

Indicator v5 Volatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Volatility Oscillator with Quick Estimate and Forecast

Calculates a Zero Lag Exponential Moving Average (ZLEMA) combined with Average True Range volatility bands to determine market trends. It plots the ZLEMA basis line, volatility bands, trend reversal labels, and entry signals directly on the price chart. Additi

Indicator v5 TrendMoving averages Repaints
Updated 6 weeks ago · None stated GitHub repository of Zero Lag Trend Signals (MTF) [AlgoAlpha]

[SMT] B&S Renko

by wynnforthework
2 stars

This strategy plots Renko open prices on the price chart based on the ATR length setting. It generates buy signals when Renko open crosses under close and sell signals when open crosses over close. The main setting adjusts ATR length used for Renko brick calcu

Strategy v5 TrendScalping
Updated 1 year ago · None stated GitHub repository of [SMT] B&S Renko

ZenLibrary

by Web3Degenerate
2 stars

ZenLibrary is a custom Pine Script utility library providing standard helper functions for trading scripts. It includes calculations for quote currency decimal precision, market pip sizes, decimal truncation, pip conversions, percentage change over lookback pe

Library v5
Updated 2 years ago · None stated GitHub repository of ZenLibrary
1 stars

A strategy that builds on the JAT+BSM family: an AlphaTrend style core with MACD, three consolidation layers with volume profile, candlestick and macro pattern drawings, and a kinematic and Bayesian forecast with a feedback learning rate. Inputs include a stra

Strategy v5 TrendOscillators & momentum
Updated 2 days ago · None stated GitHub repository of JAT+BSM Pro v15 Unified

Crypto Scanner Climax

by rubbermetal
1 stars

A dashboard indicator in a separate pane that reads many measurements for the chart symbol across several timeframes. Columns cover prices, volume, delta and VWAP, oscillators such as RSI, stochastic, CCI and MFI, a quad rotation stochastic status, trend measu

Indicator v5 Screeners & dashboardsOscillators & momentum
Updated 4 months ago · MPL-2.0 GitHub repository of Crypto Scanner Climax
1 stars

This strategy compares a 9-period EMA with a 21-period EMA of the close and uses their difference as a spread. It opens a long when the spread crosses above zero and a short when it crosses below zero, reversing the position through opposite entries. The EMA l

Strategy v5 TrendMoving averages
Updated 4 months ago · MIT GitHub repository of Generic Type Annotation Tuple

Gann Pivot HL 2024 V2

by mikeyhu70
1 stars

This indicator marks pivot swing highs and lows on the price chart and lists their dates in separate tables for highs and lows, with an extra table for seasonal dates. Left and right bar counts set pivot detection, and settings control how many swings are kept

Indicator v5 Support & resistance
Updated 6 months ago · None stated GitHub repository of Gann Pivot HL 2024 V2
1 stars

This strategy overlays price and combines SuperTrend, ADX, OBV, MACD, directional movement, EMA, and a volatility filter to decide long and short entries. Each filter can be switched on or off, and trading starts only after a chosen date. It can close when ena

Strategy v5 TrendOscillators & momentum
Updated 7 months ago · None stated GitHub repository of Percentile_SuperTrend_OBV&DI&EMA
1 stars

A Pine v5 strategy that fades price at VWAP standard deviation bands on the price chart. A long needs the low to reach the lower band with an up candle, and a short needs the high to reach the upper band with a down candle. An optional filter counts how many r

Strategy v5 Mean reversionVolume
Updated 8 months ago · None stated GitHub repository of VWapperAlgo VWAP Bands Strategy

Momentum Breakout

by knectardev
1 stars

This Pine Script strategy detects momentum breakouts on price charts by combining trend momentum signals with a volume filter. It enters trades when price breaks above resistance with volume 1.5 times average, reducing false signals. No specific stop loss or t

Strategy v5 Oscillators & momentumBreakout
Updated 9 months ago · None stated GitHub repository of Momentum Breakout

V5 Combination by YZZ

by webcrack4
1 stars

This indicator combines multiple script features into a single overlay on the main price chart. It calculates a modified MACD line and signal oscillator with configurable modes including traditional, histogram-based, leader, and source-based variations. The os

Indicator v5 TrendOscillators & momentum
Updated 9 months ago · None stated GitHub repository of V5 Combination by YZZ
1 stars

An indicator that fits a linear regression line over a chosen number of bars and draws upper and lower deviation channels around it on the price chart. Length, source and the deviation multipliers are adjustable, and lines can be extended left or right. It can

Indicator v5 TrendSupport & resistance Repaints
Updated 1 year ago · None stated GitHub repository of Linear Regression Channel

Relative Sharpe Ratio

by JohnsonHsiao
1 stars

The Relative Sharpe Ratio indicator calculates risk-adjusted return measures over a user-defined lookback window and plots them in a separate pane. It calculates single-period simple returns, sums them over the period, and divides the sum by the return varianc

Indicator v5 Volatility & bandsOscillators & momentum
Updated 3 years ago · None stated GitHub repository of Relative Sharpe Ratio
330 stars

This strategy plots MACD line, signal line, Bollinger Bands, and RSI on the price chart. It signals long entries on MACD crossover above signal with RSI below 50 and price below BB basis, plus optional DMI filter. Short entries are available but disabled by de

Strategy v5 Oscillators & momentumVolatility & bands
Updated 2 months ago · None stated GitHub repository of MACD + BB + RSI [Alorse]

Function: Decision Tree

by ricardosantos79
261 stars

Function: Decision Tree is a technical script that demonstrates probabilistic path selection through a decision tree algorithm using a custom pseudo-random number generator. It initializes weighted node arrays and simulates traversal paths down the tree based

Indicator v5 AI / machine learning
Updated 4 years ago · None stated GitHub repository of Function: Decision Tree

Lux Trailing

by dearvn
257 stars

Plots kernel-smoothed price zones on the price chart using a Rational Quadratic kernel from an imported library. It builds an inner and an outer high-low zone from 15-minute highs and lows, plus a smoothed close and a midline, and marks bullish or bearish bars

Indicator v5 Support & resistanceVolatility & bands Repaints
Updated 7 weeks ago · None stated GitHub repository of Lux Trailing
106 stars

This indicator plots an adaptive MACD in a separate pane. It builds the MACD from price changes using fast and slow smoothing factors, then scales the recursion with an R-squared term from the correlation of close and bar index over the R2 period. An EMA of th

Indicator v5 Oscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Adaptive MACD [LuxAlgo]

syminfo.* Built-ins

by be-thomas
65 stars

This educational script renders an informational table directly on the price chart to display metadata about the current trading symbol. It retrieves and formats various built-in variables, including base currency, quote currency, symbol description, minimum t

Indicator v5 Screeners & dashboards
Updated 6 days ago · GPL-3.0 GitHub repository of syminfo.* Built-ins
55 stars

This indicator draws dynamic support and resistance trendlines on the price chart. It finds pivot highs and pivot lows with a fixed 15-bar lookback on each side, keeps the last two of each, and on the latest bar connects those highs with a red line and those l

Indicator v5 Support & resistanceTrend
Updated 6 months ago · Apache-2.0 GitHub repository of Auto Dynamic Trendlines

ADR levels

by TamaraKGreen
47 stars

This indicator plots average daily range levels on the price chart, together with optional standard-deviation and Fibonacci levels scaled from that range. Users set the lookback in days, a scale factor, and the visibility, color, and line style of the ADR line

Indicator v5 Support & resistanceVolatility & bands
Updated 8 weeks ago · None stated GitHub repository of ADR levels

Chop Zone

by TWODS-CAPITAL
37 stars

The Chop Zone indicator calculates and visually represents the trend direction and angle of a 34-period Exponential Moving Average (EMA). By measuring normalized EMA slope changes relative to the highest high and lowest low of the recent 30 bars, it maps the a

Indicator v5 TrendVolatility & bands
Updated 3 years ago · MIT GitHub repository of Chop Zone

Diverlong F002

by ruckard
13 stars

Diverlong F002 is a price-chart strategy that enters on Squeeze Momentum divergences and exits on Curie closing moving-average lines. A short is taken when a light-green to dark-green squeeze section is smaller while price is higher; a long is taken on the opp

Strategy v5 DivergenceOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Diverlong F002

RSI 3

by suyons
7 stars

This indicator calculates three Relative Strength Index (RSI) oscillators with distinct length settings, defaulting to 14, 28, and 56 periods. It renders the three RSI curves stacked vertically in a separate pane using numerical offsets to prevent line overlap

Indicator v5 Oscillators & momentum
Updated 4 months ago · None stated GitHub repository of RSI 3

3-Candle Time Pattern

by alboogycOdR
6 stars

This indicator detects three-candle time patterns on the price chart, tracking range, manipulation, and distribution phases based on Smart Money Concepts. It establishes high and low boundaries from the opening candle and identifies boundary rejections during

Indicator v5 SMC / ICT / price actionCandlestick patterns
Updated 7 months ago · None stated GitHub repository of 3-Candle Time Pattern
4 stars

The Simpleton STEPFUN Strategy combines signals from multiple technical indicators including RSI-2, MACD crossover, Bollinger Band squeeze, volume spikes, triple EMA, and Ichimoku cloud. It generates buy signals when the weighted ensemble meets or exceeds the

Strategy v5 Oscillators & momentumVolatility & bands
Updated 2 days ago · None stated GitHub repository of Simpleton STEPFUN Strategy

MACD + ATR13

by jash-git
3 stars

This indicator plots a customized Moving Average Convergence Divergence oscillator combined with an Average True Range line in a separate pane. It calculates fast and slow exponential moving averages alongside a simple moving average signal line, highlighting

Indicator v5 Oscillators & momentumVolatility & bands
Updated 4 weeks ago · None stated GitHub repository of MACD + ATR13
3 stars

This indicator plots horizontal lines representing previous highs, lows, and closes from daily, weekly, monthly, quarterly, and yearly periods on the price chart. These levels serve as potential support and resistance for confluence analysis. Users can toggle

Indicator v5 Support & resistanceScreeners & dashboards
Updated 5 months ago · None stated GitHub repository of CSW Institutional Levels

GainzAlgo V2 [Alpha]

by IAMATOMIC001
3 stars

This indicator detects buy and sell signals on the price chart by combining engulfing candlestick patterns, body-to-range stability ratios, RSI boundaries, and price momentum over ten bars. Confirmed signals trigger visual buy and sell labels directly on candl

Indicator v5 Candlestick patternsOscillators & momentum
Updated 12 months ago · None stated GitHub repository of GainzAlgo V2 [Alpha]

This indicator calculates a multi-period momentum oscillator plotted alongside an Average True Range baseline. It measures momentum across five configurable lookback lengths, weighting each value proportionally by its length so longer horizons exert greater in

Indicator v5 Oscillators & momentumVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Weighted Multi-Resolution Momentum with Volatility

EzAlgo

by TamTH-Dev
2 stars

EzAlgo is a multi-purpose trading overlay that combines several technical analysis tools into one system. It calculates Ichimoku Cloud components, dynamic support and resistance zones, reversal bands, trend ribbons, and custom buy or sell signals adjusted by s

Indicator v5 TrendSupport & resistance
Updated 6 weeks ago · None stated GitHub repository of EzAlgo

Banmuxia MACD Divergence

by wynnforthework
2 stars

This strategy calculates a customizable MACD oscillator and histogram using either simple or exponential moving averages. It identifies pivot highs and pivot lows on the MACD histogram to detect momentum divergences against price action. Historical pivot point

Strategy v5 Oscillators & momentumDivergence
Updated 1 year ago · None stated GitHub repository of Banmuxia MACD Divergence

2.Draw - 11.Labels

by Web3Degenerate
2 stars

This overlay indicator draws a single price label on the chart at the current bar's index and low. The label lists the bar's close, open, high, and low. Its color is green when the close is above the open and red otherwise, then switches to purple when the low

Indicator v5
Updated 2 years ago · None stated GitHub repository of 2.Draw - 11.Labels
1 stars

An indicator that builds a feature matrix from price z-score, RSI, ATR ratio and momentum over a lookback window, weights the four features, smooths them with a covariance based decomposition, and classifies a regime. It then draws a forecast line a chosen num

Indicator v5 AI / machine learningVolatility & bands
Updated 2 days ago · None stated GitHub repository of JINXAI Tensor Forecast

Trade Worthy

by rubbermetal
1 stars

Trade Worthy is a large multi-tool overlay indicator written in Pine v5. It shows a configurable dashboard of indicator readings, volume information and stats, with Pi moving averages on by default. Many other layers are off by default and can be switched on,

Indicator v5 Screeners & dashboardsMoving averages
Updated 4 months ago · MPL-2.0 GitHub repository of Trade Worthy

Pivot Trend RMA

by Snappni
1 stars

This strategy calculates a 10-period rolling moving average (RMA) alongside short-term pivot highs and pivot lows to identify trend alignment. It plots the RMA line directly on the price chart. Long entries trigger when price crosses the RMA while the RMA is r

Strategy v5 TrendMoving averages
Updated 4 months ago · MIT GitHub repository of Pivot Trend RMA

Goertzel Algorithm

by mikeyhu70
1 stars

This indicator applies the Goertzel algorithm, a signal-processing method for measuring a single frequency component, to price in a separate pane. A period length and a measurement block length set the cycle to test, and a training percentage and shift setting

Indicator v5 AI / machine learning
Updated 6 months ago · None stated GitHub repository of Goertzel Algorithm
1 stars

This overlay strategy combines SuperTrend, ADX, OBV, MACD, directional movement, EMA, and a volatility filter to open long or short trades sized as a percent of equity. Each filter and each side can be switched off. Users set EMA lengths, DI length, volatility

Strategy v5 TrendOscillators & momentum
Updated 7 months ago · None stated GitHub repository of Percentile_SuperTrend_OBV&DI&EMA

Momentum Breakout

by knectardev
1 stars

Momentum Breakout is an overlay strategy that identifies trading opportunities using Bollinger Bands breakout logic. It enters trades when price breaks out of the volatility bands without applying additional volume filtering. Risk management is handled through

Strategy v5 BreakoutVolatility & bands
Updated 9 months ago · None stated GitHub repository of Momentum Breakout

V5 Combination by YZZ

by webcrack4
1 stars

This indicator combines multiple technical tools into a single price chart overlay, designed to optimize space and indicator limits. It features an overlay MACD visualizer with selectable calculation methods (Traditional, AS Histogram, Leader, or Source), cust

Indicator v5 TrendOscillators & momentum
Updated 9 months ago · None stated GitHub repository of V5 Combination by YZZ

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