Synced with GitHub · updated yesterday

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

PVT EMA Cross

by pineforge-4pass
1 stars

A minimal strategy that compares the Price Volume Trend indicator with a 21-period EMA of itself. It enters long when PVT crosses above the average and short when it crosses below, reversing the position each time. It has no adjustable inputs, no stop loss and

Strategy v6 Volume
Updated 6 days ago · Apache-2.0 GitHub repository of PVT EMA Cross

TARO-tracker

by Allen1212
303 stars

TARO-tracker plots historical ARK Invest transactions for TARO stock directly on the price chart. It renders buy and sell labels positioned on specific dates using bar timestamps, indicating the direction of ARK's trade along with an ETF participation multipli

Indicator v4
Updated 2 years ago · None stated GitHub repository of TARO-tracker
106 stars

Order At Specified Time is a TradingView strategy that executes trades at a designated time of day within a specified backtest date range. At the user-configured UTC hour and minute, the strategy enters a short market position while simultaneously placing a lo

Strategy v4 Sessions & time
Updated 2 years ago · GPL-3.0 GitHub repository of Order At Specified Time

This indicator measures symmetric mean absolute percentage error between a chosen price source and an exponential moving average of that source. Each bar it computes a symmetric percentage error, then averages those errors over the selected lookback with a cir

Indicator v6 Moving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of Symmetric Mean Absolute %Error (SMAPE)

Hercules Srategy

by g-moe
3 stars

This strategy detects momentum breakouts identified as lightning candles where the absolute candle body size exceeds a user-defined tick threshold. It enters long positions on large bullish candles and short positions on large bearish candles, with an option t

Strategy v5 BreakoutOscillators & momentum
Updated 5 months ago · None stated GitHub repository of Hercules Srategy

Range Filter

by pineforge-4pass
1 stars

Calculates an exponential moving average of candle ranges scaled by a multiplier to build an adaptive, stateful trend filter. It updates dynamic upper and lower bands that drift with price action and track market direction. The strategy enters long when the fi

Strategy v6 TrendVolatility & bands
Updated 6 days ago · Apache-2.0 GitHub repository of Range Filter

TCEHY-tracker

by Allen1212
303 stars

This overlay indicator marks historical ARK Invest purchases and sales of Tencent Holdings (TCEHY) directly on the price chart. When the ETF input is ALL, it places green buy labels below bars and red sell labels above bars on fixed dates, with text such as Bu

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

Prototype

by hasnocool
106 stars

This strategy overlays Supertrend-style ATR trailing stop levels on the price chart alongside multi-period moving averages, volume metrics, and Bollinger Bands. It flags trend direction changes using an ATR offset channel, plotting buy and sell signals directl

Strategy v4 TrendVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of Prototype

TD Sequential (TD_SEQ)

by mihakralj
99 stars

TD Sequential calculates Tom DeMark's exhaustion counting system to identify potential trend reversals. It operates in two phases: Phase 1 Setup tracks consecutive price comparisons against historical closes up to a 9-count, while Phase 2 Countdown tracks non-

Indicator v6 Oscillators & momentumTrend
Updated 4 weeks ago · Apache-2.0 GitHub repository of TD Sequential (TD_SEQ)
3 stars

Ichimoku Cloud Weight calculates an aggregated quantitative score based on multiple Ichimoku Cloud components from a chosen timeframe. It assigns weighted bullish and bearish points to Tenkan and Kijun crosses, price and Kijun crosses, Kumo breakouts, Senkou S

Indicator v5 TrendOscillators & momentum Repaints
Updated 5 months ago · None stated GitHub repository of Ichimoku Cloud Weight

Regex String Filter

by pineforge-4pass
1 stars

Calculates RSI and MACD indicators to evaluate trade signals parsed dynamically from an input text rule string. It uses regular expression matching to determine whether an RSI threshold rule, a MACD bullish signal line rule, or both must be satisfied. When all

Strategy v6 Oscillators & momentumTrend
Updated 6 days ago · Apache-2.0 GitHub repository of Regex String Filter

