Synced with GitHub · updated today

Free TradingView Pine Scripts

10,850 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
10,850 scripts

libhl

by ivansoft
1 stars

A Pine Script v5 library that records the open, high, low and close points of successive periods and keeps the latest few in an array. It exports types for period contexts and alignment, a helper that detects when a period such as a week or month changes relat

Library v5 Support & resistance Repaints
Updated 1 year ago · None stated GitHub repository of libhl

FATTAL-tracker

by Allen1212
303 stars

This indicator overlays dated ARK Invest buy and sell labels on the FATTAL price chart. It places a green buy label below the bar and a red sell label above the bar at fixed historical timestamps, with text marking the direction and a count of one. An ETF inpu

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

My Script

by ricardosantos79
261 stars

This indicator implements a one-dimensional function minimizer in a separate pane, based on golden-section search combined with successive parabolic interpolation. A sample function of cosine plus one is evaluated inside a rolling log of the latest ten results

Indicator v4
Updated 4 years ago · None stated GitHub repository of My Script
114 stars

Volume Weighted Distance applies statistical and machine learning distance metrics between source prices and their rolling mean, weighted by volume, to identify local trend reversals. Users can select from Manhattan, Euclidean, Mahalanobis, Cosine Similarity,

Indicator v4 Oscillators & momentumVolume Repaints
Updated 1 year ago · None stated GitHub repository of Volume Weighted Distance

This Pine Script strategy detects bullish engulfing candlestick patterns to generate buy and sell signals overlaid directly on the price chart. It supports backtesting over a user-defined date range with inputs for profit target, stop loss percentage, order si

Strategy v5 Candlestick patterns
Updated 2 years ago · GPL-3.0 GitHub repository of Buy&Sell Bullish Engulfing - The Quant Science
99 stars

This indicator plots Ehlers Ultimate Bands on the price chart. It smooths the selected source with an Ehlers ultrasmooth filter, measures the root-mean-square of residuals over the lookback, and draws upper and lower bands as that smooth line plus or minus the

Indicator v6 Volatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Ehlers Ultimate Bands (UBANDS)

History SAW demo

by be-thomas
65 stars

History SAW demo is a TradingView documentation example script that demonstrates basic long position entry execution. The script enters a long position on every bar, building positions up to a maximum pyramiding limit of 100 entries. Orders are re-evaluated on

Strategy v4
Updated 5 days ago · GPL-3.0 GitHub repository of History SAW demo
47 stars

This indicator calculates the Williams Gator Oscillator derived from Bill Williams Alligator lines and plots dual histograms in a separate pane. The upper histogram displays the absolute difference between the Jaw and Teeth moving averages, while the lower his

Indicator v6 Oscillators & momentumMoving averages
Updated 8 months ago · MIT GitHub repository of Williams Gator Oscillator

Parabolic SAR Strategy

by TWODS-CAPITAL
37 stars

This strategy implements a custom Parabolic SAR algorithm to generate trend-following entries. It plots current and next-bar SAR levels directly on the main price chart. When the SAR flips, the strategy places stop orders to reverse positions from long to shor

Strategy v5 Trend
Updated 3 years ago · MIT GitHub repository of Parabolic SAR Strategy
13 stars

This strategy looks for a long rebound after three or more candles of falling volume followed by a higher-volume candle, while price is lower across that span. It is written as a Zignaly-linked TradingView strategy and was noted for BTCUSDT on the one-hour cha

Strategy v5 Volume
Updated 1 year ago · None stated GitHub repository of Ruckard Voladder E007
9 stars

The script calculates a two-layer reversal scoring system designed to identify potential market turning points. Layer A evaluates momentum, overextension, volume, and candle metrics to establish a setup score, while Layer B confirms structural events such as m

Indicator v6 Oscillators & momentumSMC / ICT / price action
Updated 2 days ago · MIT GitHub repository of Vein: Reversal Score 4H

Trend Trader Strategy

by eddiebelaval
7 stars

Calculates a dynamic trend level based on recent highest and lowest prices adjusted by a weighted moving average of Average True Range. It plots the Trend Trader Line directly on the price chart and colors bars according to the active trend direction. Long ent

