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

This strategy draws on the price chart and combines optional long and short signals from a 9/21 EMA crossover, a breakout of the prior 20-bar high or low, RSI momentum, and a MACD histogram flip. A toggleable 200-period simple moving average allows longs only

Strategy v6 TrendOscillators & momentum Repaints
Updated 2 months ago · None stated GitHub repository of TN Asymmetric Swing Sovereign

GrimmArty

by GreyssonEnterprises
1 stars

A Pine v4 indicator that draws four smoothed moving averages (21, 50, 100 and 200) with a trend fill, marks bullish and bearish three line strike patterns with triangles, and adds large engulfing-style candle markers. It can also shade a time-zone trading sess

Indicator v4 Moving averagesCandlestick patterns
Updated 2 months ago · MIT GitHub repository of GrimmArty
1 stars

The strategy combines the Moving Average Convergence Divergence (MACD) oscillator with Bollinger Bands to generate trading signals on the main price chart. A long signal occurs when the MACD line crosses above its signal line while the closing price is above t

Strategy v5 TrendOscillators & momentum
Updated 4 months ago · MIT GitHub repository of Tuple Visual MACD BB

A Pine Script v5 indicator in a separate pane that applies Hurst-style bandpass filters to a chosen price source, such as the low, to mark cycle pivots from the 5 day to the 40 day range. Each cycle has its own bandwidth and period, and a bandpass offset, cycl

Indicator v5 Oscillators & momentumSupport & resistance
Updated 6 months ago · None stated GitHub repository of Hurst Diamond Notation Pivots 5D to 40D

Range Scalper

by knectardev
1 stars

The Range Scalper indicator identifies support and resistance levels to help traders spot range-bound price action. It calculates pivot highs and pivot lows using a user-defined pivot length parameter. The resistance levels plot in red and support levels plot

Indicator v5 Support & resistanceScalping
Updated 9 months ago · None stated GitHub repository of Range Scalper
1 stars

This overlay indicator calculates LazyBear's WaveTrend oscillator as modified by DGT. It smooths price with an EMA channel, builds a channel index from absolute deviation, then plots a WaveTrend line and a shorter signal average. It marks crosses, optional val

Indicator v5 Oscillators & momentum
Updated 9 months ago · None stated GitHub repository of WaveTrend [LazyBear] by DGT
1 stars

Draws a linear regression line over the last chosen number of bars on the price chart, with upper and lower channel lines offset by a standard deviation multiple or by the largest deviation of highs and lows. Inputs set length, source, deviation multipliers, l

Indicator v6 TrendSupport & resistance
Updated 1 year ago · None stated GitHub repository of Linear Regression Channel

VWAP Distance

by nvFede
1 stars

A Pine v4 indicator in a separate pane that shows how far the close is from a daily-reset volume-weighted average price. It rebuilds VWAP from the chosen source, typical price by default, restarting each day, then plots the close divided by VWAP minus one, so

Indicator v4 VolumeMean reversion
Updated 3 years ago · None stated GitHub repository of VWAP Distance

STDDEV Filter

by JohnsonHsiao
1 stars

This indicator compares two rolling standard deviations of the closing price and plots their difference as a histogram in a separate pane. The shorter-period standard deviation uses a default length of 20 and the longer one uses 50. The histogram is blue when

Indicator v5 Volatility & bands
Updated 3 years ago · None stated GitHub repository of STDDEV Filter
1 stars

The MACD Fast W Shorts Add Long strategy generates trading signals using a standard Moving Average Convergence Divergence (12, 26, 9) calculation and VWAP filtering. It enters long trades when MACD is below zero, rising, and under the signal line, or reopens a

Strategy v4 TrendOscillators & momentum
Updated 4 years ago · None stated GitHub repository of MACD Fast W Shorts Add Long

The Finite Impulse Response (FIR) Filter is a smoothed technical indicator plotted directly on the main price chart. It calculates a weighted moving average using seven configurable coefficient inputs applied to current and historical price values. The filter

Indicator v4 Moving averagesTrend
Updated 11 days ago · GPL-3.0 GitHub repository of Finite Impulse Response (FIR) Filter
330 stars

