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

This Pine Script indicator shades the chart background with varying transparency based on the day of the week. It evaluates the current bar's day of the week from Monday through Friday, applying a navy color with a distinct transparency percentage for each wee

Indicator v4 Sessions & time
Updated 5 days ago · GPL-3.0 GitHub repository of Shading the Chart's Background
3 stars

My Historical Volatility plots annualized historical volatility in a separate pane. It measures the standard deviation of logarithmic close-to-close returns over a user-set length, scales that value by 100, and annualizes it with a factor that uses 365 days an

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

RedK Momentum Bars

by regalouisei
2 stars

Calculates and plots momentum bars in a separate pane using three moving averages: a fast MA, a slow MA with a delay setting, and a trend filter MA. Loosely inspired by the Elder Impulse system, it measures momentum relative to a zero filter line. Users can cu

Indicator v5 Oscillators & momentumMoving averages
Updated 8 months ago · None stated GitHub repository of RedK Momentum Bars
1 stars

This strategy combines a three-tier EMA stack, RSI momentum filtering, and channel breakout rules to generate trend-following entries on the price chart. It detects swing highs and swing lows to draw connecting trend lines across pivot points. Entries trigger

Strategy v6 TrendMoving averages
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe Trendmaster Integration

This indicator calculates a staircase trailing trend line based on recent highest highs and lowest lows over a customizable lookback period. It plots a step-line directly on the price chart, changing color between green for uptrends and red for downtrends. It

Indicator v5 TrendSupport & resistance Repaints

VOB v11.9 Tick

by nishpa800
1 stars

Detects volume order block zones from six pairs of moving averages at different sensitivity lengths and draws them on the price chart. It marks combined events such as strict ladder patterns across the six tiers, multi-zone coincidences on one candle, tier clu

Indicator v5 SMC / ICT / price actionVolume
Updated 2 months ago · None stated GitHub repository of VOB v11.9 Tick

MNDY-tracker

by Allen1212
303 stars

This indicator plots historical ARK Invest buy and sell labels for MNDY on the price chart. Green labels sit below bars for buys and red labels sit above bars for sells, each marked X1 for the number of ETFs trading that day. An ETF setting switches between al

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

This overlay strategy builds two moving averages from a selectable EMA, WMA, or SMA and plots the faster one on the price chart. A buy signal is a crossover of the fast average above the slow average, and a sell signal is the opposite cross. It colors the aver

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Arch1tect's New Toy (Strategy Tester Version)
99 stars

This indicator plots Mean Absolute Scaled Error between a selected price source and an exponential moving average of that source. Absolute differences are divided by a scale equal to the mean absolute bar-to-bar change of the source, computed once from the fir

Indicator v6 Moving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of Mean Absolute Scaled Error (MASE)
65 stars

Calculates pivot high points based on user-defined left and right leg lengths and displays up to a specified number of recent pivot high labels on the main chart pane. It utilizes an array queue to track active label IDs, automatically deleting older labels wh

Indicator v4 Support & resistance
Updated 5 days ago · GPL-3.0 GitHub repository of Show Last n High Pivots
3 stars

This indicator calculates a scaled Chande Momentum Oscillator based on the hlc3 price source and displays it in a separate pane. It computes positive and negative price changes over a user-defined length, scales the resulting percentage with a multiplier, and

Indicator v5 Oscillators & momentum
Updated 5 months ago · None stated GitHub repository of My Matrix Momentum
2 stars

This indicator tracks custom multi-asset portfolio performance directly on the price chart using a clean dashboard table. It fetches live prices and dividend data for configured asset positions, calculating individual position values, total cost basis, and unr

Indicator v5 Screeners & dashboards
Updated 8 months ago · None stated GitHub repository of RedK Portfolio Tracker Table Version
1 stars

PF Probe Trendmaster Trend Line Projection is a Pine Script strategy designed to evaluate trend line projections and slope math. It identifies swing pivot highs and lows using a configurable pivot strength setting and draws trend lines directly on the price ch

Strategy v6 TrendSupport & resistance
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe Trendmaster Trend Line Projection

Super Mirror

by morindok
1 stars

Super Mirror indicator plots multiple symmetric and reflected price lines directly on the price chart. It computes a moving average whose length varies based on the time interval between start and end times, then creates mirrored versions at two user-defined p

Indicator v5 Oscillators & momentumSupport & resistance
Updated 7 weeks ago · None stated GitHub repository of Super Mirror
1 stars

TnSovereignVwapRegimeV6 is a mean-reversion strategy designed to trade price exhaustion away from the volume-weighted average price (VWAP). It calculates standard deviation bands around a session VWAP and tracks price deviation in normalized standard deviation

Strategy v6 Mean reversionVolatility & bands
Updated 2 months ago · None stated GitHub repository of TnSovereignVwapRegimeV6

