Pine Library · 4,643 open-source scripts

Free Pine Script v5 Scripts (page 29)

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

[CBB] Trade Windows

by codybbrown
2 stars

This indicator shades the price-chart background during a user-defined trading session. It reads the session string, defaulting to midnight through 13:00 on all seven weekdays, and evaluates it in the America/New_York time zone against the chart's current time

Indicator v5 Sessions & time
Updated 3 years ago · None stated GitHub repository of [CBB] Trade Windows

Three Brothers Strategy

by sassiz-root
2 stars

This strategy looks for three prior bars moving the same way with successively smaller bodies, followed by a current bar that closes the other way. It enters long when those prior bars are bearish and the current bar is bullish. A short entry is present only a

Strategy v5 Candlestick patterns Repaints
Updated 3 years ago · MIT GitHub repository of Three Brothers Strategy

RSI Scalping Machine [UT]

by theupslidedown
2 stars

This overlay indicator combines RSI, an RSI-VWAP length, RMI, ADX, volume, a range filter, and a cloud on the price chart. Settings change the ADX type, length, and threshold, the volume multiplier and average length, RSI source and lengths, the range-filter s

Indicator v5 Oscillators & momentumVolume
Updated 3 years ago · None stated GitHub repository of RSI Scalping Machine [UT]

This strategy plots SuperTrend lines on the price chart using ATR period and multiplier settings to identify trend direction and generate buy and sell signals. It integrates with Algomojo automation to automatically execute trades via API calls to supported br

Strategy v5 TrendVolatility & bands
Updated 4 years ago · MIT GitHub repository of SuperTrend Algomojo Trading Strategy with Target/Stoploss

Level Search

by DaniilOkrug
2 stars

This Pine Script strategy identifies and plots horizontal support levels by searching for price clusters across historical price lows. It scans a configurable number of past bars to group nearby low prices within a user-defined tick deviation. When a price lev

Strategy v5 Support & resistance Repaints
Updated 4 years ago · MIT GitHub repository of Level Search
1 stars

An overlay that sketches a same-day iron condor on the S&P 500 index or its ETF and mini equivalents, detecting which instrument is loaded. It tracks an opening observation window, then at a set build time projects short strikes a chosen percentage out of the

Indicator v5 Sessions & timeSupport & resistance
Updated 2 days ago · None stated GitHub repository of ZeroDTE Iron Condor v1

Stoch Price Envelope

by teshmi9z-beep
1 stars

An overlay that converts a long-period stochastic reading back into price levels. Using the highest high and lowest low over a lookback window of 200 bars by default, it plots a ceiling at the high stochastic level, a floor at the low level, a midpoint, and a

Indicator v5 Oscillators & momentumSupport & resistance
Updated 2 days ago · MIT GitHub repository of Stoch Price Envelope
1 stars

An overlay that computes three simple moving averages, by default lengths 30, 50 and 100, but draws only the highest and the lowest of them on each bar. The two lines form a band that can be filled with a color, so the band stays clean even when the averages c

Indicator v5 Moving averagesTrend
Updated 5 days ago · None stated GitHub repository of Moving Average High-Low Range

My Notes

by cckmchiu-gapps
1 stars

The My Notes indicator displays selectable trading notes on the price chart. Users choose from multiple note sets via dropdown input, covering topics like technical points, trading strategies, market states, and Hong Kong stock analysis. Notes appear as text l

Indicator v5 Screeners & dashboardsSupport & resistance
Updated 8 days ago · None stated GitHub repository of My Notes

RSI Cross

by quantxaashish
1 stars

This Pine Script v5 indicator calculates the Relative Strength Index using a default length of 14. It plots the RSI value in a separate pane below the price chart. Long signals trigger when the RSI line crosses above the oversold level of 30, and short signals

Indicator v5 Oscillators & momentum
Updated 2 weeks ago · MIT GitHub repository of RSI Cross

An overlay indicator limited to the one-minute chart that records the high and low of an opening range at a set market open time. It draws high, low and average lines plus dotted entry levels beyond the range, extending to the session end. A daily flag is kept

Indicator v5 Sessions & timeSupport & resistance
Updated 2 weeks ago · None stated GitHub repository of DAY-5MIN-L&H v6 Valid Trend Alert
1 stars

A long-only research strategy that enters when momentum, the close divided by the close several bars back minus one, crosses from zero or below to above zero. It exits when momentum turns negative or an ATR-based trailing stop is hit. Signals are decided on co

