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
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)

This price-chart indicator finds swing highs and lows with a user-set pivot length and classifies them as higher high, lower high, higher low, or lower low. It tracks a trend state and the latest swing signal from those pivots. The same swing comparison is run

Indicator v5 Candlestick patternsSupport & resistance
Updated 5 months ago · None stated GitHub repository of Price Action Candles with Pivot Trendlines

Session ispremarket NASDAQ gate

by pineforge-4pass
1 stars

This strategy evaluates premarket session activity on equity markets like NASDAQ. During premarket hours, it enters a long position whenever an intraday candle closes higher than its open price. Once the regular market session opens, the strategy automatically

Strategy v6 Sessions & timeOscillators & momentum
Updated 5 days ago · Apache-2.0 GitHub repository of Session ispremarket NASDAQ gate

PTON-tracker

by Allen1212
303 stars

PTON-tracker is an overlay indicator that marks historical ARK Invest purchases and sales of Peloton on the price chart. It places green buy labels below bars and red sell labels above bars on hardcoded dates, each noting how many ARK ETFs traded that day. An

Indicator v4
Updated 2 years ago · None stated GitHub repository of PTON-tracker
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)

This indicator identifies pivot highs and pivot lows on the price chart using specified lookback and lookahead bar lengths. When a pivot low is detected, it plots a green triangle below the corresponding bar. When a pivot high is detected, a red triangle is pl

Indicator v5 Support & resistance
Updated 5 months ago · None stated GitHub repository of Price Action Candles with Pivot Trendlines
2 stars

Live Economic Calendar by toodegrees overlays scheduled macroeconomic news events directly onto the price chart and displays an on-screen summary table. It retrieves economic release data across major global currencies, allowing traders to filter events by imp

Indicator v5 Sessions & timeScreeners & dashboards
Updated 8 months ago · None stated GitHub repository of Live Economic Calendar by toodegrees

Stochastic RSI

by pineforge-4pass
1 stars

This strategy calculates a smoothed Stochastic RSI oscillator and generates trading signals based on overbought and oversold crossovers. It opens a long position when the %K line crosses above %D while below the oversold threshold, and enters short when %K cro

Strategy v6 Oscillators & momentumMean reversion
Updated 5 days ago · Apache-2.0 GitHub repository of Stochastic RSI

PYPL-tracker

by Allen1212
303 stars

This indicator plots historical ARK Invest buy and sell events for PayPal on the price chart. Green labels sit below bars for purchases and red labels sit above bars for sales, each marked with a same-day ETF count such as X1 or X2. An ETF input switches among

Indicator v4
Updated 2 years ago · None stated GitHub repository of PYPL-tracker
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
99 stars

This indicator plots the Price Momentum Oscillator in a separate pane. It measures one-bar rate of change of the chosen source, then applies two custom exponential smoothings: the first EMA of the percentage ROC is scaled by ten, and a second EMA produces the

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Price Momentum Oscillator (PMO)

This indicator draws supply and demand zones and break-of-structure markers on the price chart. It detects swing highs and lows over a user-set length, then labels them as higher high, lower high, higher low, or lower low when price-action labels are enabled.

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 5 months ago · None stated GitHub repository of Price Action Candles with Zig Zag

Logging in Pine Script

by regalouisei
2 stars

