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

This utility indicator exports historical OHLCV market data into formatted CSV text using Pine Logs on the latest chart bar. It iterates through historical bars from oldest to newest, logging timestamps, open, high, low, close, and volume values. Users can spe

Indicator v6
Updated 7 weeks ago · None stated GitHub repository of Data Exporter for Optimizer

Larper Suite

by DeolinNaidoo
8 stars

Larper Suite is an overlay indicator for ICT and quarterly-theory analysis. It plots true session, daily, weekly, monthly, and yearly opens plus prior and current high-low liquidity levels. It tracks multi-asset SMT, swing divergence, fair-value-gap fills, and

Indicator v6 SMC / ICT / price actionDivergence Repaints
Updated 3 months ago · GPL-3.0 GitHub repository of Larper Suite

GainzAlgo V2 Alpha

by Bakomebandias
8 stars

This overlay indicator scores breakouts of recent highs and lows against failed-breakout checks, EMA trend alignment, RSI momentum, and an ATR volatility band. It plots green buy and red sell labels when conditions pass a minimum score, and it prints ATR-based

Indicator v6 TrendOscillators & momentum
Updated 6 months ago · None stated GitHub repository of GainzAlgo V2 Alpha

MattSuite V3

by mmarbmatt
8 stars

MattSuite V3 is an overlay indicator that combines market-structure and trend tools on the price chart. It identifies bullish and bearish fair value gaps and estimates their strength, flags break of structure and change of character, and marks order blocks. It

Indicator v5 SMC / ICT / price actionVolatility & bands
Updated 1 year ago · None stated GitHub repository of MattSuite V3

RSI Crossover

by cleanmind777
8 stars

This strategy evaluates market trends using triple exponential moving averages, a Stochastic RSI oscillator, MACD, Supertrend, and average true range. It plots two EMAs and Supertrend direction directly on the price chart alongside entry shape markers. Long en

Strategy v5 TrendOscillators & momentum
Updated 1 year ago · None stated GitHub repository of RSI Crossover
8 stars

Plots institutional price action and smart money concepts directly on the price chart. It detects swing and internal market structures, marking Break of Structure (BOS) and Change of Character (CHoCH) levels, swing points, and strong or weak highs and lows. Th

Indicator v5 SMC / ICT / price actionSupport & resistance Repaints
Updated 1 year ago · MIT GitHub repository of Price Action Concepts Open Source

KY SMC Indicator

by yusin99
8 stars

This indicator plots smart money concepts on the price chart. It marks internal and swing market structure, optional short, intermediate, and long-term swing points, and strong or weak highs and lows. It can draw internal and swing order blocks, filtered by AT

Indicator v5 SMC / ICT / price actionSupport & resistance Repaints
Updated 2 years ago · None stated GitHub repository of KY SMC Indicator

BB strategy Production

by satheshshiva
8 stars

This strategy plots Bollinger Bands on the price chart using a simple moving average and a standard-deviation multiplier. It enters long when close crosses above the lower band while still below the basis, and short when close crosses under the upper band whil

Strategy v5 Volatility & bandsMean reversion
Updated 3 years ago · None stated GitHub repository of BB strategy Production

Calculates a custom moving average (MaMA) by modifying the source price with price momentum, acceleration, and psychological win-rate probability before applying an EMA or SMA. Plots the adjusted moving average directly on the price chart alongside optional re

Strategy v5 Moving averagesTrend
Updated 4 years ago · None stated GitHub repository of Momentum Adjusted Moving Average by DGT
8 stars

This indicator draws a combined bias in a separate pane, aimed at crypto charts. It colors the alert green, red, or white from a linear-regression value and ADX directional movement, using a sensitivity input that tightens or loosens the ADX threshold and slop

Indicator v4 TrendOscillators & momentum
Updated 4 years ago · GPL-3.0 GitHub repository of Linear Regression ADX Eyachay

PA Stats

by Enesp4rl4k
7 stars

This indicator displays a compact trade metrics table in the top-right corner of the price chart. Built as a template script for automated MCP server workflows, it populates and presents trade setup details including risk percentage, calculated position units,