This indicator monitors multiple cryptocurrency symbols for trading signals. It calculates and plots entry prices, take profit, and stop loss levels for each symbol including BTCUSDT, ETHUSDT, BNBUSDT and others. Price crossovers trigger buy, sell or close ale

Indicator v5 Support & resistanceScreeners & dashboards
Updated 2 months ago · None stated GitHub repository of Multi Alert Long/Short [Alorse]

ANSS Tracker

by Allen1212
303 stars

Plots historical buy and sell trades executed by ARK Invest for ANSS stock directly on the price chart. It uses fixed historical timestamps to generate labels indicating buy or sell events along with the count of participating ARK funds on specific dates. User

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

FunctionLinearRegression

by ricardosantos79
261 stars

This Pine Script v5 library provides functions to calculate and plot linear regression channels using sample point arrays. It evaluates paired X and Y arrays to calculate the regression slope, intercept, fitted values, maximum deviation, minimum deviation, and

Library v5 Trend
Updated 4 years ago · None stated GitHub repository of FunctionLinearRegression
257 stars

This overlay indicator rebuilds a synthetic candle from the current open and the previous three opens. It treats the highest and lowest of those earlier opens as the range, the prior open as the synthetic open, and the current open as the synthetic close. From

Indicator v5 TrendCandlestick patterns
Updated 6 weeks ago · None stated GitHub repository of Snag - Best Futures Color Trend

Midnight VWAP

by TradersPost
218 stars

The Midnight VWAP indicator calculates and overlays two distinct Volume Weighted Average Price (VWAP) lines on the price chart based on customizable session timeframes. It tracks an overnight or pre-market session alongside regular trading hours, resetting cal

Indicator v6 Moving averagesSessions & time
Updated 3 months ago · None stated GitHub repository of Midnight VWAP

This indicator combines a dynamic Seasonal Random Index (SRI) with a dynamic Karobein Oscillator and a pattern-similarity search algorithm in a separate pane. It normalizes SRI into seasoned and deseasoned series, shading the area green or red to signal trend

Indicator v4 Oscillators & momentumTrend
Updated 1 year ago · None stated GitHub repository of Similarity Search, Karobein and Seasonal Random Index

This indicator plots an oscillator in a separate pane. It builds several SuperTrend series across a user-defined factor range and step, using ATR as the band width. On each bar it measures the distance between the close and each SuperTrend output, then groups

Indicator v5 TrendVolatility & bands
Updated 2 years ago · GPL-3.0 GitHub repository of AI SuperTrend Clustering Oscillator [LuxAlgo]
99 stars

This indicator calculates Bollinger Bands from a chosen price source. It keeps a circular buffer with running sum and sum of squares so the middle band is a simple average and the upper and lower bands sit a chosen number of standard deviations away. Period, s

Indicator v6 Volatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Bollinger Bands (BBANDS)
65 stars

This v5 indicator calculates the Relative Strength Index of close prices using a period of 20. It plots the RSI value exclusively when barstate.isconfirmed evaluates to true and renders no data otherwise. The approach filters the RSI line to confirmed bar stat

Indicator v5 Oscillators & momentum
Updated 5 days ago · GPL-3.0 GitHub repository of V5 Concepts Bar States 04

Fair Value Gaps (FVG)

by dcaoyuan
55 stars

This indicator detects fair value gaps on the price chart. A bullish gap occurs when the current low is above the high two bars earlier and the middle candle closes above its open. A bearish gap uses the opposite comparison. It draws a solid line at the gap ed

Indicator v5 SMC / ICT / price action
Updated 6 months ago · Apache-2.0 GitHub repository of Fair Value Gaps (FVG)

This indicator calculates and plots a Fibonacci-weighted moving average directly on the main price chart. It assigns weights based on the Fibonacci sequence, giving greater importance to recent bars while factoring in historical price points. Users can adjust

Indicator v6 Moving averagesTrend
Updated 8 months ago · MIT GitHub repository of Fibonacci Weighted Moving Average (FWMA)
46 stars

This indicator plots expected volatility zones on the price chart. It requests the previous daily close of the chart symbol and a user-selected volatility index, then converts the index into log space. Two volatility measures build upper and lower bands at 0.2

Indicator v5 Volatility & bandsSupport & resistance Repaints
Updated 7 weeks ago · None stated GitHub repository of Expected Volatility (Log-Transformed)

Consecutive Up/Down Strategy

by TWODS-CAPITAL
37 stars

This strategy tracks consecutive bullish and bearish candlestick closes relative to the preceding bar. It enters a long position when price closes higher for a specified number of consecutive bars, and enters a short position when price closes lower for a desi

Strategy v5 Candlestick patternsTrend
Updated 3 years ago · MIT GitHub repository of Consecutive Up/Down Strategy
16 stars

This trend-following strategy initiates long or short trades on Donchian channel breakouts. Position sizing is calculated from an Average True Range (ATR) volatility model. The script scales into winning trades up to a user-defined unit limit only when RSI con

Strategy v6 TrendBreakout
Updated 12 months ago · None stated GitHub repository of Seykota Alt 36: BE + Momentum

FairValueGap B002

by ruckard
13 stars

This price-chart strategy measures the distance from the current price to the opposite end of the latest fair value gap and enters on the idea that price fills much of that gap. Take profit is set toward a large share of that distance, with a wider stop meant

Strategy v5 SMC / ICT / price actionMean reversion
Updated 1 year ago · None stated GitHub repository of FairValueGap B002
9 stars

Kestrel Export - CCI is a reference data generator designed to export Commodity Channel Index values and divergence metrics for parity testing against external systems. It calculates standard CCI, EMA smoothing, signal lines, overbought or oversold extreme zon

Indicator v6 Oscillators & momentum
Updated 2 days ago · MIT GitHub repository of Kestrel Export - CCI

Stochastic

by suyons
7 stars

This indicator plots a standard Stochastic oscillator in a separate pane to measure momentum. It calculates the raw stochastic oscillator based on closing, high, and low prices, then applies simple moving averages to generate the smoothed %K and %D signal line

Indicator v5 Oscillators & momentum
Updated 4 months ago · None stated GitHub repository of Stochastic
6 stars

This indicator detects Turtle Soup liquidity sweeps and Candle Range Theory setups directly on the price chart. It checks breakout distances against ATR boundaries while requiring optional volume spikes and momentum shifts to confirm reversal signals or flag i

Indicator v5 SMC / ICT / price actionSupport & resistance

MTF Heiken Ashi

by jerryinyang
5 stars

This indicator evaluates Heikin Ashi trend direction across three user-defined higher timeframes. It determines directional bias using either manual Heikin Ashi calculations or imported Heikin Ashi ticker data, with an optional wick filter to assess wick perce

Indicator v4 TrendCandlestick patterns
Updated 2 years ago · None stated GitHub repository of MTF Heiken Ashi
5 stars

This indicator combines pivot-based support and resistance levels with multi-timeframe MACD crossovers and a higher-timeframe exponential moving average trend filter. It identifies support and resistance touches using pivot highs and lows within a user-defined

Indicator v4 Oscillators & momentumSupport & resistance Repaints
Updated 3 years ago · Apache-2.0 GitHub repository of MACD + Support / Resistance

MTF Trend Strategy

by trugurpala
4 stars

This strategy trades a chart-timeframe exponential moving average crossover only when a higher-timeframe close agrees with a higher-timeframe exponential moving average. A bullish cross opens a long and a bearish cross opens a short. Each entry places an avera

Strategy v6 TrendMoving averages Repaints
Updated 2 months ago · MIT GitHub repository of MTF Trend Strategy
3 stars

The CSW Sentiment Line indicator rates RSI, Volume, and RVI from 0 to 100. It averages these to create a composite sentiment and draws labels on the price chart displaying each rating. Users can enable or disable individual metrics and customize colors and lab

Indicator v5 Oscillators & momentumVolatility & bands
Updated 5 months ago · None stated GitHub repository of CSW Sentiment Line
3 stars

