Pine Library · 4,367 open-source scripts

Free Pine Script v6 Scripts (page 84)

Scripts written for Pine Script version 6, the current version of TradingView's language. They paste into the Pine Editor and run as they are.

Pine scripts4,367
Code shown here2,412open licence
Updated in a year4,021
No repaint flag3,857

Pine Script v6: Indicators, Strategies and Libraries

Hann FIR Filter (HANN)

by mihakralj
99 stars

This indicator calculates a finite impulse response filter using Hann window coefficients and plots the smoothed series on the price chart. It weights the selected source with a raised-cosine window over the chosen length and divides by the sum of the weights.

Indicator v6 TrendMoving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of Hann FIR Filter (HANN)
1 stars

This validation strategy tests broker execution priority when opposing pending stop orders are active simultaneously. At scheduled times (02:45 and 14:45), when flat, it places paired long and short stop orders at percentage offsets from the closing price. Pos

Strategy v6 BreakoutSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 80 - Dual Stop Priority

The Bear Crossover

by vedkanani123
1 stars

A simple moving average crossover indicator drawn on the price chart. It plots an 11-period and a 51-period exponential moving average. A BUY label appears when the fast line crosses above the slow line on a bullish candle, and a SELL label appears when it cro

Indicator v6 Moving averagesTrend
Updated 2 months ago · None stated GitHub repository of The Bear Crossover
99 stars

This indicator calculates the harmonic mean of a source series over a rolling lookback and plots the result in a separate pane. It stores recent values in a circular buffer, updates a running sum of reciprocals, and returns the count of valid samples divided b

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Harmonic Mean (HARMEAN)
1 stars

This Pine Script v6 strategy is a validation probe that places competing stop entries close to price. At 02:45, while flat, it submits a long stop slightly above the close and a short stop slightly below the close. At 06:15, if a position is open, it closes ev

Strategy v6 BreakoutSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 81 - dual stop near only

TL Range X V3

by vedkanani123
1 stars

An indicator for the price chart that builds a ladder of resistance and support levels from a daily range divided by a divisor, measured from the daily, weekly or monthly open, with extra levels unlocking on strong runs and optional Fibonacci lines inside each

Indicator v6 Support & resistanceSessions & time Repaints
Updated 2 months ago · None stated GitHub repository of TL Range X V3

This indicator calculates Vitali Apirine's Higher Highs and Lower Lows Stochastics (HHLLS). It evaluates conditional stochastic formulas that trigger only on bars establishing higher highs or lower lows, then smooths both values using an Exponential Moving Ave

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Higher Highs & Lower Lows Stochastics (HHLLS)
1 stars

This strategy places two stop orders at 14:45 when flat: a long stop slightly above the close and a short stop slightly below it. Whichever stop fills first opens the position. At 18:15 it closes any open position. Quantity is fixed at one, with zero commissio

Strategy v6 BreakoutSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 82 - dual stop far only

Trend Context

by vedkanani123
1 stars

A price-chart indicator that classifies the market as up, down or neutral using an adaptive baseline whose smoothing speed follows price efficiency. A weighted score combines price location against ATR zones, baseline slope, momentum and position within the re

Indicator v6 TrendVolatility & bands
Updated 2 months ago · None stated GitHub repository of Trend Context
1 stars

A strategy on the price chart that builds a four-point audit score from a higher-timeframe EMA, fast versus slow moving average, volume against its average, and bar movement against ATR. When the score reaches a minimum, it logs a message and moves through enu

Strategy v6 TrendMoving averages
Updated 2 months ago · None stated GitHub repository of TN Universal Sovereign
99 stars

This indicator plots the highest value of a chosen source over a rolling lookback. It maintains a monotonic deque and a circular buffer so each bar updates the window maximum. The period input sets the lookback length and the source input selects the series, d

Indicator v6 Support & resistance
Updated 4 weeks ago · Apache-2.0 GitHub repository of Highest Value (HIGHEST)
1 stars

This Pine Script strategy draws on the price chart with overlay=true. It enters long and short positions using stop orders at the current close price at specific session times of 4:45 and 16:45. It then closes all open positions at 8:15 and 20:15. The strategy

Strategy v6 Sessions & timeScalping
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 83 - dual stop open tie

Uptrick Vector Trail Trend

by vedkanani123
1 stars