Mrna-tracker

by Allen1212
303 stars

This indicator visualizes historical purchase and sale transactions made by ARK Invest on the price chart. It plots buy and sell labels corresponding to specific dates when shares were acquired or disposed of by specific exchange-traded funds. The main input s

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

This strategy calculates the Aroon Oscillator along with the Relative Strength Index (RSI) to generate long trading signals. It opens an initial long position when the Aroon Oscillator crosses above the zero line, and pyramids into the position if price dips b

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

Simple label

by be-thomas
65 stars

This indicator places a label on the price chart for every bar. Each label sits at the bar index and the bar high, and its text is the chart symbol ticker. The study overlays the price rather than using a separate pane. It does not calculate an oscillator, mov

Indicator v4
Updated 5 days ago · GPL-3.0 GitHub repository of Simple label

My QQE

by g-moe
3 stars

Calculates dual Quantitative Qualitative Estimation (QQE) oscillators paired with Bollinger Bands in a separate pane. It computes smoothed Relative Strength Index (RSI) values and tracks dynamic volatility bands based on Wilder-smoothed ATR of the RSI. A set o

Indicator v5 Oscillators & momentumVolatility & bands
Updated 5 months ago · None stated GitHub repository of My QQE
2 stars

This indicator estimates how much of each bar's volume is demand versus supply by weighting volume with the candle body and wick geometry. It double-smooths those shares with weighted moving averages and plots net volume as a colored area in a separate pane. S

Indicator v5 Volume
Updated 8 months ago · None stated GitHub repository of RedK Supply/Demand Volume Viewer
1 stars

This strategy tracks a three-tier exponential moving average (EMA) stack to identify trend alignment regimes. It defines a bullish state when fast EMA is above mid and mid is above slow, and a bearish state when inverted. Orders execute strictly on state trans

Strategy v6 TrendMoving averages
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe trendmaster-probe-02-multi-tier-ma
1 stars

Calculates the classic WaveTrend oscillator using exponential moving averages and absolute deviations of typical price. Entries trigger on momentum reversals across timeframe-specific overbought and oversold thresholds, filtered through configurable quality ga

Strategy v6 Oscillators & momentumMean reversion
Updated 2 months ago · None stated GitHub repository of TnSovereignWaveTrendV4

MSFT-tracker

by Allen1212
303 stars

This indicator visualizes historical purchases and sales made by ARK Invest in Microsoft directly on the price chart. It plots green buy labels below bars and red sell labels above bars at hardcoded transaction timestamps. The main setting filters trades by sp

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

The Aroon Strategy Long Only is a trend-following strategy that combines the Aroon indicator with a Least Squares Moving Average filter. It enters long positions when the Aroon Up line crosses above the Aroon Down line while the closing price trades above the

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

Mean Deviation

by mihakralj
99 stars

This indicator calculates the mean absolute deviation of a chosen source from its mean over a lookback period. A circular buffer keeps a running sum, then averages the absolute distance of each stored value from that mean. It plots the result as a line in a se

Indicator v6 Volatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Mean Deviation

Single Conditions

by be-thomas
65 stars

This educational indicator calculates a 20-period Relative Strength Index (RSI) to demonstrate various visual debugging techniques in Pine Script. When the RSI falls below the 30 threshold, it illustrates six different signal visualization methods: dynamically

Indicator v4 Oscillators & momentum
Updated 5 days ago · GPL-3.0 GitHub repository of Single Conditions

My Strategy

by g-moe
3 stars

This strategy calculates the average closing price from a lower 3-minute timeframe and plots the result in a separate pane using array sum on multi-bar aggregate data. It fetches lower-timeframe data via security lower tf and includes commented out crossover c

Strategy v5 Moving averages
Updated 5 months ago · None stated GitHub repository of My Strategy
2 stars

Calculates buying and selling pressure by evaluating high and low movements relative to a two-bar price range. Bull and bear pressures are averaged using weighted moving averages with optional pre-smoothing, and net pressure is derived through an additional sm

Indicator v5 Oscillators & momentumTrend
Updated 8 months ago · None stated GitHub repository of RedK Trader Pressure Index (TPX)
1 stars

This strategy detects long and short signals using a fast EMA crossing above or below a slow EMA. Entries only trigger when a recent pivot exists for anchoring. Long entries place a stop loss at the last pivot low and a take profit at 2R distance using the ent

Strategy v6 TrendMoving averages
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe trendmaster-probe-03-pivot-tp-sl
1 stars

Takes two user-chosen anchor points of time and price, adds an optional sloped angle scaled per bar, and computes a simple moving average whose length equals the number of bars between the anchors. It detrends the sloped levels and the average, builds mirrored

Indicator v5 Support & resistance
Updated 7 weeks ago · None stated GitHub repository of Super Mirror - Signals Only

