Pine Library · 4,643 open-source scripts

Free Pine Script v5 Scripts (page 83)

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

Level Theory

by g-moe
3 stars

This indicator draws extended horizontal lines on the price chart based on psychological rounding levels. It plots whole-number, half, and quarter increments of a configurable rounding value above and below a baseline price. Lines extend across the chart for s

Indicator v5 Support & resistance
Updated 5 months ago · None stated GitHub repository of Level Theory
2 stars

This indicator builds a separate-pane dashboard for the United States and five other countries. It requests open, high, low, and close for each region's currency, two-year yield, and equity index on the chart timeframe. Default symbols cover the dollar index,

Indicator v5 Screeners & dashboards
Updated 8 months ago · None stated GitHub repository of Equity, Bond, Currency Dashboard

This indicator tilts a simple moving average by the slope between two user-chosen price and time points and plots that average, its inverse, and a horizontal midpoint. It also mirrors the average around the midpoint and draws reconstructed candles reflected th

Indicator v5 Moving averagesSupport & resistance
Updated 7 weeks ago · None stated GitHub repository of Interactive Two Points MA Symmetry

KC Combo Bull v4.3

by nishpa800
1 stars

Overlays a Keltner Channel and an ATR supertrend on the price chart and marks candles where several built-in detectors agree on the same bar. The detectors cover pullback patterns, displacement, relative volume and high-volume bars, shown as lettered markers.

Indicator v5 Volatility & bandsTrend
Updated 2 months ago · None stated GitHub repository of KC Combo Bull v4.3

CC-Trend strategy 2

by hasnocool
106 stars

This strategy draws exponential moving averages and automatic Fibonacci retracement levels on the price chart. It opens a short when the previous close is below the upper Fibonacci extreme and the 21-period average is below the 55-period average. It closes the

Strategy v5 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of CC-Trend strategy 2

Price Channel Strategy

by TWODS-CAPITAL
37 stars

This strategy builds a price channel from the highest high and the lowest low over a user-set lookback. Once enough bars exist, it places a long stop order at the channel high and a short stop order at the channel low. The only setting changes the channel leng

Strategy v5 BreakoutSupport & resistance Repaints
Updated 3 years ago · MIT GitHub repository of Price Channel Strategy

Sergapi B002

by ruckard
13 stars

Sergapi B002 is a price-chart strategy that opens long trades when both an ATR signal and an EMA signal indicate buying, and short trades when both indicate selling. A strategy-type setting controls direction. Optional percentage or ATR stop losses, take profi

Strategy v5 Volatility & bandsMoving averages
Updated 1 year ago · None stated GitHub repository of Sergapi B002
6 stars

This overlay strategy builds independent timed session ranges and marks range, trendline, mean, VWAP, and high-low levels when those displays are enabled. It enters on range breakouts and exits with strategy exits, choosing among range, ATR, fixed-point, and r

Strategy v5 Sessions & timeBreakout
Updated 7 months ago · None stated GitHub repository of MSG Enhanced LEGO System Strategy

This overlay indicator draws rounded psychological price levels and optional PVSRA vector candle colors on the price chart. It plots quarter, half, and whole levels from a user-set rounding value, with separate color, line style, and width for each. Vector col

Indicator v5 Support & resistanceVolume
Updated 5 months ago · None stated GitHub repository of Level Theory + Vector Candles
2 stars

Everything Bitcoin [Kioseff Trading] is an overlay indicator that gathers on-chain Bitcoin network metrics and lower timeframe market data. It requests BCHAIN datasets via Quandl—including hash rate, mining difficulty, transaction volume, miner revenue, and wa

Indicator v5 Screeners & dashboardsSupport & resistance
Updated 8 months ago · None stated GitHub repository of Everything Bitcoin [Kioseff Trading]

KC Combo Bull v4.4

by nishpa800
1 stars

Overlays a Keltner Channel and an ATR supertrend on the price chart and marks candles where several built-in detectors agree on the same bar. The detectors cover pullback patterns, displacement, relative volume and high-volume bars, shown as lettered markers.

Indicator v5 Volatility & bandsTrend
Updated 2 months ago · None stated GitHub repository of KC Combo Bull v4.4

VolumeSpike

by ivansoft
1 stars

An indicator on the price chart that requests pivot lows and pivot highs from the one-hour timeframe and plots them as circles on the chart. For each new pivot it draws a dashed horizontal line back to the bar where the pivot formed. Despite the name it does n

Indicator v5 Support & resistance
Updated 1 year ago · None stated GitHub repository of VolumeSpike

This strategy generates trend-following entries using double-smoothed exponential moving averages, two Commodity Channel Index (CCI) periods, VWAP, and volume filters. Long entries require price to trade above smoothed EMAs and VWAP alongside high volume and b

Strategy v5 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of CCI & EMA strategy by Tradeswithashish

Price Oscillator

by TWODS-CAPITAL
37 stars

