Synced with GitHub · updated today

Free TradingView Pine Scripts

8,340 free, open-source indicators, strategies and libraries for TradingView. Copy any script and paste it into the Pine Editor to use it on your chart.

New scripts by RSS
8,340 scripts
1 stars

Pro Quant Desk (US) v1 is a comprehensive market analysis dashboard overlaid directly on the price chart for US equities. It calculates market regime metrics including macro risk gauges using SPY, QQQ, and equal-weight RSP breadth proxies, two-layer relative s

Indicator v5 Screeners & dashboardsTrend
Updated 4 months ago · None stated GitHub repository of Pro Quant Desk (US) v1
1 stars

This strategy combines trend, volatility, and multi-oscillator filters to generate directional trades. It calculates an Arnaud Legoux Moving Average (ALMA), Keltner Channels, Bollinger Band width, the Chande Momentum Oscillator (CMO), Money Flow Index (MFI), a

Strategy v5 TrendOscillators & momentum
Updated 4 months ago · MIT GitHub repository of Channel Momentum Suite
1 stars

This strategy combines two Supertrend indicators with different factors and periods to identify trend direction on the price chart. The primary Supertrend (factor 3, period 10) signals flips for entries, confirmed optionally by a faster Supertrend (factor 2, p

Strategy v5 TrendVolatility & bands
Updated 7 months ago · None stated GitHub repository of Supertrend - Dynamic Trend Follower
1 stars

VABOAlgo is a Pine Script v5 strategy that detects breakouts from a value area. It uses VWAP as a POC proxy and ATR to calculate VAH and VAL, requiring volume above average for confirmation and prior bar consolidation within the VA. Long entries trigger on bre

Strategy v5 BreakoutVolume
Updated 8 months ago · None stated GitHub repository of VABOAlgo (Value Area Breakout)

Net Position

by zhuzp98
1 stars

This indicator plots aggregated net long and short positions from selected crypto perpetual markets in a separate pane. It can show net longs, shorts, delta, and ratio as candles, a line, or columns, and it can switch to a position RSI view. Users choose Binan

Indicator v5 VolumeOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Net Position

Hello World

by fiji-solutions
1 stars

This indicator demonstrates how to retrieve fundamental financial metrics using Pine Script's financial data function. It requests quarterly accounts payable data for the current symbol, specified in Swiss Francs, and plots the resulting value series in a sepa

Indicator v5
Updated 2 years ago · None stated GitHub repository of Hello World

Z-Score BB

by amico1234
1 stars

Z-Score BB measures statistical deviation by comparing a short-term 22-bar sample mean against a longer-term population baseline. It computes the population standard deviation and standard error to derive absolute Z-score offset bands around the selected basel

Indicator v4 Volatility & bandsMean reversion
Updated 2 years ago · None stated GitHub repository of Z-Score BB

DMI Improve

by JohnsonHsiao
1 stars

This indicator improves the standard Directional Movement Index by adjusting plus and minus directional movement calculations with a weight factor and SMA adjustments for sensitivity. It calculates and plots improved DI+ and DI- lines in a separate pane. Setti

Indicator v5 TrendOscillators & momentum
Updated 3 years ago · None stated GitHub repository of DMI Improve

Volume Accumulation

by everget
948 stars

Volume Accumulation sums bar volume inside a chosen time bucket and plots the running total as columns in a separate pane. The bucket can be minutely, hourly, session, daily, monthly, quarterly, or yearly, and the total resets when that period changes. Columns

Indicator v6 Volume
Updated 10 days ago · GPL-3.0 GitHub repository of Volume Accumulation
575 stars

This overlay indicator marks ICT market structure shifts from a zigzag of swing highs and lows on the price chart. It can show bullish and bearish swings, structure-shift marks, and retracements, with optional zigzag lines and colored boxes. Zigzag length, hig

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 1 year ago · MPL-2.0 GitHub repository of ICT Market Structure Shift (MSS)
330 stars

RSI Multi Alerts [Alorse] is a multi-asset monitoring indicator that calculates the Relative Strength Index (RSI) for up to 40 individual user-selected symbols simultaneously. It overlays signal indicators on the chart to identify when any of the monitored ass

Indicator v5 Oscillators & momentumScreeners & dashboards
Updated 2 months ago · None stated GitHub repository of RSI Multi Alerts [Alorse]

Pricing Table

by namuan
318 stars

This indicator calculates theoretical options contract values and in-the-money probabilities using historical realized volatility across multiple standard deviations. It displays these metrics in a table overlay directly on the price chart. Users can adjust th

Indicator v4 Volatility & bandsScreeners & dashboards
Updated 2 months ago · MIT GitHub repository of Pricing Table

ABBV-tracker

by Allen1212
303 stars

ABBV-tracker visualizes historical purchase and sale transactions made by ARK Invest funds for AbbVie Inc. (ABBV) directly on the main price chart. It plots colored labels above or below candles on specific timestamps corresponding to trade dates, indicating b

Indicator v4
Updated 2 years ago · None stated GitHub repository of ABBV-tracker

CorrelationExtendsStatistics

by ricardosantos79
261 stars

This Pine Script v5 library exposes numerical helpers for correlation and special-function work and draws nothing on a chart. It returns machine-dependent floating-point constants, truncates a Chebyshev coefficient array to a requested accuracy, and evaluates

Library v5
Updated 4 years ago · None stated GitHub repository of CorrelationExtendsStatistics
257 stars

This indicator plots a 200-period weighted moving average (WMA) on the main chart and monitors price deviations across multiple timeframes. It retrieves daily, 15-minute, 5-minute, and 2-minute price data to track distance from the 200 WMA relative to key sess

Indicator v5 Moving averagesSessions & time Repaints
Updated 6 weeks ago · None stated GitHub repository of Donald SPX - Options Trading
219 stars

This indicator identifies High Of Low Price (HOLP) and Low Of High Price (LOHP) candlestick setups based on price extremes over a specified lookback period. A HOLP signal triggers when the current bar closes above the high of a recent session low, whereas a LO

Indicator v5 Candlestick patternsBreakout
Updated 1 year ago · None stated GitHub repository of Candlestick Patterns - HOLP-LOHP
219 stars

This indicator identifies local high pivot points on the price chart by comparing the high price of four bars ago against four preceding and four subsequent bars. When the middle bar is higher than all surrounding eight bars, it plots an H label on that peak b

Indicator v4 Support & resistance Repaints
Updated 5 years ago · None stated GitHub repository of 教學:尋找高低點1
218 stars

Comprehensive Volume Profile is an overlay indicator that calculates and plots volume distribution across specified time ranges such as daily sessions, weekly, monthly, or custom bar lengths. It identifies key structural price levels including the Point of Con

Indicator v6 VolumeSupport & resistance
Updated 3 months ago · None stated GitHub repository of Comprehensive Volume Profile
114 stars

ADX Strategy (original) is an overlay indicator that identifies trend-following trade signals using the Average Directional Index (ADX) combined with a Simple Moving Average filter. A long signal is generated when the ADX rises above a user-defined trend level

Indicator v4 TrendOscillators & momentum
Updated 1 year ago · None stated GitHub repository of ADX Strategy (original)
106 stars

This strategy places buy-stop and sell-stop orders around the opening-session high and low, offset by a user-defined pip gap, and only allows those orders during a separate trading session. It exits with a fixed or ATR-based stop loss and a matching take-profi

Strategy v5 Sessions & timeBreakout Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of 50 Pips A Day Strategy - Kaspricci
99 stars

This indicator calculates the statistical autocorrelation coefficient of an input series over a user-defined lookback window at a specified lag. It tracks values using an internal circular buffer, computes sample mean, variance, and autocovariance, and normali

Indicator v6 TrendMean reversion
Updated 4 weeks ago · Apache-2.0 GitHub repository of Autocorrelation Function (ACF)
92 stars

This indicator plots a volume-weighted average price of the typical price on the chart and colors that line by ADX strength. It draws a standard-deviation envelope around VWAP and tints the fill green when plus DI leads and red when minus DI leads. Triangle ma

Indicator v5 TrendOscillators & momentum
Updated 8 weeks ago · Custom licence GitHub repository of Moon Dev VWAP x ADX Explosion

Conditional colors

by be-thomas
65 stars

This script calculates a simple moving average of closing prices over a specified length and dynamically changes its plot color based on the direction of the average. When the moving average value is rising compared to the previous bar, the line displays the s

Indicator v5 TrendMoving averages
Updated 4 days ago · GPL-3.0 GitHub repository of Conditional colors

Scalping Position Size

by iamrichardD
57 stars

This indicator calculates a suggested position size from account size, risk per trade, and a percentage stop. It multiplies account size by the risk percent to get the dollar risk, then divides that by a stop distance equal to the current close times the stop-

Indicator v6 Screeners & dashboardsScalping
Updated 1 year ago · Apache-2.0 GitHub repository of Scalping Position Size

Supply Demand

by iamc1oud
56 stars

Supply Demand is a Smart Money Concepts style indicator that maps market structure and identifies volumetric order blocks directly on the price chart. It detects swing points, structural sweeps, and key supply and demand zones. Users can customize structural c

Indicator v5 SMC / ICT / price actionSupport & resistance Repaints
Updated 2 months ago · None stated GitHub repository of Supply Demand
55 stars

This indicator calculates a 14-period RSI from close and plots it in a separate pane with dotted overbought and dashed oversold lines at 70 and 30. It marks bullish divergence when a five-bar pivot low in price is lower than the price twenty bars earlier while

Indicator v6 Oscillators & momentumDivergence
Updated 6 months ago · Apache-2.0 GitHub repository of RSI Divergence Detector
53 stars

The script calculates the Relative Strength Index (RSI) alongside customizable overbought and oversold thresholds. It tracks recent high and low values over a user-defined lookback period to detect price and momentum divergence. Bullish and bearish divergences

Indicator v6 Oscillators & momentumDivergence
Updated 2 months ago · MPL-2.0 GitHub repository of RSI Divergence [Ahmed Edition]

Choppiness Index

by mihakralj
47 stars

The Choppiness Index is a technical indicator designed to determine whether a market is trending or consolidating. It calculates values between zero and one hundred using true range sums and price ranges over a user-defined lookback length. Lower values indica

Indicator v6 TrendVolatility & bands
Updated 8 months ago · MIT GitHub repository of Choppiness Index

Reversal Breakout System

by TamaraKGreen
46 stars

This indicator detects inside candles inside larger parent candles on the price chart. It plots colored boxes around inside and parent candles, fills them with user-adjustable transparency, draws Fibonacci retracement lines and mother candle range lines, and d

Indicator v6 Candlestick patternsBreakout
Updated 7 weeks ago · None stated GitHub repository of Reversal Breakout System
43 stars

This indicator plots Donchian channel bands and a midline on the price chart. It finds the highest and lowest values over a user-set length, then draws the upper band, lower band, and their average as the basis. The source setting chooses high and low, or the

Indicator v4 Volatility & bandsBreakout
Updated 1 year ago · None stated GitHub repository of Donchian Channels Experiment
43 stars

The Candle Bar - No Repaint indicator plots candlestick bars on the price chart. It sets the high and low to the maximum and minimum open prices from the previous three bars. The close of the bar is taken as the current open. The bar color turns blue when the

Indicator v5 Candlestick patterns
Updated 2 years ago · None stated GitHub repository of Candle Bar - No Repaint
41 stars

This indicator marks unfilled price gaps on the chart. It treats a gap-up as the current low above the previous close and a gap-down as the current high below the previous close, then draws a colored box for each gap that extends to the right. A dotted line ca

Indicator v5 Support & resistance
Updated 2 days ago · None stated GitHub repository of Unfilled Close-Adjusted Gaps

Average True Range

by TWODS-CAPITAL
37 stars

This indicator calculates the average true range and plots it as a single line in a separate pane. It measures true range with gaps included, then smooths that series over a user-set length. The main settings choose the lookback length and the moving-average m

Indicator v5 Volatility & bands
Updated 3 years ago · MIT GitHub repository of Average True Range

Zen Trading Toolkit

by Zen-Tim
29 stars

This indicator plots average bar range (ABR) measured move targets, opening range boxes, and historical key reference levels directly on the price chart. It projects bullish and bearish targets (0.5x, 1.0x, 1.5x, 2.0x ABR) from the previous session's close, al

Indicator v6 Support & resistanceVolatility & bands
Updated 2 weeks ago · MIT GitHub repository of Zen Trading Toolkit

Breaker Blocks with Signals [LuxAlgo] is an overlay indicator that identifies smart money market structure swing points and breaker block zones. It plots bullish and bearish breaker blocks directly on the price chart as dynamic boxes. Traders can customize the

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 2 months ago · AGPL-3.0 GitHub repository of Breaker Blocks with Signals [LuxAlgo]
24 stars

This indicator plots a smoothed stochastic oscillator in a separate pane, with K and D lines, a midsection background, and adjustable overbought and oversold levels. Optional highlights mark overbought or oversold breakouts and K/D crossovers, and ribbon filli

Indicator v5 Oscillators & momentumVolatility & bands
Updated 4 years ago · MPL-2.0 GitHub repository of Intermediate Stochastic
20 stars

This indicator plots a Swami Chart of relative strength index values in a separate pane. It calculates RSI-style up and down ratios for lookbacks from 2 to 48 bars, smooths them with a Super Smoother filter, and colors stacked horizontal plots as a heatmap. Va

Indicator v5 Oscillators & momentum
Updated 1 year ago · None stated GitHub repository of Swami Chart RSI - John F. Ehlers

RSI/BB 1minute Study

by SammyEnigma
18 stars

This strategy plots an RSI line in a separate pane and calculates Bollinger Bands and band width without showing those plots. It enters long when price crosses under the lower band and RSI is at or below the buy level. When price crosses the upper band and RSI

Strategy v4 Oscillators & momentumVolatility & bands
Updated 6 years ago · None stated GitHub repository of RSI/BB 1minute Study

This strategy executes trend-following breakout trades using asymmetric parameters for long and short directions. It calculates Donchian channels and ATR (N) to adapt to directional market speeds. Long positions utilize a longer entry lookback and tighter ATR

Strategy v6 TrendBreakout
Updated 11 months ago · None stated GitHub repository of Seykota Alt 20: Asymmetric Long/Short

Divergenced D002

by ruckard
13 stars

Divergenced D002 is a trading strategy designed to identify entries based on price and Squeeze Momentum indicator divergences. It triggers long or short positions when histogram color transitions conflict with price higher highs or lower lows. Position exits a

Strategy v5 DivergenceOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Divergenced D002

WE-VPVR

by davro
10 stars

Calculates and projects a Volume Profile Visible Range (VPVR) directly onto the price chart. It calculates volume distribution over a configurable lookback depth to generate horizontal profile bars and highlight the Point of Control (POC) line where trading ac

Indicator v4 VolumeSupport & resistance
Updated 5 years ago · None stated GitHub repository of WE-VPVR
10 stars

TPCharts Liquidity Range calculates and plots significant liquidity levels over a specified historical period and resolution directly on the main price chart. It highlights the range high, range low, and the 50% range equilibrium level, as well as the previous

Indicator v4 Support & resistanceSMC / ICT / price action Repaints
Updated 5 years ago · GPL-3.0 GitHub repository of TPCharts Liquidity Range

Chandelier Flip Radar plots an ATR trailing stop on the price chart and tracks a directional trend state. It holds a ratchet stop until an accepted flip, using close or wick extremums and a body filter so weak breaks do not change direction. Distance to the fl

Indicator v6 TrendVolatility & bands
Updated yesterday · MIT GitHub repository of Chandelier Flip Radar [WavesUnchained]

VWAP Reversion (Example)

by JasonTeixeira
9 stars

This indicator overlays a volume-weighted average price and a simple moving average on the price chart. It calculates VWAP from the typical price of high, low, and close and an SMA of close over a user-set length that defaults to 20. It plots the VWAP in orang

Indicator v5 Moving averagesVolume
Updated 12 days ago · Custom licence GitHub repository of VWAP Reversion (Example)

About the Pine Script Library

The ForexR Pine Script Library collects open-source TradingView indicators, strategies and libraries that are published on GitHub. Every script links to its repository, so you can see the author's latest version, issues and licence. Where the licence allows it, the full code is on the script's page, ready to copy into TradingView's Pine Editor. Stars, updates and licences are synced from GitHub every day, and new scripts are added every week.

Each script is read automatically before it is listed: it must declare an indicator, strategy or library for Pine Script version 4 or later, and copies of the same code are listed only once. The summaries and tags are written automatically from the code and the README. They describe what a script does; they are not a recommendation, and nothing here is tested or endorsed by ForexR.

Indicators and backtests describe the past. Check any strategy in the Strategy Tester and on a demo account before you trade with it. CFDs and leveraged forex are complex instruments with a high risk of losing money rapidly.

Pine Script Library FAQ

What is Pine Script?

Pine Script is the programming language of TradingView. Indicators, strategies and libraries written in it run directly on TradingView charts: an indicator draws lines, zones or signals, a strategy places simulated trades that the Strategy Tester reports on, and a library holds functions other scripts can import.

How do I add a Pine Script to my TradingView chart?

Open a script here and press Copy script. In TradingView, open the Pine Editor at the bottom of the chart, create a new indicator or strategy, select all of the template text and paste over it. Press Save, then Add to chart. A strategy's trades appear in the Strategy Tester tab.

Are these Pine Scripts free?

Yes. Every script listed here is published on GitHub, so you can read and use it at no cost. ForexR shows the full code only when the author published it under an open licence, such as MIT, GPL or the Mozilla Public License that TradingView adds to new scripts. For other scripts the Copy button reads the file straight from GitHub. Check the licence before reusing code in your own work.

Why are there no Pine Script v3 or older scripts?

Pine Script versions 1 to 3 are years out of date and miss most of the functions current scripts rely on. The library lists scripts written for versions 4, 5 and 6, and you can filter by version. Version 6 is the current one.

What does "Repaints" mean?

A repainting script can change its signals after the fact: on the live bar, or when it reads a higher timeframe before that bar has closed. Its history then looks better than it would have traded in real time. Scripts where the code or the author says so are marked Repaints, and the "Hide repainting" filter leaves them out.

How does ForexR choose which scripts to list?

A crawler searches GitHub every week for Pine Script files, reads each one and keeps scripts written for Pine version 4 or later in repositories with at least one star. Copies of the same code are listed once, under the most-starred repository. Repositories that ship programs, hide downloads behind passwords or show signs of bought stars are left out. Stars, updates and licences are refreshed from GitHub every day, and the summaries are written automatically from each script's code and README.

Trade on TradingView With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers