Synced with GitHub · updated today

Free TradingView Pine Scripts

8,340 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
8,340 scripts

This indicator overlays a market structure dashboard on the price chart. It reads up to seven user-selected timeframes, each with an on/off switch and a trend weight, and shows columns for EMA trend, swing highs and lows, structure, order blocks, and fair valu

Indicator v6 Screeners & dashboardsSMC / ICT / price action
Updated 3 months ago · None stated GitHub repository of Market Structure Dashboard | Flux Charts

RSI Divergence

by muammeryldrm42
7 stars

This strategy detects bullish and bearish RSI divergences using price and RSI pivot points. A bullish divergence triggers a long entry when price forms a lower low while RSI forms a higher low below 40. A bearish divergence triggers a short entry when price fo

Strategy v5 Oscillators & momentumDivergence
Updated 3 months ago · MIT GitHub repository of RSI Divergence

MA Crossover Table

by suyons
7 stars

MA Crossover Table is a multi-timeframe indicator that displays trend states in a table overlaid on the price chart. It computes SMA crossovers for lengths 10, 20 and 60 on timeframes 1, 5, 15 and 60. Bullish conditions trigger when successive SMAs are in uptr

Indicator v5 Moving averagesTrend
Updated 4 months ago · None stated GitHub repository of MA Crossover Table

This indicator combines RSI and MFI into a hybrid oscillator scaled to 0-1. It detects divergences by comparing price and MFI slopes from linear regression. The MFI receives extra weight during divergence to amplify the effect. A TMA smooths the hybrid result

Indicator v6 Oscillators & momentumDivergence
Updated 5 months ago · None stated GitHub repository of Hybrid RSI+MFI - Gold Divergence

This long-only strategy executes trades based on Ichimoku Kinko Hyo Tenkan-Sen and Kijun-Sen crossovers. It opens a long position when the Tenkan-Sen moves above the Kijun-Sen and closes the position when the Tenkan-Sen falls below the Kijun-Sen. Main settings

Strategy v5 TrendMoving averages
Updated 1 year ago · MPL-2.0 GitHub repository of Ichimoku Kinko Hyo TK Cross Strategy

Time Interval Volume Sum

by JackZhao516
7 stars

This indicator sums bar volume between a user-chosen start and end time. It highlights that interval on the price chart with a background color and plots the running total on the status line. On the last bar it draws a label above the midpoint of the interval

Indicator v5 Volume
Updated 3 years ago · MIT GitHub repository of Time Interval Volume Sum

RSI

by trsdn
6 stars

This indicator calculates the Relative Strength Index along with a 200-period simple moving average. It plots the RSI oscillator line alongside horizontal reference levels for overbought and oversold thresholds in a separate pane below the main price chart. Co

Indicator v5 Oscillators & momentumMoving averages
Updated 5 days ago · MIT GitHub repository of RSI
6 stars

Capital41 Fusion Core Strategy is an overlay trading strategy that combines an exponential moving average trend filter, RSI, Williams %R, and volume/ATR expansion into a composite momentum oscillator. It executes long trades when the smoothed oscillator crosse

Strategy v6 TrendOscillators & momentum
Updated 8 weeks ago · MIT GitHub repository of Capital41 Fusion Core Strategy
6 stars

Institutional CRT Framework is an overlay indicator that highlights candlestick patterns including 2-candle rejection, 3-candle classic, inside bar consolidation, and outside bar ranges directly on the price chart. It offers optional time-session filtering acr

Indicator v6 Candlestick patternsSMC / ICT / price action
Updated 7 months ago · None stated GitHub repository of Institutional CRT Framework

TheStrat Suite

by 345-strategies
5 stars

This indicator implements Rob Smith's TheStrat price action methodology across up to six configurable timeframes. It classifies candles into inside, directional, and outside bars, identifies patterns like hammers, shooters, and failed 2s, and calculates magnit

Indicator v6 Candlestick patternsSupport & resistance Repaints
Updated 2 days ago · MPL-2.0 GitHub repository of TheStrat Suite

Quantile-Based Adaptive Detection calculates statistical distribution thresholds using weighted quantile moments and percentiles. It computes adaptive deviation, skewness, and kurtosis levels relative to a calculated median center using moving window data or s