Indicator v6 Screeners & dashboards
Updated 5 days ago · MIT GitHub repository of PA Stats

Natural Squares

by NQ-stats-MX
7 stars

This indicator plots Gann natural squares and fractional Square of Nine levels as horizontal lines on the price chart. It scales price, takes the square root, and draws a chosen number of levels above and below the close, with optional root, angle, price, and

Indicator v6 Support & resistance
Updated 9 days ago · MIT GitHub repository of Natural Squares

Arrows Off BB

by lunarticktrading
7 stars

This indicator plots standard Bollinger Bands and identifies potential mean-reversion setup signals directly on the main price chart. A bullish signal triggers when a bullish candlestick follows a bearish candlestick while both consecutive bars' lows drop belo

Indicator v6 Volatility & bandsMean reversion
Updated 2 weeks ago · None stated GitHub repository of Arrows Off BB

This indicator plots core Inner Circle Trader (ICT) concepts directly on the price chart. It visualizes session killzones (Asia, London, NY AM, London Close, NY PM) with high and low boundaries, opening price levels, multi-timeframe Fair Value Gaps with conseq

Indicator v5 SMC / ICT / price actionSessions & time Repaints
Updated 3 weeks ago · GPL-3.0 GitHub repository of All-in-One ICT v1.2 + RTH Gap + HTF Candles

1-Min Gold Taylor Technique

by eddiebelaval
7 stars

This intraday strategy implements session-based trading rules tailored for gold on short timeframes. It tracks the Asian session price range, VWAP, 20-period EMA, and previous day high and low levels to identify liquidity sweeps during London and New York trad

Strategy v6 Sessions & timeSupport & resistance
Updated 3 months ago · None stated GitHub repository of 1-Min Gold Taylor Technique

BB Squeeze Breakout

by muammeryldrm42
7 stars

BB Squeeze Breakout is a volatility breakout strategy that identifies consolidation squeezes using Bollinger Band width percentile ranking. When the band width drops below its 25th percentile and price crosses above or below the bands with optional volume conf

Strategy v5 Volatility & bandsBreakout
Updated 3 months ago · MIT GitHub repository of BB Squeeze Breakout

ATR Renko

by suyons
7 stars

ATR Renko generates reversal signals on standard price charts by requesting synthetic Renko bar data calculated with an Average True Range box size. It tracks changes in Renko block direction and plots buy labels when a down block transitions to an up block, a

Indicator v6 TrendVolatility & bands
Updated 4 months ago · None stated GitHub repository of ATR Renko

Bullish Engulfing Low

by chargersfan47
7 stars

Bullish Engulfing Low is an overlay indicator that marks a two-candle pattern: a bullish bar whose close is above the prior bar open and whose low stays above the prior low, after a bearish bar. When that condition is true it draws a right-extended horizontal

Indicator v6 Candlestick patternsSupport & resistance Repaints
Updated 5 months ago · None stated GitHub repository of Bullish Engulfing Low
7 stars

This indicator calculates a simple moving average over a specified lookback period using a custom summation loop. It plots the moving average directly on the price chart as a blue line. An alert condition triggers whenever the chosen source price crosses above

Indicator v6 Moving averagesTrend
Updated 9 months ago · None stated GitHub repository of Non-Compliant Indicator
7 stars

This strategy plots dynamic pivot-based support and resistance trendlines on the price chart and trades breakouts beyond those lines. By default it allows longs only when EMA 50 is above EMA 200 and an RSI-SMA momentum filter is met, with an ATR entry buffer.

Strategy v6 TrendBreakout
Updated 12 months ago · None stated GitHub repository of Easy Trendline - XAUUSD 30m
7 stars

This strategy opens a long position when the bar hour matches the opening hour, the close is above a simple moving average, and the day is not Thursday or Saturday. It closes that long when the bar hour matches the closing hour. Default inputs set the open hou

Strategy v5 Moving averagesSessions & time Repaints
Updated 1 year ago · None stated GitHub repository of Strategia Buy 20:00 - Close 00:00

Backtest Adapter

by SynergOps
7 stars