This indicator plots the percentage price oscillator in a separate pane. It divides the difference between a short moving average and a longer moving average by the longer average, then multiplies by 100. Users choose the source, both lengths, and whether the

Indicator v5 Oscillators & momentumMoving averages
Updated 3 years ago · MIT GitHub repository of Price Oscillator

Sergapium A004

by ruckard
13 stars

This strategy generates long and short signals using high and low closing moving average channels combined with ATR trend filtering. It plots directly on the price chart alongside an optional moving average ribbon. Positions enter when directional criteria ali

Strategy v5 TrendMoving averages
Updated 1 year ago · None stated GitHub repository of Sergapium A004
6 stars

This indicator identifies and plots custom time-based ranges on the price chart using GMT hours, monitoring for price breakouts within a configurable time window. When price breaks beyond the high or low of the range before expiration, it displays directional

Indicator v5 BreakoutSessions & time
Updated 7 months ago · None stated GitHub repository of MSG Enhanced Range Breakout System

LibraryStopwatch

by g-moe
3 stars

LibraryStopwatch is a Pine Script library designed to measure and benchmark script execution timing. It tracks the time elapsed since the script started running using built-in system time variables and estimates execution metrics across processed bars. The lib

Library v5
Updated 5 months ago · None stated GitHub repository of LibraryStopwatch

Exploring Unicode

by regalouisei
2 stars

Exploring Unicode is a Pine Script v5 indicator that demonstrates Unicode character support on the price chart. It labels high and low pivots with blocks of special symbols and emojis using the label.new function. The script also applies plotchar to mark bars

Indicator v5 VolumeSupport & resistance
Updated 8 months ago · None stated GitHub repository of Exploring Unicode

KC Combo Bull v4.5

by nishpa800
1 stars

Overlays a Keltner Channel and an ATR supertrend on the price chart and marks candles where several built-in detectors agree on the same bar. The detectors cover pullback patterns, displacement, relative volume and high-volume bars, shown as lettered markers.

Indicator v5 Volatility & bandsTrend
Updated 2 months ago · None stated GitHub repository of KC Combo Bull v4.5

VolumeSpikeTest

by ivansoft
1 stars

This indicator calculates and visualizes statistical volume thresholds across dynamic, time-based lookback windows. It converts multi-hour and multi-day periods into bar counts based on the active timeframe to compute rolling volume medians, simple moving aver

Indicator v5 Volume
Updated 1 year ago · None stated GitHub repository of VolumeSpikeTest
106 stars

This intraday strategy enters positions based on an alignment of trend, momentum, and oscillator indicators. It triggers long entries when the Commodity Channel Index is above a positive threshold, a fast Relative Strength Index crosses above a slow RSI, price

Strategy v5 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of CCI + EMA with RSI Cross Strategy

Rate Of Change

by TWODS-CAPITAL
37 stars

This indicator plots the rate of change of a chosen price source in a separate pane. It calculates the percentage difference between the current source value and the value a set number of bars earlier, then draws that series as a line together with a horizonta

Indicator v5 Oscillators & momentum
Updated 3 years ago · MIT GitHub repository of Rate Of Change

Sergdi A002

by ruckard
13 stars

Sergdi A002 is a directional strategy designed for crypto trading. It generates long entry signals when the 4-hour DI+ crosses over the 4-hour DI-, and short entry signals on a cross under. It features configurable risk management options, including fixed perc

Strategy v5 TrendOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Sergdi A002

BTC bar volume color

by eddiebelaval
7 stars

This overlay indicator collects Bitcoin spot volume from many named exchanges on the chart timeframe and adds those series after treating missing values as zero. It also begins gathering perpetual futures volume from several venues and sets a fixed length of 1

Indicator v5 Volume
Updated 3 months ago · None stated GitHub repository of BTC bar volume color

MSNR

by alboogycOdR
6 stars

This indicator identifies and plots key support and resistance structures directly on the price chart. It calculates A/V swing levels, price gaps, and Quasimodo levels using configurable pivot lengths and touch tolerances. Users can customize maximum level cou

Indicator v5 Support & resistanceSMC / ICT / price action
Updated 7 months ago · None stated GitHub repository of MSNR
3 stars

The Limitless Trading Indicator is an overlay tool that combines multi-timeframe Exponential Moving Averages (13 and 62 EMAs) with Relative Strength Index (RSI) crossovers. It evaluates trend direction on a user-selected higher timeframe and filters entry sign

Indicator v5 TrendOscillators & momentum Repaints
Updated 5 months ago · None stated GitHub repository of Limitless Trading Indicator

Extreme Trend Reversal Points identifies potential trend reversal zones directly on the price chart using moving averages and historical range percentiles. The indicator calculates price extremes relative to historical percentile history to detect overextended

Indicator v5 TrendMoving averages
Updated 8 months ago · None stated GitHub repository of Extreme Trend Reversal Points [HeWhoMustNotBeNamed]

KC Combo Bull v4.6

by nishpa800
1 stars