Indicator v6 Volatility & bandsSupport & resistance
Updated 8 months ago · None stated GitHub repository of Quantile-Based Adaptive Detection

Rolling Moving Average

by SiegerTerpstra
5 stars

This indicator plots a Rolling Moving Average, also called Wilder's smoothing or SMMA, on the price chart. It averages the selected source with a length-based Wilder formula that is seeded by a simple moving average, then can apply a second moving-average pass

Indicator v6 Moving averagesTrend
Updated 9 months ago · None stated GitHub repository of Rolling Moving Average

SM and MACD

by jerryinyang
5 stars

This strategy combines Squeeze Momentum and MACD indicators to generate trading signals. It plots the Squeeze Momentum histogram and MACD in a separate pane. The strategy enters long positions when squeeze enters and MACD is bullish, and short when squeeze ent

Strategy v4 Oscillators & momentumVolatility & bands
Updated 2 years ago · None stated GitHub repository of SM and MACD

This long-only strategy combines a 200-period Exponential Moving Average, Stochastic RSI, and three distinct Supertrend indicators with varying ATR periods and multipliers. It enters long trades when price trades above the 200 EMA, Stochastic RSI crosses up fr

Strategy v4 TrendOscillators & momentum
Updated 3 years ago · Apache-2.0 GitHub repository of 200 EMA + Stochastic + Triple Supertrend Long Strategy
4 stars

This strategy trades pullbacks in the direction of a moving-average trend and draws on the price chart. An uptrend requires the 50-period EMA above the 200-period EMA with price above the slower average, and a downtrend is the reverse. It enters long or short

Strategy v6 TrendOscillators & momentum

MTF MA Bands + RSI

by InNoobWeTrust
4 stars

This indicator calculates and plots multi-timeframe moving average bands alongside a Relative Strength Index in a separate pane. It evaluates up to five distinct moving average layers across user-defined timeframes, ranging from the chart resolution to daily i

Indicator v6 Moving averagesOscillators & momentum
Updated today · None stated GitHub repository of MTF MA Bands + RSI

SuperTrend Follow

by latentwill
4 stars

The SuperTrend Follow strategy determines trend direction using a simple ATR value derived from the moving average of high-low ranges. It plots on the price chart and enters long positions when price exceeds the ATR value or short when price falls below. The s

Strategy v5 TrendMoving averages
Updated 6 days ago · None stated GitHub repository of SuperTrend Follow
4 stars

This strategy trades directional momentum breakouts for crude oil on the price chart. It enters long or short positions when a fast exponential moving average crosses a slow exponential moving average, provided that current Average True Range exceeds its movin

Strategy v6 TrendMoving averages
Updated 2 months ago · MIT GitHub repository of CL Crude Oil Momentum [trugurpala]
4 stars

The Keltner Channel Strategy is a breakout system plotted directly on the main price chart. It calculates upper and lower channel bands around an exponential or simple moving average using ATR, True Range, or bar range multiplied by a specified factor. A long

Strategy v5 TrendVolatility & bands
Updated 5 months ago · None stated GitHub repository of Keltner Channel Strategy

MA Crossover Strategy [Lab]

by mitchell-917
4 stars

This strategy plots fast and slow moving averages on the price chart and trades their crossovers. It enters long when the fast average crosses above the slow average and short when it crosses below. An optional higher-timeframe moving average can block trades

Strategy v5 TrendMoving averages
Updated 11 months ago · Custom licence GitHub repository of MA Crossover Strategy [Lab]

M+AT+BOLL+T3

by Kalumur
4 stars

This multi-indicator toolkit and scanner overlays Tillson T3 Moving Averages, MavilimW weighted moving average combinations, Bollinger Bands, and AlphaTrend calculations directly on the price chart. It includes color-coded trend direction signals and alerts wh

Indicator v5 Moving averagesTrend
Updated 2 years ago · None stated GitHub repository of M+AT+BOLL+T3

My Custom Strategy 1

by might-tree
4 stars

This long-only strategy plots a 20-period exponential moving average of the low, a 20-period simple moving average of the low, and the close in a separate pane. It enters long when the high breaks the prior 25-bar highest close and the close is above both the

Strategy v5 Moving averagesBreakout Repaints
Updated 3 years ago · None stated GitHub repository of My Custom Strategy 1

Stoch (Brahim)