TCS Tracker

by Allen1212
303 stars

TCS Tracker is an overlay indicator that visualizes historical purchase and sale transactions made by ARK Invest funds for TCS stock. It plots color-coded buy labels directly on the price chart on specific historical dates corresponding to trade execution time

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

Rapid Fire

by hasnocool
106 stars

This strategy draws on the price chart and enters long when the open crosses above the Parabolic SAR and is above a 50-period simple moving average of close. It enters short on the opposite cross below that average. Offset prices of 0.5 percent and 1.5 percent

Strategy v4 TrendMoving averages Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Rapid Fire

Theil's U Statistic

by mihakralj
99 stars

Theil's U Statistic measures forecast accuracy by comparing actual and predicted data series over a rolling length. It calculates a normalized error ratio where zero indicates perfect accuracy and one represents predictive quality equal to a naive forecast. Us

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Theil's U Statistic

This indicator renders Ichimoku cloud components consisting of conversion line, base line, leading span A and leading span B. It tracks Tenkan-Kijun crosses and assigns a numeric score to each based on whether the cross occurs below, inside or above the Kumo c

Indicator v5 Moving averagesSupport & resistance
Updated 5 months ago · None stated GitHub repository of Ichimoku Cloud Weight Original

RSI 14 Cross 50

by pineforge-4pass
1 stars

A minimal strategy that trades the 14-period RSI crossing the 50 midline. It enters long when RSI crosses up through 50 and short when it crosses down through 50, reversing the position on each opposite signal so only one direction is held at a time. It has no

Strategy v6 Oscillators & momentum
Updated 6 days ago · Apache-2.0 GitHub repository of RSI 14 Cross 50

TDY Tracker

by Allen1212
303 stars

TDY Tracker plots historical buy and sell transactions executed by ARK Invest funds for Teledyne Technologies (TDY) directly on the main price chart. It creates visual labels at exact historical timestamps to show institutional trade activity and volume count.

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

Simple MA 200 Cross

by hasnocool
106 stars

This strategy calculates a simple moving average of closing prices and executes a basic trend-following system on the main chart. It enters a long position when the closing price crosses above the moving average and exits the position when the price crosses be

Strategy v4 Moving averagesTrend
Updated 2 years ago · GPL-3.0 GitHub repository of Simple MA 200 Cross
99 stars

This indicator calculates the third finite difference, or jerk, of a selected data series. By applying binomial expansion coefficients across four consecutive bars, it measures the rate of change of price acceleration. Users can customize the source input seri

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Third Derivative / Jerk (JERK)

RSI EMA Signal

by pineforge-4pass
1 stars

A strategy that smooths the RSI with an EMA and trades crossovers between the two. It enters long when RSI crosses above its signal line while RSI is below 50, and short when RSI crosses below its signal while RSI is above 50. RSI length and signal length are

Strategy v6 Oscillators & momentum
Updated 6 days ago · Apache-2.0 GitHub repository of RSI EMA Signal

TEAM-tracker

by Allen1212
303 stars

This indicator overlays historical ARK Invest trade marks for the TEAM ticker on the price chart. It places green buy labels below bars and red sell labels above bars at hardcoded dates, each marked with an X1 count. The ETF input switches between ALL and ARKW

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

This strategy overlays buy and sell signals on the price chart by combining selectable RSI conditions, ADX trend rules, and EMA pullback filters. Users can configure the RSI mode, toggle global EMA trend filtering, enforce EMA pullback requirements, and limit

Strategy v4 TrendOscillators & momentum Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of SirPoggy Simple and Effective RSI Strategy
99 stars

This indicator calculates the Triple Exponential Average oscillator as the percentage rate of change of a triple exponential moving average of the chosen source. It plots the resulting series as a single line in a separate pane. The period input sets the smoot

Indicator v6 Oscillators & momentumMoving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of Triple Exponential Average (TRIX)
3 stars

