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

Self-Aware Trend System

by vedkanani123
1 stars

An adaptive trend indicator on the price chart. It draws ATR bands whose width reacts to an efficiency-based trend quality index that blends efficiency, volatility regime, structure and momentum persistence. Options include asymmetric bands, an efficiency-weig

Indicator v6 TrendVolatility & bands
Updated 2 months ago · None stated GitHub repository of Self-Aware Trend System

KC Combo Bull v4.7.1

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.1
1 stars

This strategy identifies breakouts from session highs and lows on the price chart. It tracks the current session high and low for the configured time window in the specified timezone. Price crosses above the prior session high with an upward EMA trend confirm

Strategy v6 Sessions & timeBreakout
Updated 2 months ago · None stated GitHub repository of Tn Sovereign Session Quant v6
1 stars

This indicator builds a Detrended Rhythm Oscillator in a separate pane. It uses a detrended price oscillator with fast and slow lengths to find zig-zag swings, then draws dashed or dotted lines and labels showing the bar distance between successive highs. The

Indicator v4 Oscillators & momentum
Updated 6 months ago · None stated GitHub repository of Detrended Rhythm Oscillator Peak
1 stars

An educational Pine Script v4 indicator that demonstrates how higher timeframe requests behave with each combination of the gaps and lookahead settings of security(). It draws lines for the current and previous higher timeframe value on the price chart, with l

Indicator v4 Repaints
Updated 1 year ago · None stated GitHub repository of Avoid Repainting With security()

GLBE-tracker

by Allen1212
303 stars

This indicator marks historical ARK Invest purchases and sales of GLBE on the price chart. Green labels sit below bars for buys and red labels sit above bars for sells, each showing a same-day ETF count such as X1. An ETF setting switches between all recorded

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

Test 014 Array Functions

by ricardosantos79
261 stars

This script is a technical demonstration of custom array manipulation functions in Pine Script v4. It identifies pivot highs and pivot lows and dynamically manages their values and corresponding bar indices inside fixed-size float and integer arrays. It also d

Indicator v4 Support & resistance
Updated 4 years ago · None stated GitHub repository of Test 014 Array Functions

Filtered Stoch

by hasnocool
106 stars

Filtered Stoch is a long-only strategy that combines a Stochastic RSI oscillator with a trend filter based on the highest EMA of price highs. A bullish trend state is identified when close prices trade above the EMA filter level. The strategy enters a long pos

Strategy v5 Oscillators & momentumTrend
Updated 2 years ago · GPL-3.0 GitHub repository of Filtered Stoch

This indicator calculates the Cumulative Distribution Function (CDF) of an exponential distribution applied to a price series. It normalizes source values into a zero-to-one range using a min-max window over a specified lookback period, then computes the expon

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Exponential Distribution CDF (EXPDIST)

My Script

by be-thomas
65 stars

This indicator demonstrates how the history-referencing operator behaves inside user-defined functions versus a direct series reference. It plots the previous close returned by a function argument and by a function that reads close, but only on every other bar

Indicator v4
Updated 5 days ago · GPL-3.0 GitHub repository of My Script

Relative Volatility Index

by TWODS-CAPITAL
37 stars

This indicator plots the Relative Volatility Index in a separate pane. It measures the standard deviation of the close and splits that volatility into upward and downward price changes, then smooths each side with a fixed 14-period exponential moving average a

Indicator v5 Volatility & bandsOscillators & momentum
Updated 3 years ago · MIT GitHub repository of Relative Volatility Index

Sergdi D002

by ruckard
13 stars

This strategy detects trend reversals on the 4H timeframe using ADX crossover signals. Long entries occur when +DI crosses above -DI, and short entries when +DI crosses below -DI. Built-in risk management includes ATR-based stop loss, optional take profit, tra

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

Combines an upgraded WaveTrend oscillator engine with market structure swing pivots, volume profile point of control (POC), and multi-timeframe trend alignment scoring. Trades are triggered by WaveTrend reversal or pullback continuation signals that pass conte

Strategy v6 Oscillators & momentumTrend
Updated 2 days ago · MIT GitHub repository of WaveTrend v3 [WavesUnchained] — Strategy

Cyberpunk MACD Pulse Engine

by eddiebelaval
7 stars

The Cyberpunk MACD Pulse Engine is a momentum indicator displayed in a separate pane. It calculates MACD line, signal line, and histogram values using configurable parameters or preset modes tailored for scalping, swing trading, and custom setups. The indicato

Indicator v5 Oscillators & momentumDivergence
Updated 3 months ago · None stated GitHub repository of Cyberpunk MACD Pulse Engine
6 stars

MSNR Ultimate detects and plots horizontal support and resistance structures directly on the price chart. It combines swing apex and valley (A/V) pivot levels, gap detection, and Qualified Move (QM) levels. Users can filter levels to display only fresh, unmiti

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

This indicator calculates a TTM-style squeeze by comparing Bollinger Bands with Keltner Channels alongside a linear regression momentum oscillator. It measures volatility compression when Bollinger Bands contract within the Keltner Channels and tracks the dura