Strategy v5 TrendVolatility & bands
Updated 3 weeks ago · None stated GitHub repository of Momentum ATR Next-Bar Open
1 stars

A long-only strategy template meant to send webhook alerts to an external bot. It enters on a fast and slow EMA cross with a volume surge while RSI is below the overbought level, or on an oversold RSI at the lower Bollinger Band with a volume surge. Each entry

Strategy v5 Oscillators & momentumMean reversion
Updated 6 weeks ago · None stated GitHub repository of Algo Bot Signal Generator

Order Flow Delta

by mrme000m
1 stars

A Pine v5 indicator in a separate pane that estimates buying and selling pressure from each candle's position between its low and high, weighted by volume. It plots the per-bar delta, a moving average of delta, cumulative delta and buy and sell percentages. Ex

Indicator v5 VolumeDivergence
Updated 7 weeks ago · None stated GitHub repository of Order Flow Delta

CTLV v2 Liquidity Void Map

by AssetWhisper
1 stars

An overlay indicator that maps price voids as boxes on the chart: three-candle fair value gaps and opening gaps, mostly from a higher timeframe such as four hours, with an option to include chart-timeframe voids. It uses closed higher-timeframe candles, tracks

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 7 weeks ago · MPL-2.0 GitHub repository of CTLV v2 Liquidity Void Map
1 stars

A price-chart indicator that reads market structure from confirmed swing highs and lows over an adjustable period. A break of the last swing by candle body or wick sets the trend direction, and a change of character is marked when the direction flips. It colou

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 2 months ago · None stated GitHub repository of Smart Money Trades Pro

Mxwll Suite

by BrandonFreire
1 stars

A smart money concepts toolkit drawn on the price chart. It marks internal and external market structure with break of structure and change of character labels at selectable sensitivities, swing order blocks, higher-high and lower-low labels, and areas of inte

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 2 months ago · None stated GitHub repository of Mxwll Suite

An overlay indicator that marks confirmed swing highs and lows with arrows and tracks market structure. A bullish or bearish trend, and a change of character, needs at least four alternating confirmed swings, so one contradicting swing does not flip the trend.

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 2 months ago · None stated GitHub repository of Market Structure Change of Character

GrimmHA Strategy

by GreyssonEnterprises
1 stars

This strategy combines Heikin Ashi candlestick pattern recognition with Smoothed Moving Average (SMMA) trend filtering to generate long and short entries. It detects doji candles, three-line strikes, and engulfing patterns aligned with SMMA trends. Risk manage

Strategy v5 TrendMoving averages
Updated 3 months ago · MIT GitHub repository of GrimmHA Strategy

A/D Context v20.10

by VVASILEVSS
1 stars

A Pine v5 indicator that draws in its own pane and measures accumulation and distribution flow with Williams or Chaikin A/D, a smoothing EMA, Chaikin Money Flow and ATR. It compares price pivots with flow pivots to flag regular or hidden divergences, optionall

Indicator v5 DivergenceVolume
Updated 3 months ago · None stated GitHub repository of A/D Context v20.10

MTF RSI Management

by iyoshikawa
1 stars

An overlay indicator built around a fast and a slow smoothed RSI, a double-smoothed stochastic, an EMA trend line and an ADX filter, combined with a volume filter to grade setups from B to A+. Presets adapt settings for crude oil, Nasdaq, S&P 500 and Dow futur

Indicator v5 Oscillators & momentumTrend Repaints
Updated 5 months ago · None stated GitHub repository of MTF RSI Management

Talons FVG Strategy

by muammeryldrm42
1 stars

A strategy that detects three-candle fair value gaps larger than a set ATR multiple and draws them as boxes on the price chart. It then waits for price to retrace to the gap midpoint and enters with a limit order, optionally only in the direction of a 200 EMA

Strategy v5 SMC / ICT / price actionSupport & resistance
Updated 5 months ago · None stated GitHub repository of Talons FVG Strategy

QUANT-OMEGA Strategy

by princeleuel-code
1 stars

A strategy version of the QUANT-OMEGA regime and ensemble signal. It classifies the market with ADX and ATR, scores trend, mean-reversion and breakout signals into a confidence value, and enters only above set thresholds. Stops and targets are ATR multiples. P

Strategy v5 TrendMean reversion
Updated 5 months ago · None stated GitHub repository of QUANT-OMEGA Strategy