A price-chart indicator that estimates trend with a smoothed velocity and a projected vector, then draws an ATR-based trailing line coloured by direction. Up and down signals appear on trend changes. Optional dynamic take-profit markers use momentum and a Z-sc

Indicator v6 TrendVolatility & bands
Updated 2 months ago · None stated GitHub repository of Uptrick Vector Trail Trend
1 stars

This strategy detects value area rejections on the price chart. It calculates a fair value midpoint using a simple moving average of length 50 and ATR-based bands. Bullish and bearish rejection signals trigger when price crosses the value area boundaries and c

Strategy v6 Mean reversionVolatility & bands
Updated 2 months ago · None stated GitHub repository of Tn Value Area Rejection v6

This indicator calculates the Hilbert Transform Dominant Cycle Phase based on John Ehlers' cycle analytics and the TA-Lib algorithm implementation. It processes price through a four-tap weighted smoothing filter, a Hilbert finite impulse response detrender, in

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Hilbert Transform Dominant Cycle Phase (HT_DCPHASE)
1 stars

A test strategy from a reference corpus that checks whether the order in which two stop entries are submitted changes which one fills. At 02:45 it submits a long stop 0.2 percent above the close, then a short stop 0.2 percent below. Any open position is closed

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 84 Dual Stop Long First
1 stars

A price-chart indicator by BigBeluga that draws a custom volatility-based Supertrend with an optional shaded trend cloud, and marks order blocks at confirmed swing pivots. Each block shows its buy and sell volume percentage. Blocks can be removed once price br

Indicator v6 SMC / ICT / price actionTrend
Updated 2 months ago · None stated GitHub repository of Volume-Trend Order Block Engine
1 stars

A strategy that sorts the market into quiet, active and extreme regimes using ATR as a percentage of price against two thresholds. Position size is 15 percent of equity in quiet markets, 25 percent in active ones, and zero in extreme ones. Entries are long onl

Strategy v6 Volatility & bandsTrend
Updated 2 months ago · None stated GitHub repository of TN Volatility Regime Sovereign
99 stars

This indicator calculates a causal approximation of the Hodrick-Prescott filter. It plots a smoothed trend of the selected source and a cycle equal to the source minus that trend. Lambda controls smoothing; the source defaults to close. The trend is drawn on t

Indicator v6 Trend
Updated 4 weeks ago · Apache-2.0 GitHub repository of Hodrick-Prescott Filter (HP)
1 stars

This validation probe strategy tests how TradingView handles dual stop-order priority based on script source order. At a fixed time of 02:45, when no position is open, it submits a short stop order below the close followed by a long stop order above the close.

Strategy v6 BreakoutSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 85 - Dual Stop Short First

VWMA True Range

by vedkanani123
1 stars

A separate-pane indicator that applies a volume-weighted moving average to true range over a chosen period, with optional smoothing. Long and short thresholds set when the reading counts as a bullish or bearish state. Options include a fast Hull line, a band d

Indicator v6 Volatility & bandsVolume
Updated 2 months ago · None stated GitHub repository of VWMA True Range

Huber Loss (HUBER)

by mihakralj
99 stars

This indicator calculates Huber loss between a selected source and an exponential moving average of that source. Inside the delta threshold it uses half the squared error; beyond delta it uses a linear absolute-error form. It averages those values over the cho

Indicator v6 Moving averages
Updated 4 weeks ago · Apache-2.0 GitHub repository of Huber Loss (HUBER)

PF Probe 86 Dual Stop Low First

by pineforge-4pass
1 stars

A test strategy from a reference corpus that places a long stop and a short stop at the same time, 0.2 percent above and below the close of the 02:45 bar. It only does so on bars where the open is nearer to the low than to the high, so the price path is expect

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 86 Dual Stop Low First
1 stars

A gold-focused price-chart indicator that measures rolling correlation between the chart symbol and the dollar index, and when the correlation is inverse enough it generates signals from RSI crossing its oversold and overbought levels. It adds a Supertrend tre

Indicator v6 TrendOscillators & momentum
Updated 2 months ago · None stated GitHub repository of Wake Up, Neo Gold/DXY Confluence
1 stars

The script calculates the yield spread between long-term and short-term US Treasury yields (T10Y2Y or manual US10Y minus US02Y) and plots the spread line on a separate pane. It signals long entries on steepening beyond a user threshold in reversion mode or SMA

Strategy v6 Mean reversionSupport & resistance
Updated 2 months ago · None stated GitHub repository of TN Yield Spread Sovereign v6