This indicator plots pivot high and low lines on the price chart based on user-defined bars on each side of the pivot. It automatically logs messages for new pivots, higher highs, lower lows, and price crosses with color-coded text (gray for messages, orange f

Indicator v5 Support & resistanceScreeners & dashboards
Updated 8 months ago · None stated GitHub repository of Logging in Pine Script

Supertrend ADX Filter

by pineforge-4pass
1 stars

The Supertrend ADX Filter strategy calculates Supertrend direction and ADX strength to generate trend signals. It plots the Supertrend line on the price chart in green for bullish and red for bearish. Long entries trigger on Supertrend direction change to bull

Strategy v6 TrendOscillators & momentum
Updated 5 days ago · Apache-2.0 GitHub repository of Supertrend ADX Filter

QSI Tracker

by Allen1212
303 stars

QSI Tracker visualizes historical buy and sell transactions made by ARK Invest funds directly on the price chart. The script plots customized visual labels on specific historical dates to indicate trading activity and quantify multi-ETF involvement. Users can

Indicator v4
Updated 2 years ago · None stated GitHub repository of QSI Tracker

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
99 stars

Price Relative Strength (RS) compares base asset prices to a compare symbol like SPY to measure relative performance. It calculates raw ratio and smoothed ratio with EMA-like smoothing over a configurable period. Optional normalization scales values to 100 and

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Price Relative Strength (RS)
3 stars

Price-Action Candles classifies swing structure from pivot highs and lows and colors chart candles bullish, bearish, or neutral. It marks higher highs, lower highs, higher lows, and lower lows, with a label mode that either offsets labels by the pivot length o

Indicator v5 TrendCandlestick patterns Repaints
Updated 5 months ago · None stated GitHub repository of Price-Action Candles
2 stars

This indicator tracks the most recent historical daily high higher than the current day's high and the most recent daily low lower than the current day's low. It scans back up to 5000 bars using daily security calls to identify these price levels, the elapsed

Indicator v5 Support & resistanceScreeners & dashboards
Updated 8 months ago · None stated GitHub repository of Lowest / Highest From Widget

Swing Pivot ATR

by pineforge-4pass
1 stars

Swing Pivot ATR is a trend-breakout strategy that identifies swing highs and lows using pivot points and enters positions on price breakouts. It tracks historical pivot high and low levels, plotting them as steplines directly on the price chart. When price clo

Strategy v6 TrendBreakout
Updated 5 days ago · Apache-2.0 GitHub repository of Swing Pivot ATR

RADA-tracker

by Allen1212
303 stars

This overlay indicator marks historical ARK Invest purchases of RADA on the price chart with dated labels. When the ETF input is set to ALL, it places green below-bar labels on specific calendar days using bar time, showing a buy and a count such as X1. The on

Indicator v4
Updated 2 years ago · None stated GitHub repository of RADA-tracker
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)

Pseudo-Huber Loss

by mihakralj
99 stars

This indicator computes the rolling mean of the Pseudo-Huber Loss, a smooth approximation of absolute error between the actual close prices and predicted open prices. The loss function transitions between quadratic and linear behavior controlled by the delta p

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Pseudo-Huber Loss
3 stars

Price-Action Candles (Lower) is a separate-pane indicator that classifies swing structure from pivot highs and lows. It marks higher highs, lower highs, higher lows, and lower lows, then assigns a bullish, bearish, or neutral trend from those swings and the cl

Indicator v5 TrendSupport & resistance Repaints
Updated 5 months ago · None stated GitHub repository of Price-Action Candles (Lower)
2 stars

This indicator visualizes intrabar market activity by requesting lower timeframe open, close, and volume data. It constructs a visual heatmap directly on the price chart using colored box objects, where gradient shading represents volume intensity across intra

Indicator v5 VolumeSupport & resistance
Updated 8 months ago · None stated GitHub repository of LTF Activity Heatmap [LuxAlgo]
1 stars

This strategy evaluates intraday trading execution for US equities during regular trading hours while handling overnight gaps. It calculates a 14-period Relative Strength Index (RSI) across price history without daily resets. Trades are gated by the market ses

Strategy v6 Oscillators & momentumSessions & time
Updated 5 days ago · Apache-2.0 GitHub repository of Symbol Equity RTH + Overnight Gaps AAPL

RAVN-tracker

by Allen1212
303 stars

RAVN-tracker visualizes historical buy and sell transactions executed by ARK Invest funds for RAVN stock directly on the price chart. Using hardcoded trade timestamps, it plots green buy labels below bars and red sell labels above bars to highlight historical

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

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
99 stars

This indicator calculates the Psychological Line as the percentage of up-bars over a lookback window. It counts bars where the selected source is higher than the previous bar and divides that count by the period, scaled to 0–100. A circular buffer keeps a runn

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Psychological Line (PSL)

Prior Day Levels

by g-moe
3 stars

Prior Day Levels plots horizontal reference lines for the previous day's high, low, close, and midpoint, plus the previous week's high, low, close, and midpoint. Each level can be shown or hidden, and its color, line style, and width can be set independently.