ORB

by onlyspx
1 stars

This indicator marks the opening range of the trading session on the price chart. The range period can be 5, 15, 30 or 60 minutes, or a custom session and time zone for non-US markets. It draws the range high and low, an optional shaded box and midpoint, plus

Indicator v5 Sessions & timeBreakout
Updated 6 months ago · None stated GitHub repository of ORB

EMA Indicator

by Sandesh30-cloud
1 stars

Plots 50-period and 200-period Exponential Moving Averages directly on the price chart. The fast 50 EMA is drawn in orange, while the slow 200 EMA is drawn in blue to provide a simple visual reference for baseline trend analysis. The indicator has no configura

Indicator v5 TrendMoving averages
Updated 6 months ago · None stated GitHub repository of EMA Indicator

ICT Unicorn Model

by cavaldos
1 stars

Looks for the ICT unicorn pattern, where a breaker block overlaps a fair value gap, using zigzag swings with a default length of 10. Bullish and bearish patterns can be enabled separately, or combined so both appear together. For each setup it draws risk and r

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 6 months ago · None stated GitHub repository of ICT Unicorn Model

Estimates the Hurst exponent with detrended fluctuation analysis on log returns, indicating whether recent price behaviour leans toward trending or mean reverting around a 0.5 mid line. Inputs set the sample size, base and maximum scales, an optional smoothing

Indicator v5 TrendMean reversion
Updated 6 months ago · None stated GitHub repository of Hurst Exponent - Detrended Fluctuation Analysis

Supply & Demand Zones

by nexobanks-prep
1 stars