Kane Bollinger Bands calculates and plots traditional Bollinger Bands alongside a percentage change plot for upper band movement directly on the main price chart. It establishes a Simple Moving Average basis line and generates upper and lower channel boundarie

Indicator v5 Volatility & bandsMoving averages
Updated 5 months ago · None stated GitHub repository of Kane Bollinger Bands

RSI MACD Combined State

by pineforge-4pass
1 stars

A minimal strategy that stays long while two conditions hold together: a 14-period RSI above 50 and the MACD line above its signal line, using 12, 26 and 9 settings. When either condition fails, it closes the long position. It never goes short, has no adjustab

Strategy v6 Oscillators & momentum
Updated 6 days ago · Apache-2.0 GitHub repository of RSI MACD Combined State

TEVA-tracker

by Allen1212
303 stars

TEVA-tracker overlays historical ARK Invest trade labels on the TEVA price chart. The visible script places green buy markers below bars at dated timestamps, with text showing a buy and an X1 count. An ETF input is present but offers only ALL, so it does not f

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

Spread Entry Strategy

by hasnocool
106 stars

This strategy overlays bull and bear setup filters on the price chart. It compares a reference symbol, QQQ by default, on the daily timeframe with hot and cool percent-change levels, then combines RSI, DMI, three simple moving averages, Bollinger Bands, and Ke

Strategy v4 TrendOscillators & momentum Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Spread Entry Strategy
99 stars

Calculates the True Strength Index oscillator and its exponential moving average signal line using custom double-smoothing on price momentum and absolute momentum. The indicator measures trend strength and direction by normalizing smoothed price variations, pl

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of True Strength Index (TSI)
3 stars

This Pine Script v5 indicator demonstrates the matrix.new function for creating custom types. It plots a single label containing the text Hello world at the high price on the chart. The script is set to overlay mode with no input settings and serves as a minim

Indicator v5
Updated 5 months ago · None stated GitHub repository of Matrix New Type Example 1

RSI with Bollinger Bands

by pineforge-4pass
1 stars

Calculates the Relative Strength Index (RSI) and wraps Bollinger Bands directly around the RSI series rather than price. It enters long positions when the RSI drops below its lower band and hooks back upward, and enters short positions when the RSI exceeds the

Strategy v6 Oscillators & momentumVolatility & bands
Updated 6 days ago · Apache-2.0 GitHub repository of RSI with Bollinger Bands

TMO-tracker

by Allen1212
303 stars

This indicator plots historical ARK Invest buy and sell labels for the TMO stock on the price chart. An ETF setting chooses ALL or ARKG, and matching dates receive green buy labels below the bar or red sell labels above it, each marked X1. It does not calculat

Indicator v4
Updated 2 years ago · None stated GitHub repository of TMO-tracker
106 stars

This strategy evaluates trade entries by combining Stochastic RSI crossovers with MACD momentum and three exponential moving averages (8, 15, and 50 EMAs). Positions are filtered by directional alignment across indicators and date ranges. Exits are managed via

Strategy v4 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Stoch RSI Crossover Strat + EMA

TTM Scalper Alert

by mihakralj
99 stars

TTM Scalper Alert marks three-bar pivot highs and lows on the price chart. It treats the prior bar as a pivot high when its high exceeds both neighboring highs, and as a pivot low when its low is below both neighboring lows. An optional setting uses closes ins

Indicator v6 Support & resistanceScalping Repaints
Updated 4 weeks ago · Apache-2.0 GitHub repository of TTM Scalper Alert

Session Isfirstbar VWAP Anchor

by pineforge-4pass
1 stars

A test strategy from a reference corpus that builds a VWAP restarted on the first bar of each trading session, using typical price times volume during market hours. It buys one unit when the close crosses above this session VWAP and closes the long when the cl

Strategy v6 Sessions & timeSupport & resistance
Updated 6 days ago · Apache-2.0 GitHub repository of Session Isfirstbar VWAP Anchor

TOST-tracker

by Allen1212
303 stars