by bfoura
4 stars

Stoch (Brahim) is a momentum indicator that calculates Stochastic oscillator values and plots signals directly on the main price chart. It evaluates whether the smoothed Stochastic %K line meets or exceeds predefined overbought and oversold thresholds. When ov

Indicator v4 Oscillators & momentum
Updated 4 years ago · None stated GitHub repository of Stoch (Brahim)

Snagprofit HL

by dearvn
4 stars

Snagprofit HL is an overlay indicator that tracks recent price extremes. It stores the highest high and lowest low over two lookback windows, defaulting to 8 and 21 bars, when price matches those extremes. It plots the longer window high and low as black lines

Indicator v5 Support & resistance
Updated 4 years ago · None stated GitHub repository of Snagprofit HL

Dipmix

by gocaman
3 stars

Dipmix is a separate-pane momentum and scanning indicator designed to identify market bottoms and oversold conditions. It calculates a WaveTrend oscillator using EMA-smoothed price channels, alongside an integrated Awesome Oscillator and Accelerator Oscillator

Indicator v5 Oscillators & momentumScreeners & dashboards
Updated today · None stated GitHub repository of Dipmix

Auto S/R v2

by g-moe
3 stars

Auto S/R v2 plots automatic support and resistance on the price chart. It finds pivot highs and pivot lows with a fixed strength of five bars, then stores those prices as horizontal key levels. A proximity check compares each new level with the average candle

Indicator v5 Support & resistance
Updated 5 months ago · None stated GitHub repository of Auto S/R v2
3 stars

This Pine Script v5 indicator provides a collection of mathematical utility functions including safe division, percentage change, normalization, array average and standard deviation calculations. The functions are wrapped with debugging capabilities that suppo

Indicator v5
Updated 7 months ago · None stated GitHub repository of Math Utilities with Debugging
3 stars

This indicator plots four exponential moving averages on the price chart and compares their order. It marks a fast-over-medium crossover only when the fast average is on the same side of the trend average, and it draws buy or sell labels when all four averages

Indicator v5 TrendMoving averages
Updated 8 months ago · MIT GitHub repository of Stella's Multi-EMA Crossover

Elite Algo Modded

by IAMATOMIC001
3 stars

This overlay indicator plots optional buy and sell signals on the price chart, with a selectable strategy mode, sensitivity, and an automatic sensitivity option. Filters can limit signals during consolidation, to smart signals, or to high-volume bars, and cand

Indicator v5 Volatility & bandsTrend
Updated 12 months ago · None stated GitHub repository of Elite Algo Modded

BTMM Master Dashboard

by jcortes254
3 stars

The BTMM Master Dashboard indicator plots tables, boxes, and labels on the price chart for multi-timeframe analysis. It calculates 5, 13, 50, and 200 period EMAs along with session-based market maker phases including accumulation, manipulation, distribution, a

Indicator v5 Screeners & dashboardsSessions & time
Updated 1 year ago · None stated GitHub repository of BTMM Master Dashboard

This indicator calculates and plots a custom Parabolic Stop and Reverse (PSAR) trailing level directly on the price chart. It tracks trend direction by updating acceleration factors as new extreme price highs or lows are reached. Bullish trends are displayed w

Indicator v5 Trend
Updated 2 years ago · None stated GitHub repository of Parabolic Stop and Reverse (Trend Following)

Hyper Flow Indicator

by jawauntb
3 stars

This indicator calculates a composite RSI oscillator paired with STARC volatility bands in a separate pane. It evaluates momentum by combining RSI differentials with smoothed RSI readings, while also referencing higher-timeframe data, moving averages, and esti

Indicator v5 Oscillators & momentumVolatility & bands Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Hyper Flow Indicator

Currency Strength Chart

by itmakesyousick
3 stars

This indicator plots relative strength for major forex currencies in a separate pane. It calculates each currency with RSI, CCI, or stochastics over a chosen resolution, using automatic, custom, or lookback period modes. Users can show or hide individual curre

Indicator v5 Oscillators & momentumScreeners & dashboards
Updated 4 years ago · None stated GitHub repository of Currency Strength Chart

Golden / Death Cross

by piecioshka
2 stars

