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.
The Rolling VWAP indicator calculates and overlays a rolling volume-weighted average price directly on the price chart. Unlike anchored or daily reset VWAPs, it calculates volume-weighted price over a continuous rolling time window defined by days, hours, and
The HMA sweete indicator computes multiple variants of the Hull Moving Average including standard HMA THMA EHMA and custom z- versions with added momentum. Users can select the source series MA type length multiplier and history bars for up to three MAs. It pl
This strategy identifies and plots Fair Value Gaps (FVG) and Balanced Price Ranges (BPR) directly on the price chart. It generates trading signals when price retraces into active gap zones using a customizable entry ratio coefficient. Stop loss levels are plac
This educational indicator calculates and visualizes market gap sizes in a separate pane. It computes two distinct metrics: the absolute percentage gap between the current bar open and the previous close, and the percentage gap distance between the current bar
This indicator draws price data on the chart. It uses a plot budget function to limit the number of plots and displays close, high, and low prices. The script also provides functions to draw dynamic boxes and lines on the price chart. Arrays manage these objec
This strategy implements the classic Turtle Trading breakout rules on the price chart. It enters positions when price breaks above or below highest high or lowest low channel levels. Position size is dynamically calculated using ATR volatility so that one ATR
This long-only strategy identifies trading opportunities using anchored VWAP reclaims, retests, and breakouts. It calculates VWAP with standard deviation bands alongside zero-lag EMA slope filters to verify market trend alignment. Entries trigger either from a
This strategy calculates three simple moving averages with lengths 10, 20 and 50. It identifies a bull stack when the shortest exceeds the middle which exceeds the longest, and a bear stack in the opposite direction. A var-bool latch tracks prior states to sup
This script is an indicator written in Pine Script version 6. It declares an indicator named P_err_unclosed_paren and plots the close price using the plot function. The plot draws in a separate pane. There are no input settings. The script is incomplete with a
An overlay indicator for the New York morning window that looks for qualified structure breaks on a 5-minute chart. Direction is filtered by a one-hour bias built from swing structure and EMAs. A break must clear swing, channel or session-extreme levels and pa
DEPV2 DEBUG S17 is a debug indicator for a multi-method crypto trading signal tool. It supports 20 major cryptocurrency symbols from Binance such as BTCUSDT, ETHUSDT, SOLUSDT, and others. Four signal classes are available: TREND based on price levels, MOMENTUM
The indicator plots volume power zones on the price chart using lower timeframe data. It divides recent candles into multiple zones and computes a weighted probability of strong or weak buy or sell signals. The probability combines momentum strength, accelerat
A small price-chart indicator that plots a fast and a slow exponential moving average, defaulting to 6 and 20 periods, and fills the space between them with a cloud. The cloud is green while the fast average is above the slow one and red otherwise, so a colour
A large detection indicator that merges many volume and price-pattern engines into numbered signals drawn as shapes on the price chart. Components include pocket pivot detection, displacement measured in standard deviations, a VWMA with ATR Supertrend, relativ
TN Compression Expansion V6 identifies volatility contraction and trades subsequent breakouts. It compares the Average True Range against its simple moving average to pinpoint compression phases where ATR drops below a specified ratio threshold. When price bre
A short Pine v4 indicator that plots a Donchian-style channel using the highest and lowest values over a set length, with a midpoint line. It labels a bullish or bearish Turtle when the previous bar's upper band rose or fell compared with the bar before, colou
A Pine Script v5 indicator in a separate pane, the second revision of a Hurst cycle peak marker. It passes the hl2 price through bandpass filters for cycles from 1 day to 18 years and draws labels and lines at cycle peaks. Each cycle has its own bandwidth and
This indicator plots VWAP of the typical price and upper and lower bands from a rolling standard deviation of price versus VWAP. It scores possible downside and upside reversals from RSI extremes, band touches, a 9-period versus 21-period EMA, and candle direc
This indicator overlays Bollinger Bands on the price chart and combines them with the Awesome Oscillator to generate buy and sell signals. It triggers long entries when the three-period EMA crosses upward through the middle Bollinger Band while the Awesome Osc
Teaching script showing user-defined methods in Pine. A method keeps an array of the latest 50 closes by adding a new value and removing the oldest, and the script plots the array's average in a separate pane, which acts as a 50-bar simple average. It also not
A strategy that scores many indicators and trades when the total reaches a set threshold. Inputs weight an EMA trend, SuperTrend, Parabolic SAR, Hull average, RSI, MACD, WaveTrend, Stochastic, Bollinger and ATR signals, including divergences. Separate strong a
This indicator calculates the Vertical Horizontal Filter (VHF) to help identify whether a market is trending or ranging. It measures the difference between the highest and lowest close over a user-defined period and divides it by the sum of absolute bar-to-bar
A Pine v4 strategy that builds a MACD from simple moving averages of 12 and 26 bars with a nine-bar signal, alongside a 14-period RSI. It plots the volume-weighted average price in blue and the 30-bar highest and lowest closes as green and red lines on the pri
The Hampel Filter indicator identifies and filters out price outliers to smooth price data directly on the main chart. It calculates the rolling median and Median Absolute Deviation (MAD) of the chosen source series over a specified length. When a data point e
This indicator screens multiple symbols for regular RSI divergence and extreme RSI readings. It compares pivot lows and highs in price with a 14-period RSI, then alerts when price makes a lower low against a higher RSI low, or a higher high against a lower RSI
APTV-tracker plots historical ARK Invest buy and sell transactions directly on the price chart for Aptiv PLC. The script uses hardcoded labels anchored to specific historical timestamps to mark execution dates, showing transaction directions and ETF counts. An
FunctionNNLayer is a Pine Script v5 library providing a generalized neural network layer computation. It accepts an input array, a weight matrix flattened into an array, the target number of nodes, a bias value, and an activation function name. It computes per
Calculates three weighted moving averages (11-period, 48-period, and 200-period WMAs) to evaluate market trend conditions directly on the price chart. It monitors crossovers between price and WMAs as well as crossovers between the moving averages themselves to
This indicator computes moving average and RSI bias signals across the current timeframe and four higher timeframes. It sums biases from the MA and RSI to derive an overall bullish or bearish signal. The results appear in a configurable table that displays eac
This indicator calculates key support and resistance levels by analyzing the first and second momentum derivatives of a Double Exponential Moving Average (DEMA). When the second derivative (momentum of momentum) crosses zero, it identifies local turning points
AlphaTrend calculates a trailing trendline using ATR bands combined with momentum or volume filters (MFI by default, or RSI when volume data is disabled). It plots the AlphaTrend line alongside a two-bar delayed reference line directly on the price chart. The
The Chande Forecast Oscillator plots the percentage difference between the selected source and a linear-regression forecast of that source. It fits slope and intercept over the chosen period using incremental sums, then expresses the forecast error as a percen
This indicator plots volume as columns in a separate pane. Bar color is the bull input when close is above open and the bear input otherwise. A running count of consecutive volume rises or falls, clamped between one and the gradient-levels setting, sets column
This indicator calculates a Gaussian-weighted moving average of a chosen price source and plots it on the price chart. It builds a finite impulse response window, weights past bars with a normalized Gaussian bell, and returns the weighted mean. Period sets the
Hourly Time Levels plots opening price horizontal lines and text labels at specific user-selected times of the trading day directly on the main price chart. It marks key intraday timestamps such as midnight, market opens, and specific hourly intervals includin
Identifies the two-candle Dark Cloud Cover bearish reversal candlestick pattern on price charts. The indicator evaluates the prevailing trend using optional simple moving averages (SMA 50 or SMA 200) and checks for a strong bullish candle followed by a bearish
This strategy plots on the price chart and trades Donchian breakouts in long or short directions. It sizes each unit from a risk percentage of price and an ATR-based initial stop, then adds units at a fixed ATR step up to a maximum. An ATR trail can exit, and
Calculates the distance between the current price and the opposite end of the latest fair value gap, entering trades on the expectation that price will partially fill the gap. It incorporates risk management with customizable stop loss, take profit based on ri
This indicator classifies market state into bull, bear, or neutral regimes using three moving averages and ATR-based stop bands plotted directly on the price chart. It evaluates alignment across customizable MA types (SMA, EMA, DEMA, TEMA, or JMA) and filters
Average True Range V2 calculates market volatility using customizable moving average smoothing methods, including RMA, SMA, EMA, and WMA. Drawn in a separate pane, it offers options to wait for bar confirmation before updating values and can invert the ATR sca
This strategy combines Opening Range Breakout (ORB) mechanics with Inner Circle Trader (ICT) concepts like Fair Value Gaps, Order Blocks, and liquidity grabs. It identifies session opening ranges and generates signals when price breaks out with supporting rela
The VuManChu B Divergences indicator combines a WaveTrend oscillator with a Money Flow Index calculation to analyze market momentum and volume flow. It plots dual WaveTrend curves alongside overbought and oversold levels in a separate indicator pane, highlight
This indicator plots two multi-timeframe exponential moving averages on the price chart and calculates a MACD from the chart source. It marks Long when the shorter-timeframe EMA is above the longer one and a counted sequence of MACD and signal crosses reaches
This strategy calculates fast and slow exponential moving averages, the Relative Strength Index, and the Average True Range directly on the price chart. It enters long positions when the fast EMA crosses above the slow EMA with RSI above the minimum threshold
This overlay indicator draws supply and demand zones from prior swing highs and lows, treating supply as resistance and demand as support. It places price-action labels at swing points using higher-high, lower-high, higher-low, and lower-low tags. It also plot
Price Action Market Structure Sweeps identifies swing and internal market structure events, including Break of Structure (BOS) and Change of Character (CHoCH). It overlays key high and low levels across daily, weekly, monthly, and yearly timeframes, while mark
This overlay indicator detects price contractions from confirmed pivot highs and lows. When price later breaks above the contraction high or below the contraction low, it draws a bullish or bearish box between those extremes and a midline at their average. Sep
This Pine Script v5 library exports SwitchingColorMode, which takes a color and a mode string and returns a theme-adjusted color. It reads red, green, blue, and transparency, classifies brightness into coarse channel buckets, and labels the color as hard dark,
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.