Indicator v5 Support & resistance
Updated 5 months ago · None stated GitHub repository of Prior Day Levels

TArec_p02_UNT

by pineforge-4pass
1 stars

The strategy tests untested TA classes including ALMA, SAR and rolling correlation under bar magnifier. It enters long only when ALMA crosses above close, SAR flips below price and 20-period correlation of close and volume is positive. It exits long when SAR f

Strategy v6 TrendOscillators & momentum
Updated 5 days ago · Apache-2.0 GitHub repository of TArec_p02_UNT

RDHL Tracker

by Allen1212
303 stars

RDHL Tracker plots historical buy and sell transactions executed by ARK Invest for Redhill Biopharma directly on the price chart. The script creates color-coded labels at specific historical trade timestamps, marking buy actions in green below the price bar an

Indicator v4
Updated 2 years ago · None stated GitHub repository of RDHL Tracker

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

Ehlers Precision Trend Analysis extracts trend direction using a dual high-pass filter bandpass approach. It calculates two 2-pole Butterworth high-pass filters on close prices using configurable long and short periods, subtracting the shorter filter from the

Indicator v6 TrendOscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of PTA - Ehlers Precision Trend Analysis
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
1 stars

This Pine Script strategy executes a dual moving average crossover system designed as a validation test for intraday order capping across exchange session rollovers. It calculates a 9-period fast SMA and a 21-period slow SMA, entering long on bullish crossover

Strategy v6 Moving averagesTrend
Updated 5 days ago · Apache-2.0 GitHub repository of US-equity Intraday Cap (Scaffold)

RDWR Tracker

by Allen1212
303 stars

RDWR Tracker visualizes historical buy and sell transactions made by ARK Invest for Radware (RDWR) directly on the price chart. It plots colored labels on specific trade dates displaying whether ARK bought or sold shares along with the number of participating

Indicator v4
Updated 2 years ago · None stated GitHub repository of RDWR Tracker

Bollinger Blast Buy

by hasnocool
106 stars

This strategy plots an asymmetric Bollinger envelope on the price chart. The upper band is a simple moving average plus a larger standard-deviation multiple, and the lower band uses a smaller multiple. It enters long when close crosses above the upper band and

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

Qstick Indicator

by mihakralj
99 stars

This indicator calculates the Qstick value as a simple or exponential moving average of the difference between a chosen close source and open source. It plots that oscillator in a separate pane as a yellow line, draws a dashed zero line, and shades the backgro

Indicator v6 Oscillators & momentumCandlestick patterns
Updated 4 weeks ago · Apache-2.0 GitHub repository of Qstick Indicator

Psych Levels

by g-moe
3 stars

This TradingView indicator overlays horizontal zones on the price chart to highlight psychological rounding levels. It analyzes the close price's decimal length and mintick to compute baseline values for singles, tens, hundreds, and thousands zones. These leve

Indicator v5 Support & resistance
Updated 5 months ago · None stated GitHub repository of Psych Levels

MA Sabres [LuxAlgo]

by regalouisei
2 stars

MA Sabres identifies trend reversals by monitoring direction changes in a selectable moving average after a user-defined trend duration. The indicator supports various moving average types including SMA, EMA, HullMA, VWMA, DEMA, and TEMA. When a moving average

Indicator v5 TrendMoving averages
Updated 8 months ago · None stated GitHub repository of MA Sabres [LuxAlgo]

VCP probe 01 - pivot strength 5

by pineforge-4pass
1 stars

This strategy identifies pivot highs and pivot lows using standard pivot detection functions to evaluate market structure. Plotted directly overlaying the price chart, it enters a fixed long position on the exact bar where a pivot low is confirmed. The long po

Strategy v6 Support & resistance
Updated 5 days ago · Apache-2.0 GitHub repository of VCP probe 01 - pivot strength 5

RHHBY-tracker

by Allen1212
303 stars

This indicator plots historical buy and sell transactions executed by ARK Invest funds directly on the price chart for RHHBY. It renders visual chart labels below or above bars at specified historical timestamps, detailing the trade direction and the count of

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

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