This strategy adapts an external numeric source into backtest orders on the price chart. It opens a long when the source equals 1 and closes that long when it equals 2. It opens a short at -1 and closes it at -2. An optional start-date filter blocks trades bef

Strategy v6
Updated 1 year ago · MPL-2.0 GitHub repository of Backtest Adapter
7 stars

Calculates volume profile levels over a lookback window to identify support, resistance, and Point of Control (POC) lines on the price chart. It executes trades based on price interaction with these low-volume zones, featuring customizable signal inversion and

Strategy v6 ScalpingVolume
Updated 1 year ago · None stated GitHub repository of Enhanced NQ1 Scalping Strategy

Our MACD Backtesting

by benniebendiksen
7 stars

This Pine Script strategy computes a MACD indicator with customizable fast, slow, and signal EMA lengths applied to close prices. Delta is calculated as the difference between the MACD line and signal line, plotted as an overlay on the price chart. Long entrie

Strategy v5 Oscillators & momentumMoving averages
Updated 1 year ago · MIT GitHub repository of Our MACD Backtesting

ForexAlgo

by Harshil427
7 stars

ForexAlgo generates trade signals directly on the price chart using a primary leading indicator, such as the Range Filter, combined with modular confirmation filters. Traders can toggle multiple technical filters, including exponential moving average crosses,

Indicator v5 TrendOscillators & momentum Repaints
Updated 1 year ago · None stated GitHub repository of ForexAlgo

LIT - Timing

by rpanchyk
7 stars

LIT - Timing plots key market session ranges directly on the price chart based on Liquidity Inducement Theorem concepts. It renders customizable boxes alongside horizontal projection lines representing the high, low, and midpoint for the Asian, London, and New

Indicator v5 Sessions & timeSupport & resistance Repaints
Updated 2 years ago · MIT GitHub repository of LIT - Timing

Math

by BlackPhoenixSlo
7 stars

This Pine Script v5 library provides helpers for approximating price and reducing noise. The exported DFT3 function computes a three-point discrete Fourier transform from the current close and the two previous closes, using a direction parameter that scales th

Library v5
Updated 2 years ago · None stated GitHub repository of Math

This strategy trades EUR/USD breakouts on the price chart using Ichimoku values. It marks a compressed range when the Senkou spans twist and the range height stays under a pip limit. It enters long on a close above the prior range high, or short below the prio

Strategy v4 TrendBreakout
Updated 2 years ago · MIT GitHub repository of Robot Forex BREAKOUT EUR/USD 5MIN - Ichimoku
7 stars

Acts as a modular strategy boilerplate designed for automated and manual trading strategies on the price chart. It provides execution infrastructure including trade direction toggles, signal reversal, alternating orders, session filtering, and anti-news volati

Strategy v5 Sessions & time
Updated 2 years ago · None stated GitHub repository of Git Pine Script v5 Template

Combined Strategy

by Dropio12
7 stars

This strategy plots buy and sell markers on the price chart by combining a fast and slow ALMA crossover with a simple close-to-close momentum check. A long marker appears when the fast ALMA crosses above the slow ALMA and momentum is positive. A short marker a

Strategy v5 TrendOscillators & momentum
Updated 2 years ago · None stated GitHub repository of Combined Strategy

Optimizer v1

by QuantGeekDev
7 stars

This strategy generates long signals on the price chart using multiple technical indicators. It computes EMA 70 and 100, SMA 70, ADX with DMI, CCI, and MACD values. A long entry occurs when EMA crossover condition, SMA condition, ADX above 15, CCI above 30, an

Strategy v5 TrendOscillators & momentum
Updated 3 years ago · None stated GitHub repository of Optimizer v1

15m Volume Alert

by JackZhao516
7 stars

This strategy monitors 15-minute volume to detect sudden volume spikes and triggers long entries directly on the price chart. It evaluates whether the latest 15-minute volume exceeds preceding bars by a factor of 10 or 50, provided that the total bar turnover

Strategy v5 VolumeBreakout Repaints
Updated 3 years ago · MIT GitHub repository of 15m Volume Alert

FX Market Sessions

by itmakesyousick
7 stars