MTRX-tracker

by Allen1212
303 stars

MTRX-tracker visualizes historical ARK Invest trade activity for Matrix Service Co on the price chart. The script generates chart labels at specific historical timestamps indicating when ARK funds purchased or sold shares, along with transaction counts across

Indicator v4 Screeners & dashboards
Updated 2 years ago · None stated GitHub repository of MTRX-tracker

ARR VWAP Intraday

by hasnocool
106 stars

This strategy plots VWAP on the price chart and trades only between a start hour and an end hour. It enters long when VWAP is rising and RSI is above a threshold, and short when VWAP is falling and RSI is below a threshold. If the reversal option is on, it clo

Strategy v4 Oscillators & momentumVolume Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of ARR VWAP Intraday

Mean Error (ME)

by mihakralj
99 stars

This indicator calculates the mean error between a selected price source and an exponential moving average of that source. It subtracts the EMA from the source, then averages those errors over a user-defined lookback with a circular buffer that behaves like a

Indicator v6 Moving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of Mean Error (ME)
65 stars

This strategy calculates a 20-period Relative Strength Index (RSI) and generates entry orders based on crossovers and crossunders of the 50 level. When RSI crosses above 50, it places a long stop entry at the current high price with a custom alert message. Whe

Strategy v4 Oscillators & momentum
Updated 5 days ago · GPL-3.0 GitHub repository of Strategy Using Alert Message

This overlay indicator plots automatic Midas-style anchored VWAPs on the price chart. It finds the bars of the highest high and lowest low inside a user-set length, then builds volume-weighted averages of high or low and of the HLC3 midpoint back to those bars

Indicator v5 VolumeTrend
Updated 5 months ago · None stated GitHub repository of Nubia - Auto Midas Anchored VWAP [xdecow]

RedK Volume-Accelerated Directional Energy Ratio (VADER) measures directional momentum accelerated by volume activity. It calculates price change relative to the average bar range, limits the ratio, and scales it using relative, raw, or static volume weighting

Indicator v5 VolumeOscillators & momentum
Updated 8 months ago · None stated GitHub repository of RedK Volume-Accelerated Directional Energy Ratio

This strategy evaluates a triple-confluence entry gate combining trend, momentum, and structure filters on the price chart. It enters long when a fast exponential moving average is above a slow exponential moving average, RSI exceeds a defined threshold, and t

Strategy v6 TrendOscillators & momentum
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe Trendmaster-Probe-04 Trend Entry Gate
1 stars

Super Mirror By BITMOON618 is an overlay indicator on the TradingView price chart. It calculates mirrored price levels based on user-defined price1 and price2, and a moving average of close. The indicator monitors price movements within a specified time range

Indicator v5 Support & resistanceSessions & time
Updated 7 weeks ago · None stated GitHub repository of Super Mirror By BITMOON618
1 stars

This strategy identifies volatility compression and corridor breakouts on the price chart. It detects squeeze conditions where Bollinger Bands compress inside Keltner Channels, combined with Donchian Channel range boundaries. Long trades trigger on an upward s

Strategy v6 Volatility & bandsBreakout
Updated 2 months ago · None stated GitHub repository of Zzc Corridor Sovereign v6

MTTR-tracker

by Allen1212
303 stars

Plots historical buy and sell transactions executed by ARK Invest (specifically ARKQ) for Matterport Inc (MTTR) directly on the price chart. It places green upward labels below bars on buy dates and red downward labels above bars on sell dates, noting the tran

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

An intraday trading strategy that calculates daily pivot points, support and resistance levels, previous day high/low, and typical price. Designed around specific trading sessions like Indian market hours (09:15 to 15:30), it draws key reference levels directl

Strategy v4 Support & resistanceSessions & time Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of ARR-Pivote-India-Stategy
99 stars

The Mean Relative Absolute Error indicator measures forecast accuracy by comparing an actual price series against a predicted price series. For each bar, it divides the absolute difference between actual and predicted values by the absolute actual value, then

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Mean Relative Absolute Error
65 stars

This Pine Script strategy generates trading signals using a 20-period Relative Strength Index (RSI) relative to the 50 level. It enters a long position when the RSI crosses above 50 and a short position when it crosses below 50. While in an active trade, the s

Strategy v4 Oscillators & momentum
Updated 5 days ago · GPL-3.0 GitHub repository of Strategy with Selective Alert Calls

Opening Range

by g-moe
3 stars

The Opening Range indicator combines multiple technical analysis tools onto the main price chart. It calculates MACD momentum sequences alongside Stochastic oscillator limits to generate buy and sell triangle shapes. Additionally, it evaluates trend alignment

Indicator v5 TrendOscillators & momentum Repaints
Updated 5 months ago · None stated GitHub repository of Opening Range

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