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.
This indicator plots an EMA and RSI on the price chart. It signals overbought and oversold conditions through red and green triangular markers when the RSI crosses 75. A background highlight marks the active trading session between user-defined start and end t
This strategy executes long entries during a user-defined backtest time window. It calculates a 1-period Exponential Moving Average (EMA) and enters long trades automatically within the specified dates. Positions exit when the calculated EMA exceeds the positi
Bullish Indicator Strategy v2 is a multi-indicator panel drawn in a separate pane. It calculates RSI, MACD, four simple moving averages (20, 50, 100 and 200), Bollinger Bands, ADX, a stochastic oscillator, OBV, a cumulative volume delta, Chaikin Money Flow and
A price-chart indicator that shows buy and sell signals together with a numeric strength score for each signal. Options include a signal strategy mode and sensitivity with an automatic setting, filters for consolidation, high volume and smart signals, candle c
A small Pine v5 indicator that marks fair value gaps on the price chart and shades their position relative to price, with separate colors for buy and sell sides. A single ATR multiplier setting controls how large a gap must be to qualify. Comments and settings
ArminOscillator Strategy is a strategy that applies a stochastic calculation to a long RSI, then smooths it into K and D lines. A long entry occurs when K crosses above D below 20 with price above a short SMA, or in a sideways case; a short entry mirrors this
Plots three exponential moving averages with lengths 12, 26 and 50 as thick lines on the price chart. The README describes using the 50-period line to judge the major trend and waiting for a pullback before entering with it. The visible code has no adjustable
A short overlay indicator that plots rolling resistance and support lines using the highest high and lowest low over a lookback period, 20 bars by default. When a level changes it adds a small label marking the new resistance or support. Inputs set the lookbac
This indicator calculates custom Bollinger Bands using one of four selectable moving averages, defaulting to VIDYA. It plots the upper band, lower band, and basis line directly on the price chart, with a filled background between the outer bands. Buy and sell
A simple example indicator that draws a series of green labels and connects them with red lines on the price chart. On every bar it creates the chosen number of labels, spaced ten bars apart to the right and stepped upward from the high, and joins their coordi
An overlay indicator that merges pivot-based support and resistance channels with MACD signals and a visual backtest module. Channels are built from pivot points inside a loopback window, with limits on width, strength and count, and are coloured when price si
This indicator identifies basic bullish and bearish engulfing candlestick patterns directly on the main price chart. A bullish engulfing signal triggers when a green candle opens at or below the prior bearish candle's close and closes at or above its open. A b
A separate-pane indicator that reads weekly Commitments of Traders data through a TradingView library and plots net positioning for commercial, non-commercial and non-reportable traders. Each series is normalised to a 0 to 100 scale over a configurable lookbac
This minimal Pine Script indicator plots the closing price directly onto the price chart. Developed as part of the GenieV1 automated scalping project, it serves as a lightweight template or baseline script initialized with expanded allowances for boxes, labels
Plots a fixed list of hard-coded price values as circles and short line segments, offset forward from the last bar so they appear as a manually entered projected path on the chart. The values are typed directly into the code, so they do not respond to market d
The MACD #2 strategy plots two exponential moving averages with lengths 12 and 26 on the price chart. Buy signals trigger on the fast EMA crossing above the slow EMA when ATR(14) exceeds its prior value, entering a long position with one unit. The position clo
An overlay that plots a Donchian channel from the prior highest high and lowest low over an adjustable length, with an optional midline and fill, plus a fast and a slow EMA. It highlights a breakout bar when the close crosses the channel, sits on the matching
A long-only style strategy aimed at finding relative lows in stocks. It checks recent and one-year lows, RSI, the lower Bollinger band, volume against its average, a 200-period moving average bear test, MACD histogram turns, consecutive down days and drop from
An overlay indicator combining several tools. It finds pivot highs and lows and groups them into support and resistance channels, limited by width, count and minimum strength, drawn with a chosen line style and colours. It also plots three smoothed moving aver
A minimal strategy-type script for the price chart that draws a fast and a slow moving average, exponential or simple according to a toggle, and colours the lines and the area between them by the direction of the gap. Inputs set the source, the fast length at
A Pine strategy script that overlays three SuperTrend lines with different periods and multipliers, plus a 100-period EMA, and computes the same SuperTrends on a higher timeframe set in minutes. A slope of the third SuperTrend is plotted over a bar-count input
This strategy generates long signals on the price chart using EMA conditions and RSI levels. It enters long positions when the buy condition, based on EMA alignment checks over specified back bars, is satisfied. Exits occur at a stop loss calculated from the e
This indicator calculates and plots the Directional Movement Index (DMI), including the Average Directional Index (ADX), Positive Directional Indicator (+DI), Negative Directional Indicator (-DI), and raw Directional Index (DX). It measures directional price m
A smart money concepts toolkit on the price chart that marks market structure with internal and swing structure, order blocks, equal highs and lows, fair value gaps and premium, discount and equilibrium zones. It can colour candles, flag boring candles and sho
This indicator plots standard Bollinger Bands consisting of an upper band, lower band, and a simple moving average directly on the price chart. It calculates the Relative Strength Index to identify overbought conditions. A bearish signal displays as a red down
Chart Viewer overlays user-supplied price data on the chart. It reads a Candle array and plots each bar's open, high, low and close with plotcandle, coloring green when close is above open, gray when they match, and red otherwise. A second Order array draws gr
Combines an ATR-based Supertrend with an On Balance Volume momentum oscillator. The Supertrend bands, with adjustable ATR period, source and multiplier, appear on the price chart with up and down trend highlighting. The OBV momentum compares a short and a long
A Pine v5 overlay that plots four EMAs (20, 50, 100 and 200) together with a daily central pivot range, taken from the previous day's values, and a full set of pivot point support and resistance levels. Pivot types include Traditional, Fibonacci, Woodie, Class
A long-only strategy based on a trailing stop approach, using a slow SMA, medium and fast EMAs, a pin bar test, and optional stochastic and money flow index filters that can read other timeframes. Exits use a trailing stop plus a hard stop expressed in pips. I
A strategy-type script for crypto that combines Bollinger Bands (22 periods, 1.62 deviations) with %B and an 18-period RSI. It looks for %B crossing back above zero together with RSI crossing back above 28 as one sequence, and %B falling below 1.33 together wi
This indicator combines four tools on the price chart: three simple moving averages (12, 24 and 50 by default), a SuperTrend with an inner zone band and a slower long-term SuperTrend, NSDT HAMA-style candles with gradient colours, and a UT Bot style trailing s
This indicator requests quarterly financial statement data for the current symbol and shows it in a table at the bottom right of the price chart. It groups readings under growth sustainability and solvency, including return on invested capital, reinvestment ra
This indicator combines a squeeze momentum histogram with an ADX line in a separate pane. The squeeze part compares Bollinger Bands with Keltner Channels and marks the squeeze state with coloured crosses on the zero line, while the histogram shows a linear reg
This strategy plots two moving averages on the price chart and uses their relationship to bias long or short trades. Entries can be limited to one direction or allowed to reverse. Stops sit beyond a swing high or low by an ATR multiple, and a reward-to-risk li
LWTI-pro is a custom momentum oscillator plotted in a separate pane. It computes a normalized line from the difference between current and per-bar-close prices divided by ATR then scaled to center at 50. Optional smoothing applies SMA EMA WMA or RMA to the lin
Plots a modified Bollinger setup on the price chart. It draws a 20-bar EMA basis with inner bands at one standard deviation and outer bands at an adjustable multiplier, plus a 13-bar EMA and a 200-bar EMA coloured by price position. Band width is compared with
A Pine v4 indicator in a separate pane that combines MACD and RSI. It plots the standard MACD line, signal line and a four-colour histogram, with options to use simple instead of exponential averages for the oscillator and the signal. The RSI is rescaled and d
A chart overlay combining pivot-based support and resistance lines, five smoothed moving averages (10, 21, 50, 100 and 200), and a zigzag with order block and breaker block boxes. Break labels appear when price crosses a pivot level with a volume-oscillator fi
ARI wrong gap finder is an overlay indicator that searches recent bars for bearish and bullish price gaps. It compares an older low or high range with the current bar and marks a gap only when the percentage difference exceeds the minimum allowed. A qualifying
A smart money concepts overlay that marks swing pivots, break of structure and change of character events, liquidity sweeps, and liquidation wicks on the price chart. The pivot length and liquidation validity window are adjustable, candles can be coloured by c
A strategy that trades when price closes across a 50-period moving average after the previous close was on the other side. It also needs a Stochastic RSI condition on the chart timeframe, a limit on the stop distance in points, and agreement from a higher time
This indicator plots buy and sell markers on the price chart using RSI and Bollinger Bands. A buy triangle appears when RSI is at or below the oversold level and the close is at or below the lower band. A sell triangle appears when RSI is at or above the overb
An unfinished multi-timeframe envelope script on the price chart. The visible code sets a single input, the SMA period with a default of 25, uses the close as source and defines a helper to compare the current timeframe with a given one. No plots, signals or a
12/26-IT Strategy is a trend-following trading strategy that calculates 12 and 26 exponential moving averages alongside resistance levels and RSI bounds. It triggers long entries upon EMA crossovers, optionally filtered by resistance pivots and RSI ranges. The
This indicator overlays two variants of Bollinger Bands and four simple moving averages on the price chart. It plots the Bollinger basis along with upper and lower bands for two adjustable settings using different lengths and multipliers. It also displays MA7,
This intraday strategy opens a long when the MACD histogram crosses above zero and a short when it crosses below, only inside a chosen session and only while ADX is below a threshold of 25. Each trade has a fixed point-based stop loss and take profit relative
A strategy that treats a low ADX, below 18 by default, as consolidation. It draws a box from the highest high and lowest low of the last 20 bars and enters when price crosses the box edge while ADX is low. The stop loss is half the box width and the profit tar
A strategy that applies a k-nearest-neighbours classifier to RSI, ROC, CCI or volume features to estimate the next move, then trades long and or short with an optional moving average filter and volatility filter. Each position uses an ATR-multiple stop loss, a
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.