Hurst Exponent (HURST)

by mihakralj
99 stars

Calculates and plots the Hurst Exponent to quantify the persistence, mean-reverting tendencies, or random walk characteristics of a time series. It computes logarithmic returns, segments the lookback window into sub-periods to determine rescaled range statisti

Indicator v6 TrendMean reversion
Updated 4 weeks ago · Apache-2.0 GitHub repository of Hurst Exponent (HURST)
1 stars

A test strategy from a reference corpus that places a long stop and a short stop at the same time, 0.2 percent above and below the close of the 02:45 bar. It only does so on bars where the open is nearer to the high than to the low, so the price path is expect

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 87 Dual Stop High First

TN_CMO_v26

by raybird
1 stars

The TN_CMO_v26 strategy calculates the Chande Momentum Oscillator and applies causal divergence filters against price action within a trend regime defined by a 200-bar EMA. It generates long entries on bullish divergence or CMO crossing above negative extreme

Strategy v6 DivergenceOscillators & momentum Repaints
Updated 2 months ago · None stated GitHub repository of TN_CMO_v26

Ichimoku Cloud

by mihakralj
99 stars

This indicator plots the five classic Ichimoku components on the price chart. It calculates Tenkan-sen, Kijun-sen, and Senkou Span B as midpoints of the highest high and lowest low over their periods, then derives Senkou Span A from Tenkan and Kijun. Chikou Sp

Indicator v6 TrendSupport & resistance
Updated 4 weeks ago · Apache-2.0 GitHub repository of Ichimoku Cloud
1 stars

This strategy places long and short entries on the price chart at fixed daily times of 8:00 and 20:00. It uses fixed position sizing of 1 share with pyramiding set to 1, so only one position is held. At entry it immediately sets a three-way bracket exit that i

Strategy v6 ScalpingSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 88 - 3-way exit set once

TnS_ICT_Combo_V6

by raybird
1 stars

TnSovereignIctComboV6 is a multi-confluence ICT SMC strategy on the price chart. It calculates HTF EMA bias, killzone sessions, FVG detection, liquidity sweeps, market structure shifts, premium discount arrays and V17 fractal gate to achieve minimum confluence

Strategy v6 SMC / ICT / price actionTrend
Updated 2 months ago · None stated GitHub repository of TnS_ICT_Combo_V6

Inertia Oscillator

by mihakralj
99 stars

This indicator calculates the Inertia Oscillator, measuring market trend strength based on the distance between price and its linear regression value. Over a user-defined length and price source, it computes the linear regression line and calculates the curren

Indicator v6 TrendOscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Inertia Oscillator

This Pine Script strategy acts as a validation probe to examine TradingView order execution when using trail_points without an explicit trail_offset. It enters a long position at 08:00 and a short position at 20:00 when flat, setting wide 5% protective stop-lo

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 89 - trail_points 8 + far stop/limit

TnS_ICT_V20

by raybird
1 stars

TnS_ICT_V20 is a Pine Script v6 strategy that identifies institutional trading opportunities using ICT concepts. It calculates pivot swings as support and resistance levels, OTE zones, and a thermodynamic audit based on free energy and fractal entropy to filte

Strategy v6 SMC / ICT / price actionTrend
Updated 2 months ago · None stated GitHub repository of TnS_ICT_V20
99 stars

This indicator calculates the interquartile range of a chosen price source over a lookback window. It estimates the 25th and 75th percentiles with linear interpolation, then plots their difference as a line in a separate pane. The source and lookback period ar

Indicator v6 Volatility & bands
Updated 4 weeks ago · Apache-2.0 GitHub repository of Interquartile Range (IQR)
1 stars

This strategy is a validation probe that places one long at 08:00 and one short at 20:00 when flat, using a fixed quantity of one. Each entry is paired with a stop 10 price units away, a limit 20 units away, and a trailing stop of 8 points. Orders process on b

Strategy v6 ScalpingSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 90 - narrow stop/limit + trail8

TnS_ICT_V6

by raybird
1 stars

TnS_ICT_V6 is a Pine Script v6 strategy that identifies liquidity sweeps and displacement moves exceeding a multiple of ATR. It detects Fair Value Gaps and Optimal Trade Entries in the 62 to 79 percent retracement zone of the displacement leg to generate buy a

Strategy v6 SMC / ICT / price actionVolatility & bands
Updated 2 months ago · None stated GitHub repository of TnS_ICT_V6
99 stars