Strategy v5 TrendVolatility & bands
Updated 3 months ago · None stated GitHub repository of Trend Trader Strategy

Jerry MACD

by g-moe
3 stars

Jerry MACD is a momentum oscillator indicator displayed in a separate pane. It calculates a standard Moving Average Convergence Divergence line, signal line, and histogram using fast, slow, and signal lengths. The indicator features symbol-specific entry thres

Indicator v5 Oscillators & momentumMoving averages
Updated 5 months ago · None stated GitHub repository of Jerry MACD

Dynamic Money Flow

by regalouisei
2 stars

This indicator calculates volume-weighted money flow across price action, plotting in a separate pane. It combines close-to-range and close-to-close metrics using dynamic or static weighting. Users can toggle between an index mode smoothed by RMA or a cumulati

Indicator v5 VolumeOscillators & momentum
Updated 8 months ago · None stated GitHub repository of Dynamic Money Flow

PF probe 54 - MTF roll state

by pineforge-4pass
1 stars

This strategy detects roll states in multiple timeframes to generate trading signals on the price chart. It fetches close prices from 60m, 240m and daily bars using request.security. Long entries trigger on a 60m roll up with flat 240m state or on a daily high

Strategy v6 TrendBreakout
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 54 - MTF roll state
1 stars

A price-chart indicator that combines trend, range edge reversal and transition breakout sleeves, with shock conditions blocking new signals. It uses an adaptive core, causal trail, completed ranges and a previous completed higher-timeframe filter. Presets suc

Indicator v6 TrendBreakout Repaints
Updated 2 months ago · None stated GitHub repository of NO.1 V5 Ultimate Adaptive Engine

KC Combo Bull

by nishpa800
1 stars

Time-chart bullish overlay indicator with 23 combination markers that mix Keltner Channel logic with other engines. Inputs cover a VWMA base line, an ATR Supertrend, a PB and J filter, Keltner bands with slope thresholds, pocket pivot size, and a displacement

Indicator v5 Volatility & bandsVolume Repaints
Updated 2 months ago · None stated GitHub repository of KC Combo Bull

TN Sovereign Market Structure v6 is an overlay strategy that identifies market structure breaks and trends using pivot points, a 50-period Exponential Moving Average (EMA), and the Ichimoku Cloud. It detects Break of Structure (BOS) signals when price closes p

Strategy v6 SMC / ICT / price actionTrend
Updated 2 months ago · None stated GitHub repository of TN Sovereign Market Structure v6
1 stars

Draws supply and demand zones on the price chart from engulfing candle patterns. Settings set how many bars back removal of invalidated zones begins, how much history is kept after invalidation, and a tolerance margin. A long term mode keeps more zones. Algori

Indicator v5 Support & resistanceCandlestick patterns
Updated 6 months ago · None stated GitHub repository of Supply and Demand Zones V4
1 stars

An indicator that draws a box on the price chart for each higher timeframe period, showing that period's range as one candle-like block. The timeframe is chosen automatically from the chart timeframe or set by hand. Box height can be based on the high-low rang

Indicator v5 Support & resistance Repaints
Updated 1 year ago · None stated GitHub repository of Multi-Time Period Charts

FB Tracker

by Allen1212
303 stars

This indicator plots ARK Invest buy and sell trade labels directly on the price chart for Facebook stock. Labels show buy quantities with green "Buy Xn" text and sell quantities with red "Sell Xn" text at exact bar times. The etf_type input changes the ETF fil

Indicator v4 Support & resistanceSMC / ICT / price action
Updated 2 years ago · None stated GitHub repository of FB Tracker

Tables 002 Matrixscreen

by ricardosantos79
261 stars

This visual script displays a digital matrix screen effect using TradingView tables. It generates pseudo-random character displays across a customizable grid of rows and columns. Users can configure the table dimensions, controlling row and column counts to ad

Indicator v4 Screeners & dashboards
Updated 4 years ago · None stated GitHub repository of Tables 002 Matrixscreen