A Pine v5 indicator that draws supply and demand boxes on the price chart. A candle counts as an impulse when its body exceeds a multiple of ATR, and as a base candle when its body is small. Impulse, base, impulse sequences create reversal zones (rally-base-dr

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 7 months ago · None stated GitHub repository of Supply & Demand Zones
1 stars

This strategy builds the high and low of a configurable Asian session and locks that range when the session ends. During the London window it enters long when price closes above the range high plus a pip buffer, or short when it closes below the range low minu

Strategy v5 BreakoutSessions & time Repaints
Updated 8 months ago · None stated GitHub repository of London Breakout - Session Strategy

Trend-Filtered Reversal

by caizongxun
1 stars

A separate-pane indicator for counter-trend reversal setups that are filtered by a baseline EMA trend. A bearish setup needs price at a wide upper Bollinger Band, high volume or an overbought RSI, and a rejection wick; the bullish setup mirrors this. In a stro

Indicator v5 Mean reversionVolatility & bands
Updated 8 months ago · MIT GitHub repository of Trend-Filtered Reversal

ML Decision Tree Classifier

by haydarkadioglu
1 stars

The ML Decision Tree Classifier uses rule-based decision tree logic to evaluate trend, momentum, volume, and MACD indicators for market direction classification. It calculates exponential moving averages, relative strength index values, volume relative to a mo

Indicator v5 AI / machine learningTrend
Updated 8 months ago · None stated GitHub repository of ML Decision Tree Classifier

ARC VMAlgo

by Tradehook-org
1 stars

ARC VMAlgo is an indicator that plots a histogram in a separate pane. It calculates volatility bands using a Bollinger-style SMA and standard deviation. It computes a MACD-style momentum oscillator with fast and slow EMAs. It normalizes distance to bands using

Indicator v5 Oscillators & momentumMoving averages
Updated 8 months ago · None stated GitHub repository of ARC VMAlgo

MNQ Gamma (0DTE)

by Juice-zhi
1 stars

A price-chart overlay that draws a static set of options gamma levels for MNQ (Micro Nasdaq-100 futures, scaled from QQQ options) expiring in the same day. The center line and the one and two standard deviation bands are hardcoded numbers from a snapshot dated

Indicator v5 Support & resistance
Updated 8 months ago · None stated GitHub repository of MNQ Gamma (0DTE)

Daily ATR Levels

by sbtnc
1 stars

Plots horizontal levels above and below the daily open based on the Average True Range, drawn on the price chart. The ATR length defaults to 20, and the reference can be yesterday's ATR or today's. Levels change colour once price reaches or passes them. Option

Indicator v5 Volatility & bandsSupport & resistance
Updated 9 months ago · MPL-2.0 GitHub repository of Daily ATR Levels
1 stars

This indicator evaluates Relative Strength Index (RSI), Moving Average Convergence Divergence (MACD), and Stochastic oscillators across four customizable timeframes. It aggregates bullish and bearish conditions into a confluence score to identify aligned marke

Indicator v5 Oscillators & momentumScreeners & dashboards
Updated 9 months ago · MIT GitHub repository of MTF Confluence Scanner

This overlay indicator draws trendlines on the price chart and marks breakouts with optional targets. It builds a slope from successive changes in a wick or body source over a user-set period, then extends the line by a selected multiple of the bar interval. P

Indicator v5 TrendVolatility & bands
Updated 9 months ago · None stated GitHub repository of Trendline Breakouts With Targets [ Chartprime ]

Crypto Trading Bot Pro

by KirstonKK
1 stars

A chart-overlay indicator that combines RSI, a fast and slow EMA cross, Bollinger Bands, volume spikes, MACD and stochastic into alert conditions. Individual alert groups can be switched on or off, and a weighted confidence score must reach a minimum before an

Indicator v5 Oscillators & momentumVolatility & bands
Updated 10 months ago · None stated GitHub repository of Crypto Trading Bot Pro
1 stars

A strategy built around the first regular-session candle of the US day in New York time, together with rejection levels collected from wicks formed during pre-market and after-hours sessions. Rejection levels within a tolerance percentage are grouped. Options

Strategy v5 BreakoutSessions & time
Updated 11 months ago · Custom licence GitHub repository of Breakout Strategy - Step by Step
1 stars

The Heikin Ashi Trend Follow Strategy calculates smoothed Heikin Ashi candle values from open, high, low and close prices and plots them on the price chart along with a trend EMA. It signals long entries when the Heikin Ashi close crosses above the trend EMA a

Strategy v5 TrendCandlestick patterns
Updated 11 months ago · None stated GitHub repository of Heikin Ashi Trend Follow Strategy
1 stars

This strategy looks for pullbacks to a 15-period EMA. A long needs price to touch or dip under the EMA, close back above it on a sufficiently large green candle, with the EMA above a 100-period EMA and a minimum pullback percentage. Shorts mirror this. Optiona

Strategy v5 TrendMoving averages
Updated 1 year ago · None stated GitHub repository of NakInvest EMA Pullback Strategy

Example Screener - 1

by NakliTechie
1 stars

Example Screener is a work-in-progress Pine Script v5 indicator meant to show a multi-symbol screener on the price chart. The file is a skeleton: the signal function returns a placeholder dash, and symbol lists, security calls, colors, helper functions, and ta

Indicator v5 Screeners & dashboards
Updated 1 year ago · MIT GitHub repository of Example Screener - 1
1 stars

This indicator calculates classic on-balance volume from the sign of the close change and volume, then rescales that cumulative series using the exponential averages of its highest and lowest values over a chosen length. It plots the normalized result in a sep

Indicator v5 Volume
Updated 1 year ago · None stated GitHub repository of On Balance Volume Scaled

SOLETH MTPI

by Mikelkulla
1 stars

This strategy detects relative performance between Solana and Ethereum using a liquidity-weighted supertrend (LWST) derived from fast and slow weighted moving averages of liquidity times close. It plots the Tsl2 trend line in a separate pane and issues buy sig

Strategy v5 TrendMoving averages
Updated 1 year ago · None stated GitHub repository of SOLETH MTPI

MACD Strategy

by pcjtse
1 stars

This strategy trades MACD line crossovers: it enters long when the MACD line crosses above the signal line and short when it crosses below. Each entry has an ATR-based stop loss and take profit set by separate multipliers. Fast, slow and signal lengths are adj

Strategy v5 Oscillators & momentum
Updated 1 year ago · None stated GitHub repository of MACD Strategy

Ehlers DMI

by munlit
1 stars

A separate-pane indicator that smooths price with a weighted average and a two-pole filter, then runs a directional movement calculation on the filtered series and plots one line coloured by its slope. The sign of the line sets a bullish or bearish state, whic

Indicator v5 TrendOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Ehlers DMI
1 stars

The script overlays a VWAP line on the price chart and identifies divergences between price close movements and VWAP movements. It computes VWAP using a customizable anchor period such as session or earnings, then checks for divergence over a lookback period c

Indicator v5 Moving averagesSupport & resistance
Updated 1 year ago · None stated GitHub repository of VWAP Divergence dobofulop

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