The Intraday Momentum Index calculates an oscillator bounded between 0 and 100 based on intraday price movement. It measures gains when the close is higher than the open and losses when the close is lower than the open over a set lookback period. Computed usin

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Intraday Momentum Index (IMI)
1 stars

This strategy is a validation probe that opens one long at 08:00 and one short at 20:00 when the position is flat. Each entry sets an ATR-based stop, a limit at twice that stop distance, and a trailing stop whose trail points equal the current ATR. ATR length

Strategy v6 Volatility & bandsSessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 91 - atr trail fixed entry

TnS_IctCombo_V6

by raybird
1 stars

This Pine Script strategy identifies high-confluence trading opportunities using ICT and SMC logic. It calculates a confluence score from HTF bias via EMA, FVG detection with lookback, liquidity sweep confirmation, market structure shift breaks, premium discou

Strategy v6 SMC / ICT / price actionTrend Repaints
Updated 2 months ago · None stated GitHub repository of TnS_IctCombo_V6

This indicator reconstructs a low-pass filtered series from the selected source using a discrete Fourier transform. It applies a Hann window over a fixed window of 32, 64, or 128 bars, keeps only the chosen number of lowest-frequency harmonics, and adds their

Indicator v6 Trend
Updated 4 weeks ago · Apache-2.0 GitHub repository of Inverse Fast Fourier Transform (IFFT)
1 stars

This validation strategy tests position reversal mechanics via stop orders without explicit closing calls. It executes a long market entry at 00:15 when flat, then submits a short stop entry just below the bar low at 00:45 to trigger an automated position flip

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 92 - flip stop no paired close

TnS_StochDiv_V6

by raybird
1 stars

This Pine Script strategy detects causal reversals using a smoothed stochastic oscillator to track momentum. It identifies harmonic divergences in price versus the oscillator and applies a Kronos resonance proxy based on phase coherence. ATR dynamically sets s

Strategy v6 Oscillators & momentumDivergence
Updated 2 months ago · None stated GitHub repository of TnS_StochDiv_V6

Jarque-Bera Test (JB)

by mihakralj
99 stars

Jarque-Bera Test evaluates whether price data follows a normal distribution. It constructs a rolling array of recent bars to compute sample mean, variance, skewness, and excess kurtosis through central statistical moments. The calculated statistic quantifies d

Indicator v6
Updated 4 weeks ago · Apache-2.0 GitHub repository of Jarque-Bera Test (JB)
1 stars

This validation strategy tests TradingView order execution behavior and position sizing during stop-entry position flips when pyramiding is set to 2. It opens long entries at specific times of day (0:15 and 6:15), sets opposite stop orders paired with exit com

Strategy v6 Sessions & time
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 93 - flip stop pyramiding 2

More Pine Script Categories

Browse the whole Pine Library

Third-party code. ForexR lists open-source Pine scripts from GitHub; it did not write, test or endorse them, and their summaries are generated automatically from each script's code and README. Indicators describe the past, and a strategy's backtest can look better than live trading. Check a script on a demo account before you rely on it. CFDs and leveraged forex are complex instruments with a high risk of losing money rapidly.

Learn to Use Pine Scripts

Free, plain-English guides: add a script to TradingView, read what it does, test it and avoid the common traps.

  1. 1Using this librarySearch, filters, licences and what the badges mean.
  2. 2Add a script to TradingViewCopy, paste into the Pine Editor, save and add to chart.
  3. 3Indicators, strategies and librariesWhat each type does and how to tell them apart.
  4. 4Spot a script that repaintsWhy some signals change after the bar closes.
  5. 5Backtest a strategyStrategy Tester settings that keep results honest.
  6. 6Send alerts to MT4 or MT5From a TradingView alert to an order in MetaTrader.
  7. 7What Pine Script isThe language, what it can and cannot do, and where to start.
  8. 8Write your first indicatorA complete script, line by line, in the Pine Editor.
  9. 9Read a script before you trust itA routine for checking inputs, logic and red flags.
  10. 10Edit a script safelyChange colours and lengths, add a filter or an alert.
  11. 11Pine Script alertsalertcondition(), alert(), placeholders and webhooks.
  12. 12Build a crossover strategyAn EMA cross strategy with an ATR stop, ready to test.

Trade Your Charts With a Regulated Broker

Compare regulated brokers on platforms, spreads, minimum deposit and leverage.

Compare brokers