This boilerplate strategy script acts as a customizable template for generating buy and sell signals based on price or source crossovers relative to defined fixed values. Users can select an input source, set threshold values, and specify whether to trigger en

Strategy v5 Support & resistance
Updated 2 years ago · GPL-3.0 GitHub repository of Buy/Sell Signal Template/Boilerplate Strategy [ExoMaven]
99 stars

Ehlers Ultimate Channel calculates volatility bands around an adaptive smoothed centerline based on John Ehlers' smoothing algorithm. It applies a specialized infinite impulse response filter to both price and True Range, constructing an upper, middle, and low

Indicator v6 Volatility & bandsSupport & resistance
Updated 4 weeks ago · Apache-2.0 GitHub repository of Ehlers Ultimate Channel (UCHANNEL)

Holiday Candles

by be-thomas
65 stars

Holiday Candles is a visual demonstration script from TradingView documentation that renders price candlesticks with randomized colors. For each bar, it generates pseudo-random values for red, green, blue, and transparency levels to construct a dynamic RGB col

Indicator v4 Candlestick patterns
Updated 5 days ago · GPL-3.0 GitHub repository of Holiday Candles
47 stars

This indicator plots a winsorized mean moving average of the close on the price chart. Over a lookback window it sorts values, replaces the lowest and highest percentage of samples with the values at the trim boundaries, and averages the full window so outlier

Indicator v6 Moving averages
Updated 8 months ago · MIT GitHub repository of WINS: Winsorized Mean Moving Average

Piercing - Bullish

by TWODS-CAPITAL
37 stars

Identifies the two-candle bullish Piercing Line reversal pattern during a downtrend directly on the price chart. It checks for a long bearish candle followed by a bullish candle opening at or below the prior low and closing above its midpoint. Users can filter

Indicator v5 Candlestick patternsTrend
Updated 3 years ago · MIT GitHub repository of Piercing - Bullish
13 stars

Ruckard Walcrypto DoubleDonchian is a trend-following breakout strategy built on two Donchian Channels with an optional exponential moving average filter. Position entries trigger when price achieves a new high or low on the primary channel, provided the optio

Strategy v5 TrendBreakout
Updated 1 year ago · None stated GitHub repository of Ruckard Walcrypto DoubleDonchian

This indicator draws support and resistance zones on the price chart from reversal bars that later reach ATR-based targets. Weak and strong labels depend on travel distance, adverse move, and how quickly the target is hit. Nearby same-direction zones merge, a

Indicator v6 Support & resistanceOscillators & momentum Repaints
Updated 2 days ago · MIT GitHub repository of Vein: Reversal Zones [WavesUnchained]

Vdubus Pattern Gen V2

by eddiebelaval
7 stars

Vdubus Pattern Gen V2 is a TradingView indicator that identifies and plots chart patterns, harmonic shapes, and structural reversals based on multi-scale ZigZag structures and smoothed momentum physics. It draws fast entry structures, slow macro context struct

Indicator v5 TrendSupport & resistance Repaints
Updated 3 months ago · None stated GitHub repository of Vdubus Pattern Gen V2
6 stars

This indicator plots Malaysian-style support and resistance on the price chart. It marks A levels from pivot highs and V levels from pivot lows, using a user-set lookback, and can also mark gap levels. Fresh and previously touched levels can be shown or hidden

Indicator v5 Support & resistance
Updated 7 months ago · None stated GitHub repository of Malaysian SnR [by DanielM]
3 stars

This trading strategy evaluates moving average slope and concavity changes to identify trend direction and entry signals. Traders can choose between Hull, EMA, SMA, WMA, or ALMA moving averages, filtered by secondary trend EMAs for long and short positions. Si

Strategy v5 TrendMoving averages
Updated 5 months ago · None stated GitHub repository of Jerry Strategy / Dashboard