Indicator v5 Oscillators & momentumVolatility & bands
Updated 5 months ago · None stated GitHub repository of Linear Regression

Financials on Chart

by regalouisei
2 stars

Financials on Chart displays fundamental company financial metrics in a tabular overlay directly on the price chart. It retrieves statement items such as income statement and balance sheet data across reporting periods including fiscal year, financial quarter,

Indicator v5 Screeners & dashboards
Updated 8 months ago · None stated GitHub repository of Financials on Chart
1 stars

A test strategy from a reference corpus that sends two market entry calls with the same order id on the same bar, to see whether they merge or stack. It does this long at 00:15 and closes at 01:15, then short at 12:15 and closes at 13:15. Pyramiding is set to

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 64 Same Id Market Repeat

Live Tick Counter

by morindok
1 stars

Live Tick Counter tracks up and down ticks on each price movement while weighting them against volume. It calculates a cumulative probability of upward movement by combining tick counts and volume totals from the last lookback bars plus the current bar. The in

Indicator v5 Volume Repaints
Updated 7 weeks ago · None stated GitHub repository of Live Tick Counter
1 stars

A session-based swing structure indicator drawn on the price chart. For three configurable sessions, by default Asian, London and New York, it finds the highest and lowest pivots and labels them HH or LH and HL or LL. It then draws one Fibonacci or standard-de

Indicator v6 Sessions & timeSupport & resistance
Updated 2 months ago · None stated GitHub repository of Session 2 Swings HH HL LL LH + SD v3

KC Combo SR Ext Tick

by nishpa800
1 stars

Tick-chart extension study for a Keltner Channel combo indicator, carrying eighteen extra bullish and bearish markers on the price chart. They combine PB, RS and RC members with relative volume or Grand Slam and MOAB tiers, and high-volume ranks from 500 to 49

Indicator v5 Volatility & bandsVolume
Updated 2 months ago · None stated GitHub repository of KC Combo SR Ext Tick

Tn Sovereign SMC v6

by raybird
1 stars

Tn Sovereign SMC v6 is a Smart Money Concepts strategy that overlays trade entries and an status HUD table directly on the price chart. It identifies liquidity sweeps by checking if price pierces recent swing highs or lows before closing back within range, fil

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

This indicator builds a Detrended Rhythm Oscillator in a separate pane. It uses a detrended price oscillator with fast and slow lengths to find zig-zag swings, then draws dashed or dotted lines and labels showing the bar distance between successive lows. The a

Indicator v4 Oscillators & momentum
Updated 6 months ago · None stated GitHub repository of Detrended Rhythm Oscillator Trough

GLEO Tracker

by Allen1212
303 stars

GLEO Tracker overlays historical ARK Invest buy and sell transactions directly onto the main price chart. It uses hardcoded transaction records to place green labels below price bars for buys and red labels above price bars for sells on specific trading dates.

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

Test 019 Tuple Security

by ricardosantos79
261 stars

This script plots multi-timeframe OHLC candlesticks in a separate chart pane using tuple security data fetching. It extracts open, high, low, and close prices from a user-specified timeframe, defaulting to Monthly, using a tuple-returning function. Traded valu

Indicator v4 Candlestick patterns Repaints
Updated 4 years ago · None stated GitHub repository of Test 019 Tuple Security

John Day Stop Loss

by hasnocool
106 stars

This long-only Pine v5 strategy plots RSI, Money Flow Index, Stochastic RSI, and a MACD calculation in a separate pane. Visible buy logic requires Money Flow below a maximum and a Stochastic RSI K-line cross above D while below the oversold band; the matching

Strategy v5 Oscillators & momentumVolume
Updated 2 years ago · GPL-3.0 GitHub repository of John Day Stop Loss
99 stars

The Exponential Transformation indicator applies the natural exponential function y = e^x to the input source series. The transformed series is plotted as a line in a separate pane. The main setting allows selecting the input source with close as default. This

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Exponential Transformation (EXP)

My Script

by be-thomas
65 stars

This overlay indicator draws a single text label above the price bar. On the first bar it creates a persistent label with the fixed text Colored label, then each bar it moves that same label to the current bar index and colors it with the user-chosen main colo

Indicator v4
Updated 5 days ago · GPL-3.0 GitHub repository of My Script
37 stars

This overlay indicator detects the bullish Rising Three Methods continuation pattern on the price chart. It looks for a long white candle, three small black candles whose bodies stay inside the first candle’s range, and a long white candle that closes above th

Indicator v5 Candlestick patternsTrend Repaints
Updated 3 years ago · MIT GitHub repository of Rising Three Methods - Bullish

Sergdi E002

by ruckard
13 stars

Sergdi E002 is a directional trading strategy based on higher-timeframe Directional Movement Index crossovers. It enters long when the 4-hour DI+ crosses above DI- and short when DI+ crosses below DI-. The strategy features extensive risk management options in

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