Overlays a Keltner Channel and an ATR supertrend on the price chart and marks candles where several built-in detectors agree on the same bar. The detectors cover pullback patterns, displacement, relative volume and high-volume bars, shown as lettered markers.

Indicator v5 Volatility & bandsTrend
Updated 2 months ago · None stated GitHub repository of KC Combo Bull v4.6
1 stars

A test indicator in a separate pane that sums the previous bar's volume over several rolling windows, from ten minutes up to one day, converted into bar counts from the chart timeframe. For some windows it also plots a percentile of the sum over a longer histo

Indicator v5 Volume
Updated 1 year ago · None stated GitHub repository of VolumeSpikeTestCumulative
106 stars

This Pine Script strategy uses the Commodity Channel Index (CCI) with a 20-period SMA to generate long-only signals. It plots the CCI line and dashed bands at 150 and -150 on the chart, filling the area between bands. Entries occur when CCI crosses above the l

Strategy v5 Oscillators & momentumSupport & resistance
Updated 2 years ago · GPL-3.0 GitHub repository of CCI High Performance Long Only

Relative Strength Index

by TWODS-CAPITAL
37 stars

This indicator calculates the Relative Strength Index from a chosen price source using a smoothed average of gains and losses, then plots it in a separate pane. It overlays a moving average of the RSI that can be SMA, EMA, SMMA, WMA, VWMA, or a Bollinger Band

Indicator v5 Oscillators & momentum
Updated 3 years ago · MIT GitHub repository of Relative Strength Index

Sergdi B003

by ruckard
13 stars

Sergdi B003 is a trend-following strategy designed to capture directional momentum using higher-timeframe Directional Movement Index signals. It opens long positions when the 4-hour DI+ crosses over the 4-hour DI-, and short positions when DI+ crosses under DI

Strategy v5 TrendOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Sergdi B003

MSNR [Optimized]

by alboogycOdR
6 stars

The MSNR Optimized indicator identifies key market structure support and resistance levels directly on the price chart, including Apex/Valley (A/V) swings, price gaps, and Quasimodo (QM) patterns. It uses configurable pivot lengths to detect structural pivots

Indicator v5 Support & resistanceSMC / ICT / price action
Updated 7 months ago · None stated GitHub repository of MSNR [Optimized]
3 stars

Lin Reg Simplified calculates a custom linear regression channel overlaid on the main price chart. It uses a combination of weighted moving average (WMA) and simple moving average (SMA) applied to HLC3 prices to compute the trend slope, middle line, and standa

Indicator v5 TrendSupport & resistance Repaints
Updated 5 months ago · None stated GitHub repository of Lin Reg Simplified
2 stars

The Fast Fourier Transform (FFT) Filter decomposes time series price data into frequency components using a discrete Fourier transform algorithm. It plots the frequency-domain power spectrum in a separate pane to highlight dominant market cycles. Users can dis

Indicator v5 TrendScreeners & dashboards
Updated 8 months ago · None stated GitHub repository of Fast Fourier Transform (FFT) Filter

KC Combo Bull v4.7

by nishpa800
1 stars

Overlays a Keltner Channel and an ATR supertrend on the price chart and marks candles where several built-in detectors agree on the same bar. The detectors cover pullback patterns, displacement, relative volume and high-volume bars, shown as lettered markers.

Indicator v5 Volatility & bandsTrend
Updated 2 months ago · None stated GitHub repository of KC Combo Bull v4.7

CCI Level Zone

by hasnocool
106 stars

This strategy plots the Commodity Channel Index of the OHLC4 price in a separate pane and uses fixed CCI zones to allow long or short trades. Longs open when the CCI is above its long level, optionally above an SMA of the CCI, and the long RSI crosses a buy le

Strategy v5 Oscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of CCI Level Zone

Relative Vigor Index

by TWODS-CAPITAL
37 stars

This indicator plots the Relative Vigor Index in a separate pane. It divides the length-period sum of symmetrically weighted close-minus-open values by the matching sum of high-minus-low ranges, then plots that line and a symmetrically weighted moving average

Indicator v5 Oscillators & momentum
Updated 3 years ago · MIT GitHub repository of Relative Vigor Index

Sergdi C003

by ruckard
13 stars

Sergdi C003 is a trading strategy that generates entry signals using directional movement index (DI+ and DI-) crossovers on a four-hour higher timeframe. It opens long positions on bullish DI crossovers and short positions on bearish crossovers. The script inc

Strategy v5 TrendVolatility & bands
Updated 1 year ago · None stated GitHub repository of Sergdi C003
7 stars

This indicator plots Smart Money Concepts and price action components directly on the price chart. It highlights bullish and bearish order blocks, multi-timeframe pivot points, market structure swings with key Fibonacci retracement levels (0.618 and 0.786), zo

Indicator v5 SMC / ICT / price actionSupport & resistance Repaints
Updated 3 months ago · None stated GitHub repository of Cryptokazancev Strategy Pack

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