Earnings Price Move Cheat Sheet [Kioseff Trading] is an overlay indicator designed to quantify price movements around earnings announcements. It calculates percentage returns across earnings periods and uses historical simulation to estimate Value at Risk (VaR

Indicator v5 Volatility & bandsScreeners & dashboards
Updated 8 months ago · None stated GitHub repository of Earnings Price Move Cheat Sheet [Kioseff Trading]
1 stars

This strategy is a validation probe that isolates an implicit reversal exit. When flat at 00:15 it enters one long unit. At 00:45 an opposite short entry of quantity one closes that long and opens a short. At 01:15 an opposite long entry reverses back to long.

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 55 - entry reversal implicit exit

OBV Signal Confluence

by vedkanani123
1 stars

An On-Balance Volume oscillator in a separate pane. It plots an OBV histogram against a moving average chosen from SMA, RMA, WMA or VWMA and marks regular and hidden divergence from pivots. Optional filters use a higher-timeframe confirmation, ADX and a volume

Indicator v6 VolumeDivergence
Updated 2 months ago · None stated GitHub repository of OBV Signal Confluence

KC Combo Bull Tick

by nishpa800
1 stars

Tick-chart bullish overlay indicator with 23 combination markers that mix Keltner Channel logic with other engines. Inputs cover a VWMA base line, an ATR Supertrend, a PB and J filter, Keltner bands with slope thresholds, pocket pivot size, and a displacement

Indicator v5 Volatility & bandsVolume Repaints
Updated 2 months ago · None stated GitHub repository of KC Combo Bull Tick
1 stars

This multi-timeframe strategy combines higher-timeframe trend context with lower-timeframe execution. It evaluates macro trend direction on a higher timeframe using Exponential Moving Average crosses and a Supertrend indicator. On the lower timeframe, entry si

Strategy v6 TrendMoving averages Repaints
Updated 2 months ago · None stated GitHub repository of TN Sovereign MTF Dual-Layer v6
1 stars

Draws supply and demand zones on the price chart from engulfing candle patterns, split into two zone types: one where price breaks the zone high or low, and one where only the open is broken. Each type has its own maximum count, and a tolerance margin allows s

Indicator v5 Support & resistanceCandlestick patterns
Updated 6 months ago · None stated GitHub repository of Supply and Demand Zones V4

Varip Period Tracker

by ivansoft
1 stars

Experimental overlay that tracks high and low points for several period types such as session, five and ten minutes, day, week, month and year using varip objects. It draws dashed lines for the current period extremes and writes debugging labels with times on

Indicator v5 Support & resistanceSessions & time Repaints
Updated 1 year ago · None stated GitHub repository of Varip Period Tracker

FBRT-tracker

by Allen1212
303 stars

FBRT-tracker is an overlay indicator that marks recorded ARK Invest activity in FBRT with labels on the price chart. With the ETF input set to ALL, it draws red downward labels above bars on fixed dates, each reading as a sell with a count of X1. The only sett

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

Tables-001

by ricardosantos79
261 stars

This indicator builds a TradingView table in a separate pane and fills its cells with fixed placeholder text according to whether each row and column index is even or odd. Users set the table position, the number of rows and columns, and the background, frame,

Indicator v4 Screeners & dashboards
Updated 4 years ago · None stated GitHub repository of Tables-001
114 stars

This indicator overlays a Renko-style brick channel on the price chart. It sets brick size as a fraction of the previous close, choosing that fraction from the chart timeframe, then steps two brick levels when price moves beyond that size. It colors the fill g

Indicator v4 TrendSupport & resistance
Updated 1 year ago · None stated GitHub repository of ZigZag via Renko Emulator

Buy/Sell Strat

by hasnocool
106 stars

This strategy plots a fast and a slow exponential moving average on the price chart and trades their crossovers. It enters long when the fast average crosses above the slow average, volume is above 85 percent of the prior five-bar average, and price is above t

Strategy v5 TrendMoving averages Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Buy/Sell Strat

This indicator calculates John Ehlers' Ultimate Smoother Filter, a two-pole infinite impulse response filter designed to reduce market noise while minimizing lag. It computes filter coefficients using exponential decay and trigonometric functions, then applies

Indicator v6 Moving averagesTrend
Updated 4 weeks ago · Apache-2.0 GitHub repository of Ehlers Ultimate Smoother Filter (USF)

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