This indicator draws custom trading session boxes directly on the price chart, with presets for London, New York, and Tokyo sessions. It calculates and outlines session ranges using boxes and lines, with optional extensions, opening ranges, and Fibonacci retra

Indicator v5 Sessions & timeSupport & resistance
Updated 3 years ago · None stated GitHub repository of FX Market Sessions

SRI Indicator ft. MSB

by kingmalitha
7 stars

This indicator overlays an all-in-one technical analysis toolkit on the price chart. It plots multiple moving averages, including standard EMAs, SMAs, and a Trend Regularity Adaptive Moving Average, alongside Bollinger Bands, Supertrend, Nadaraya-Watson envelo

Indicator v5 Moving averagesTrend Repaints
Updated 3 years ago · None stated GitHub repository of SRI Indicator ft. MSB
7 stars

This indicator calculates Time Segmented Volume (TSV) to measure volume flows by comparing price and volume changes across periods. Displayed in a separate pane, it plots a color-coded TSV histogram alongside a fast moving average signal line. It adds upper an

Indicator v4 VolumeOscillators & momentum
Updated 4 years ago · None stated GitHub repository of Time Segmented Volume Bands
7 stars

This strategy plots a simple moving average basis and upper and lower Bollinger bands on the price chart, with a fill between the bands. It also calculates RSI. It opens one long trade when RSI is above 25, price is at or below the lower band, and no position

Strategy v5 Volatility & bandsOscillators & momentum
Updated 4 years ago · GPL-3.0 GitHub repository of Bollinger Bands Strategy

Philosopher

by AzureKn1ght
7 stars

Philosopher is an overlay strategy that combines Stochastic momentum calculations, Waddah Attar Explosion volatility signals, and Hull Moving Average baselines to generate trade entries. It utilizes higher-timeframe Hull Moving Averages to evaluate market tren

Strategy v4 TrendOscillators & momentum
Updated 5 years ago · MPL-2.0 GitHub repository of Philosopher

MainScript

by Swastik2000
7 stars

This strategy calculates a Volume-Weighted Average Price (VWAP) with optional standard deviation bands alongside an Exponential Moving Average (EMA) on the main price chart. It is designed to generate buy and sell conditions based on crossovers between the EMA

Strategy v4 TrendMoving averages Repaints
Updated 5 years ago · None stated GitHub repository of MainScript

Head

by dgnsrekt
7 stars

This indicator template generates an options reticle overlay on the price chart, plotting horizontal out-of-the-money strike price targets and vertical expiration crosshairs. It includes a fill mode that dynamically shades the area between historical price and

Indicator v4 Support & resistanceScreeners & dashboards
Updated 6 years ago · MIT GitHub repository of Head

CG-ISMARKET Session Flags

by pineforge-4pass
6 stars

This diagnostic strategy inspects and records TradingView session built-in flags on each chart bar. It alternates between long and short entries on every bar, encoding the state of regular market, premarket, postmarket, and boundary flags into the order commen

Strategy v6 Sessions & time
Updated today · Custom licence GitHub repository of CG-ISMARKET Session Flags

Bollinger Bands

by trsdn
6 stars

This indicator plots classic Bollinger Bands on the price chart. It calculates a simple moving average of the selected source as the basis, then places upper and lower bands a chosen number of standard deviations away from that average. A translucent fill mark

Indicator v5 Volatility & bandsMoving averages
Updated 5 days ago · MIT GitHub repository of Bollinger Bands
6 stars

This overlay indicator scores a bull, bear, or neutral game state from an auditable decision-forest probability rather than a fitted machine-learning model or live API. It compares the smoothed probability with bull and bear thresholds, then shifts it when a s

Indicator v6 Screeners & dashboardsAI / machine learning Repaints
Updated 6 days ago · None stated GitHub repository of Regime Game Probability Forest

C41 Core Strategy v2

by damianpitt
6 stars

This strategy plots an EMA or SMA on the price chart and enters long when price is above the average and both RSI and Williams %R meet the long condition, or short when price is below the average and both oscillators meet the short condition. An optional turn

Strategy v6 TrendOscillators & momentum
Updated 8 weeks ago · MIT GitHub repository of C41 Core Strategy v2

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