The WaveTrend v4 Strategy generates trading signals when the WaveTrend oscillator crosses at oversold or overbought levels. Long positions enter on bullish crosses in oversold territory, while short positions enter on bearish crosses in overbought territory. I

Strategy v6 Oscillators & momentumTrend Repaints
Updated 2 days ago · MIT GitHub repository of WaveTrend v4 [WavesUnchained] Strategy
6 stars

NY SMC Suite Multi-Killzone is a Smart Money Concepts indicator that plots session killzones and structural supply and demand zones directly on the price chart. It identifies Order Blocks, Fair Value Gaps, Change in State of Delivery levels, and wick rejection

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of NY SMC Suite Multi-Killzone

This indicator plots linear regression bands on the price chart for multiple timeframes. It calculates regression lines with standard deviation bands for up to three timeframes, each configurable with length, deviation, color, width, and background transparenc

Indicator v5 TrendVolatility & bands
Updated 5 months ago · None stated GitHub repository of Linear Regression MTF + Bands

This indicator fits a trigonometric series to historical prices and projects future price movement directly on the price chart. Using the Quinn and Fernandes algorithm alongside least-squares fitting, it identifies dominant cycle frequencies across a user-defi

Indicator v5 Trend
Updated 8 months ago · None stated GitHub repository of Fourier Extrapolator of Price w/ Projection Forecast [Loxx]
1 stars

This strategy acts as an engine execution validation probe designed to test how same-pass, same-identifier entries and exits are processed within the same bar. It triggers fixed long and short position entries at specific intraday times, followed by simultaneo

Strategy v6
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 65 - Same ID Entry Close

Live Tick Counter

by morindok
1 stars

Live Tick Counter tracks real-time upward and downward tick price movements on active candles using intrabar variable updates. It accumulates directional tick statistics during live market execution and calculates directional probabilities over a customizable

Indicator v5 Volume Repaints
Updated 7 weeks ago · None stated GitHub repository of Live Tick Counter

KC Combo SR EXT v1.0

by nishpa800
1 stars

Combines bullish and bearish signals in one price chart overlay, built on a Keltner Channel, an ATR supertrend and several volume and displacement detectors. Markers flag candles where those detectors line up with a support or resistance structure. This extens

Indicator v5 Support & resistanceVolume
Updated 2 months ago · None stated GitHub repository of KC Combo SR EXT v1.0

Tn Sovereign STC v6

by raybird
1 stars

Tn Sovereign STC v6 is an overlay strategy that combines the Schaff Trend Cycle oscillator with a 200-period Exponential Moving Average trend filter. It triggers long entries when the Schaff Trend Cycle crosses above the oversold boundary during a general uptr

Strategy v6 Oscillators & momentumTrend
Updated 2 months ago · None stated GitHub repository of Tn Sovereign STC v6

Rakesh Level

by mikeyhu70
1 stars

A Pine Script v4 indicator, credited to LonesomeTheBlue, that draws a set of manually entered horizontal levels on the price chart, ten above and ten below, labelled as seller and buyer levels. The default prices are fixed numbers for ES or NQ futures, chosen

Indicator v4 Support & resistance
Updated 6 months ago · None stated GitHub repository of Rakesh Level

security() Revisited

by ivansoft
1 stars

An educational Pine Script v4 indicator that shows reliable higher timeframe requests with a choice of repainting or non-repainting output. It plots a plain repainting request for reference, a single-call helper function that switches repainting on or off, a t

Indicator v4 Repaints
Updated 1 year ago · None stated GitHub repository of security() Revisited

GLMD-tracker

by Allen1212
303 stars

GLMD-tracker overlays dated ARK Invest trade labels on the GLMD price chart. The visible code places red downward labels above bars on specific calendar dates, each marked as a sell with a count of one. An ETF setting is present but only offers ALL, so it does

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

Test 022 Copy

by ricardosantos79
261 stars

This test indicator demonstrates Pine Script v4 array operations and array copying behavior. It initializes two integer arrays, updates the primary array elements using a loop structure on every bar, and creates a duplicate array using array.copy(). The script

Indicator v4
Updated 4 years ago · None stated GitHub repository of Test 022 Copy

Mov Avg Speed Strategy

by hasnocool
106 stars

This strategy evaluates market trend and momentum by combining moving average rate of change, Stochastic Oscillator levels, and MACD signal line directions on the main chart overlay. It calculates a directional signal from each of the three indicators and requ

Strategy v5 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Mov Avg Speed Strategy
99 stars

Calculates the Cumulative Distribution Function (CDF) of an F-distribution for a normalized price series. It normalizes the source input over a configurable lookback period using min-max scaling, then computes the CDF values bounded between zero and one via La

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of F-Distribution CDF (FDIST)

My Script

by be-thomas
65 stars

This indicator stores the difference between close and open for the current bar and the five preceding bars in a float array. It then plots the value at array index four, which is the close-minus-open difference from four bars ago. The study draws that single

Indicator v4 Candlestick patterns
Updated 5 days ago · GPL-3.0 GitHub repository of My Script

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