This indicator plots a fast and a slow simple moving average on the price chart, defaulting to lengths of 50 and 200. It marks a golden cross when the fast average crosses above the slow average and a death cross when it crosses below. Each cross draws a dashe

Indicator v6 TrendMoving averages
Updated 10 days ago · MIT GitHub repository of Golden / Death Cross

MP Camarilla Range Bounce

by midngtpickle
2 stars

This strategy fades touches of daily Camarilla pivot boundaries (S3 for longs, R3 for shorts) during sideways market conditions. It plots pivot levels directly on the price chart and validates entries using regime filters, including maximum ADX thresholds, pri

Strategy v6 Support & resistanceMean reversion
Updated 4 weeks ago · Custom licence GitHub repository of MP Camarilla Range Bounce

Oscillator

by TamTH-Dev
2 stars

This indicator plots a composite oscillator in a separate pane, integrating squeeze momentum, directional flux, divergence detection, and confluence gauges. It calculates momentum dynamics and squeeze conditions, highlights regular or hidden divergences with l

Indicator v6 Oscillators & momentumDivergence Repaints
Updated 5 weeks ago · None stated GitHub repository of Oscillator
2 stars

This indicator plots smart money concept structures directly on the price chart using confirmed swing pivots and an internal trend state machine. It identifies Break of Structure, Change of Character, Fair Value Gaps, and Order Blocks. Mitigated zones automati

Indicator v6 SMC / ICT / price actionSupport & resistance
Updated 2 months ago · Custom licence GitHub repository of Smart Money Structure Toolkit

Mirpapa Lib HTF

by alvinng214
2 stars

Mirpapa Lib HTF is a Pine Script v6 utility library designed for higher timeframe (HTF) data processing and chart timeframe conversions. It exports a custom data structure for caching open, high, low, close, and time values across multiple bars, alongside util

Library v6
Updated 2 months ago · None stated GitHub repository of Mirpapa Lib HTF

ZEGUELA DEMALONG

by danielvm-git
2 stars

This strategy executes long trades based on Double Exponential Moving Average (DEMA) crossover signals. It calculates up to three DEMAs, triggering entries when the faster DEMA crosses above the slower DEMA (optionally filtered by a third DEMA's direction) or

Strategy v4 Moving averagesTrend
Updated 2 months ago · MIT GitHub repository of ZEGUELA DEMALONG

This indicator calculates Stan Weinstein's Mansfield Relative Strength (MRS) comparing a security against a chosen benchmark index, such as the S&P 500. It measures outperformance and underperformance relative to a zero line using a moving average baseline. Th

Indicator v6 TrendOscillators & momentum
Updated 3 months ago · Apache-2.0 GitHub repository of Mansfield Relative Strength (Weinstein Method)

Lakshmi Zones

by voletiramu
2 stars

Lakshmi Zones calculates and plots unmitigated daily order blocks, supply and demand zones, and key levels directly on the price chart. It processes historical daily candlestick bodies and wicks to generate zone boxes, tracking whether subsequent daily closes

Indicator v6 Support & resistanceSMC / ICT / price action
Updated 6 months ago · None stated GitHub repository of Lakshmi Zones

WaveTrend with Crosses [LazyBear]

by avatar-lavventura
2 stars

This strategy combines multiple technical indicator systems into a composite trading setup. It computes an Ichimoku Cloud, an ATR-based trailing stop system (nKRAL) with optional Heikin Ashi smoothing, Bollinger Bands, Parabolic SAR, and higher-timeframe Super

Strategy v4 TrendVolatility & bands
Updated 7 months ago · None stated GitHub repository of WaveTrend with Crosses [LazyBear]

This indicator builds a Supertrend-style channel from ATR and the median price, then tracks the highest and lowest prices between trend flips. It plots a grid high, grid low and midpoint, shifted by an offset, and can filter the channel by minimum and maximum

Indicator v6 TrendVolatility & bands Repaints
Updated 8 months ago · MIT GitHub repository of Grid Bot Supertrend Channel [psyll]

This indicator plots net positions for Commercial and Non-Commercial (Large Speculators) traders using Commitment of Traders (COT) legacy report data. It automatically converts root symbols to their corresponding CFTC codes to fetch daily long and short positi

Indicator v6 Volume
Updated 8 months ago · None stated GitHub repository of COT Net Commercial vs Net Non-Commercial Positions

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