This overlay indicator marks historical ARK Invest buy and sell dates for Toast on the price chart. When the ETF input is ALL, it places green labels below bars for buys and red labels above bars for sells, each reading X1. The ETF setting offers ALL, ARKF, an

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

Stochastic

by hasnocool
106 stars

This strategy combines a smoothed stochastic oscillator with three exponential moving averages. It opens a long position of 1000 units when the stochastic K line crosses above D and the 5-period and 15-period EMAs both cross above the 50-period EMA. It closes

Strategy v4 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Stochastic

TTM Trend

by mihakralj
99 stars

TTM Trend plots an exponential moving average of a chosen source on the price chart and colors the line by the direction of its one-bar change. A positive change is green, a negative change is red, and an unchanged value is gray. Optional bands scale with the

Indicator v6 TrendMoving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of TTM Trend

MyVIXFIX

by g-moe
3 stars

MyVIXFIX calculates the Williams Vix Fix as the percentage distance from the highest close over a lookback to the current low. It plots that reading as histogram columns in a separate pane. Columns turn red when the value reaches the upper Bollinger band or an

Indicator v5 Volatility & bands
Updated 5 months ago · None stated GitHub repository of MyVIXFIX

Session islastbar flatten

by pineforge-4pass
1 stars

This strategy enters long positions when a 9-period Simple Moving Average (SMA) crosses above a 21-period SMA during active market session hours. To avoid holding positions overnight, it automatically exits all open trades on the final bar of the session using

Strategy v6 Moving averagesSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of Session islastbar flatten

TREE-tracker

by Allen1212
303 stars

TREE-tracker visualizes historical buy and sell trades made by ARK Invest funds directly on the main price chart. It projects static historical transaction records across specific timestamps and plots labels below or above price bars to indicate transaction ac

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

This strategy demonstrates how to place and cancel pending stop orders with syntax formatted for MT4 and MT5 webhook bridges. It generates entries using a smoothed Stochastic oscillator crossover and crossunder. Stop orders are placed at a configurable tick di

Strategy v4 Oscillators & momentumSupport & resistance
Updated 2 years ago · GPL-3.0 GitHub repository of TradingView Alerts to MT4 MT5 example with cancelling pending orders

TTM Wave

by mihakralj
99 stars

This indicator plots six MACD histogram channels from exponential moving averages. Fast period is eight and the signal period equals each Fibonacci slow period: 34, 55, 89, 144, 233, and 377. Wave A shows short-term momentum, Wave B medium-term, and Wave C lon

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of TTM Wave
3 stars

This overlay indicator builds a volume profile from a chosen number of recent bars and splits the price range into rows. It draws a horizontal volume histogram on the price chart, highlights the point of control, and can optionally show a rolling point of cont

Indicator v5 VolumeSupport & resistance
Updated 5 months ago · None stated GitHub repository of myVolume Profile [LUX]

Session Ismarket NYSE RTH Gate

by pineforge-4pass
1 stars

A test strategy from a reference corpus that only trades during regular market hours as reported by the session variable. Within those hours it buys one unit when a 9-period simple moving average crosses above a 21-period one and closes the long on the opposit

Strategy v6 Moving averagesSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of Session Ismarket NYSE RTH Gate

TRMB-tracker

by Allen1212
303 stars

The TRMB-tracker indicator plots labels directly on the TRMB stock price chart to mark ARK Invest buy and sell trades. It displays specific dates with "Buy X1" or "Sell X1" text in green and red colors. The input setting selects an ETF type from ARKK, ARKQ, AR

Indicator v4 Support & resistance
Updated 2 years ago · None stated GitHub repository of TRMB-tracker

Triple EMA Scalper

by hasnocool
106 stars

This strategy plots three moving averages on the price chart, although the calculations use simple moving averages despite the EMA title. It enters long when the fastest average crosses above the other two and short when it crosses below them, limited to the L

Strategy v4 Moving averagesScalping
Updated 2 years ago · GPL-3.0 GitHub repository of Triple EMA Scalper

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