Pieki Algo is an all-in-one technical analysis indicator that overlays trading signals, trend visualizers, and Smart Money Concepts onto the main price chart. It plots buy and sell signals based on configurable sensitivity settings, colors candles by trend or

Indicator v5 SMC / ICT / price actionTrend Repaints
Updated 12 months ago · None stated GitHub repository of Pieki Algo Signals & Overlays

IMBA Algo

by TamTH-Dev
2 stars

IMBA Algo is a price chart overlay indicator designed to simulate trading setups with detailed position visualisations. It calculates entry points, automatic or fixed percentage stop losses, break-even levels, and four distinct take profit targets with customi

Indicator v5 TrendScreeners & dashboards
Updated 5 weeks ago · None stated GitHub repository of IMBA Algo
2 stars

This Pine Script library provides a standardized function to format and send custom trade alerts. It processes incoming parameters such as trade direction, setup types, chart timeframe, and price levels including entry, take profit, and stop loss. The library

Library v5
Updated 2 months ago · None stated GitHub repository of AlertSenderLibrary TradingFinder

BS

by avatar-lavventura
2 stars

This indicator estimates buying and selling volume proportions based on the relative position of the close within the high-low range of each bar. It plots total volume as red columns and overlays estimated buying volume as teal columns in a separate indicator

Indicator v4 Volume
Updated 7 months ago · None stated GitHub repository of BS
2 stars

This indicator tracks macroeconomic and financial conditions to estimate recession risk across multiple market dimensions. It requests external data for the S&P 500 moving average growth rate, US 10-year minus 3-month yield curve inversion, M2 money supply tre

Indicator v6 Screeners & dashboardsMoving averages
Updated 8 months ago · None stated GitHub repository of Recession Warning Traffic Light

Hilbert Trendline (HTIT)

by mushroom-men-Trading
2 stars

This indicator calculates a Hilbert Transform instantaneous trendline from a chosen price source and plots it on the price chart. It smooths the source, estimates an adaptive cycle period between 6 and 50 bars from quadrature components, and updates a recursiv

Indicator v6 Trend
Updated 9 months ago · None stated GitHub repository of Hilbert Trendline (HTIT)

Bollinger Bands

by Web3Degenerate
2 stars

This overlay indicator plots customized asymmetrical Bollinger Bands on the price chart to detect breakout trade signals. It calculates a middle simple moving average and standard deviation bands using separate standard deviation multipliers for upper and lowe

Indicator v5 Volatility & bandsBreakout
Updated 2 years ago · None stated GitHub repository of Bollinger Bands

Supply & Demand Zones

by jayadevrana
1 stars

The Supply & Demand Zones indicator calculates and plots potential institutional supply and demand levels directly on the main price chart. It defines base candles by measuring body size against total candle range, and detects impulse candles when candle body

Indicator v6 Support & resistanceSMC / ICT / price action
Updated 3 days ago · MPL-2.0 GitHub repository of Supply & Demand Zones
1 stars

This indicator draws a visible-range volume profile directly on the main price chart as a companion tool for smart money concepts (SMC) analysis. It calculates volume distribution across selectable price rows, plotting high-volume nodes, a configurable Value A

Indicator v6 VolumeSupport & resistance
Updated 3 days ago · None stated GitHub repository of SMC Volume Profile Overlay

Linear Regression Channel

by pineforge-4pass
1 stars

This strategy builds a linear-regression midline of close and places upper and lower bands at a multiple of close standard deviation. It enters long when price is below the lower band and the close rises versus the prior bar, and short when price is above the

Strategy v6 Mean reversionVolatility & bands
Updated 6 days ago · Apache-2.0 GitHub repository of Linear Regression Channel

P_err_two_declarations

by GammaExpansion
1 stars

This script is a minimal parser test fixture from the OptiPine test suite designed to evaluate syntax handling when multiple script declarations are present. It defines both an indicator and a strategy header before plotting the closing price in a separate cha

Indicator v6
Updated 6 days ago · MIT GitHub repository of P_err_two_declarations

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