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 up to four customizable moving averages directly on the price chart to create a ribbon visualizer for tracking trends. Users can independently toggle each line, choose from multiple calculation types including SMA, EMA, SMMA, WMA, and VWMA
This strategy monitors section height changes within the Squeeze Momentum Indicator to identify momentum shifts and divergence entry signals. It uses high and low closing moving averages to evaluate price trends and overlay a visual ribbon on the price chart.
Trade Permission Engine evaluates whether market structure currently permits long or short trades, alongside a decoupled Position Health score for managing existing positions. It analyzes alternating confirmed swing legs, Fibonacci retracement depths, time mat
This indicator colors price chart candles according to trading volume relative to a simple moving average. It classifies volume into five distinct tiers ranging from low to ultra using customizable multiplier thresholds. Candles are painted directly on the mai
This indicator tracks a sequential smart money concepts workflow using a state machine on the price chart. It monitors higher-timeframe four-hour bias, Asian session ranges, liquidity sweeps, market structure shifts, change in state of delivery, and fair value
Indicatorv5SMC / ICT / price actionSessions & time
The ID50 indicator identifies pullback opportunities to the 50-period exponential moving average (EMA) within an established trend. It plots a fast EMA and a slow EMA with a color-coded cloud between them to define trend direction. When price touches the slow
This indicator simulates and backtests candlestick pattern performance directly on the price chart. Utilizing an imported pattern recognition library, it calculates theoretical trade outcomes based on user-defined entry modes, stop-loss methods (ATR or pattern
The Weighted Moving Average indicator computes a weighted average of price data using an optimized circular buffer for efficient calculation. It plots the WMA line on the price chart as an overlay. The period setting determines the lookback window, and the sou
This strategy is a validation probe designed to test order execution behavior when issuing bracket exit orders while flat alongside a pending limit entry. It calculates 9-period and 21-period exponential moving averages on price data. On a bullish EMA crossove
Trend Breakout is a price-chart strategy that builds a simple moving average and upper and lower bands from a multiple of standard deviation. It enters long when close crosses above the upper band and short when close crosses below the lower band. Position siz
The Golden Spiral indicator calculates and draws logarithmic Fibonacci spiral projections in a separate pane. Centered at a user-defined bar timestamp, it plots forward and backward spiral curves using customizable turns, step resolution, and X/Y axis scaling.
A price-chart indicator that marks only buy and sell labels, with no trail, cloud or dashboard. A signal closes any opposite position and flips direction. It combines a fast zero-lag EMA, slow EMA, Hull average and macro EMA with slope, separation, ADX, DMI sp
Overlay indicator that combines several detection pipelines on the price chart: high-volume candles with large displacement, a PBJ trend filter built from a moving average and Supertrend, and relative-volume lanes. Markers appear when these conditions coincide
Tn Sovereign FlowZone v6 is a strategy script that plots signals on the price chart using EMA crossovers combined with confluence scoring. The script calculates confluenceScore from trend EMA, volume SMA comparison, and RSI momentum to confirm EMA20/50 crossov
This indicator applies an RSI-style oscillator smoothed with a cyclic filter, based on the dominant cycle idea from a published trading book. A Fast Fourier Transform library measures cycle strength, and a table lists the strongest cycle periods. This second v
Compares normalised volatility across a fixed list of Moscow Exchange stocks and funds in a separate pane. For each symbol it requests a 14-period ATR expressed as a percentage of close and plots it as a line, drawing the line more strongly when the value is a
DSM-tracker is an overlay indicator that marks ARK Invest activity on the price chart. In the supplied code it draws one green label below the bar on 17 January 2020 reading Buy X1 when the ETF input is ALL. That input offers only the ALL choice, so it does no
This demonstration script implements a custom FIFO array push function in Pine Script v4. It maintains a fixed-length array of closing prices by popping the oldest value and inserting the newest close at the front index. The script plots the newest price eleme
This strategy calculates normalized price or on-balance volume differentials across a user-defined timeframe and passes them through an activation function such as Swish, Step, or LeakyReLU. It opens long positions when the activated vector crosses above a pos
This long-only strategy enters when a 14-period simple moving average crosses above a 28-period average and closes that long when the faster average crosses back below. While a position is open, it sets a stop a configurable percent below the entry, then moves
This indicator calculates market cycle phase using John Ehlers' Phasor Analysis methodology. It correlates the price series against cosine and negative-sine reference waves via dual Pearson correlation to extract real and imaginary phasor components. From thes
This strategy demonstrates staged long entries and a bracket exit on the price chart. It opens a first long of five units when the position is flat and the year is after 2014. When size reaches five, it adds a second long of ten units with a stop price ten per
This indicator plots a trimmed mean moving average of the close on the price chart. It sorts each lookback window, drops a user-set percentage of the lowest and highest values from each tail, and averages the remaining middle portion. Period sets the window le
This indicator calculates a weighted moving average of a chosen price source and plots the result on the price chart. It uses TradingView's built-in weighted moving average function, so more recent bars receive greater weight than older bars. Length sets the n
Ruckard Squeezed E004 is a price-chart strategy that compares successive Squeeze Momentum colour-section changes. A smaller squeeze value with a higher price opens a short; a higher squeeze value with a lower price opens a long. Direction can be limited to lon
This overlay indicator detects a trading range from clustered pivots, falling back to the highest and lowest prices over a lookback, and scores it with eight weighted factors. The score moves the range through Inactive, Building, Confirmed, Mature, and Breakin
This overlay indicator builds a volume histogram of recent bars across user-defined price bins and draws it on the price chart. A Gaussian spread smooths volume around detected cluster peaks, and the highest enhanced bin is plotted as the current point of cont
This overlay indicator walks price through a configurable ICT state sequence on the chart. It can require a four-hour CRT bias, an Asian range, manipulation, a New York macro window, a liquidity sweep, a market structure shift, CISD, a fair value gap, and a re
Indicatorv5SMC / ICT / price actionSessions & time
Imagegpt Test 1 is a comprehensive chart overlay indicator that plots buy, sell, and reversal signals along with supply and demand zones. It calculates key levels using volume pivots and features integrated Bollinger Bands alongside entry, exit, stop-loss, and
This indicator draws an equity factor dashboard in a separate pane. It can show a correlation table over a chosen length and a performance table based on rate of change or Sharpe ratio. Optional implied correlation plots, including single and double normalizat
This script calculates and plots Wilder's Relative Moving Average (RMA) of a chosen source over a user-defined period. It applies an optimized exponential warmup compensator to ensure accurate early bar values while maintaining O(1) computational complexity. T
The strategy applies the Parabolic SAR indicator to detect trend reversal flips. It monitors when the SAR crosses from above to below the close (bullish flip) to enter long positions or from below to above (bearish flip) to enter short positions. Opposite posi
This indicator acts as a test probe to verify Pine Script v5 language features within an offline engine. It tests custom enum declarations, enum inputs, string formatting, functions, collections, and historical enum referencing. In addition, it constructs symm
This overlay indicator draws golden and optional symmetric spirals between two user-selected time and price anchors on the price chart. It measures the selected range, counts green, red, and total candles, and sums their high-to-low heights, then uses the chos
A price-chart indicator that prints buy and sell labels aimed at one larger intraday price move per UTC day, with the target size set in price units. A first signal can come from a trend breakout or a completed Asia range break, optionally preferring the day-o
Overlay indicator that looks for co-occurrence of high-volume displacement candles and a PBJ trend filter, then marks the result on the price chart. Both bullish and bearish pattern families are included, with toggles for UUUU, UUU, UU and Omega variants. Sett
The TN Sovereign Footprint POC v6 strategy calculates a simulated Point of Control by identifying the highest volume node in a lookback period using the average of high, low, and close prices. It plots on the price chart as an overlay and signals buy or sell e
This indicator plots a cyclic smoothed RSI in a separate pane, with a dominant cycle length, a maximum cycle and a divider as inputs, plus vibration and leveling values. Two signal lines use selectable moving average types with automatic or manual lengths, and
Draws step-line bands around each candle on the price chart, sized from a rolling median of previous true range or candle body range. Two divisors set the band width for the high and low range and for the body range; the body version is shown by default and th
DSY-tracker is an overlay indicator that marks recorded ARK Invest purchases of DSY on the price chart. When the ETF input is set to ALL, it places green buy labels below bars on a fixed list of dates beginning in November 2019. The ETF setting switches the di
This indicator implements a K-means clustering algorithm in Pine Script to partition two-dimensional data points into user-defined clusters. It features an internal pseudo-random number generator for centroid initialization and computes Euclidean distances acr
Sequential Indicator normalizes price data within a configurable lookback window using min-max scaling and applies linear regression smoothing. It tracks the number of bars elapsed since the smoothed values crossed upper, middle, or lower threshold conditions.
The Breakeven Line Demo strategy is a Pine Script demonstration tool designed to visualize the average position price of stacked trades. It enters long positions after seven consecutive bearish candles and short positions after seven consecutive bullish candle
Calculates John Ehlers' Recursive Median Filter, a nonlinear filter combining a 5-bar running median with exponential smoothing to reduce impulsive noise while maintaining responsiveness. The smoothing factor is calculated from the cycle period setting using E
This strategy demonstrates a partial bracket exit. It enters a long position of four units when the current position size is zero or negative. It then places an exit for two of those units, with a ten-point profit target and a ten-point stop. There are no user
The TRIX indicator calculates the percentage rate of change of a triple-smoothed exponential moving average (EMA) applied to a selected price source. It incorporates explicit warm-up logic to ensure stable runtime initialization without relying on uncompensate
This strategy calculates a simple moving average of closing prices to detect trend shifts directly on the price chart. It enters a long position when the price remains above the moving average for a specified number of consecutive confirmation bars, and enters
Calculates divergence between price movement and the Squeeze Momentum Indicator transitions to identify entry conditions. A short position is opened when the squeeze value decreases while price makes a higher high during bullish momentum decay. A long position
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.