Pine Library · 3,870 open-source scripts

Free Trend Pine Scripts (page 75)

Open-source Pine scripts that show the direction of the trend or trade with it: Supertrend variants, moving-average systems, ADX and trend filters.

Pine scripts3,870
Code shown here2,160open licence
Updated in a year2,525
No repaint flag3,292

Trend: Indicators, Strategies and Libraries

1 stars

An overlay indicator that uses a wide SuperTrend-style trail with a zero-lag bias to print always-in buy and sell flips while ignoring small moves. Settings set the trail factor, price smoothing, minimum bars between flips, a break buffer and a minimum adverse

Indicator v5 TrendVolatility & bands
Updated 2 months ago · None stated GitHub repository of Nexus Prime Engine v2.1 Anti-Noise

This strategy calculates an Adaptive Hull Moving Average (HMA+) that dynamically adjusts its period based on market volatility measured by fast and slow ATR indicators. It uses slope angle calculations to categorize market conditions into trending, consolidati

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of 72s Strategy: Adaptive Hull Moving Average+ pt.1
99 stars

The Jurik Composite Fractal Behavior indicator computes a weighted average of efficient trend lengths as a composite fractal behavior value, also known as the trend duration index. It processes a user-specified source series using a max lookback length and cal

Indicator v6 TrendOscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Jurik Composite Fractal Behavior

Trailering T002

by ruckard
13 stars

This automated trading strategy operates in a separate pane and is designed to integrate with Zignaly copy-trading and profit-sharing webhooks. It focuses on long positions, adjusting position size based on the number of triggered sub-strategy consensus condit

Strategy v5 Trend
Updated 1 year ago · None stated GitHub repository of Trailering T002

SMC LuxMod Nuburo5

by alboogycOdR
6 stars

This Smart Money Concepts indicator highlights market structure and institutional levels on the main price chart. It detects internal and swing structure breaks (BOS) and character changes (CHoCH), along with strong or weak high and low points. The script iden

Indicator v5 SMC / ICT / price actionSupport & resistance Repaints
Updated 7 months ago · None stated GitHub repository of SMC LuxMod Nuburo5

The Parallel Price Universe Oscillator calculates detrended price movements relative to two derived moving averages weighted by fast and slow Fibonacci ratios. It extracts smoothed angular slopes using arctangent functions, aggregates them into a unified momen

Indicator v5 Oscillators & momentumMoving averages
Updated 7 weeks ago · None stated GitHub repository of Parallel Price Universe Oscillator
1 stars

TnSovereign Fakeout Filter V6 is a trend-following strategy designed to reduce false breakouts by evaluating entries against a four-layer scoring system. It checks fast and slow EMA crossovers alongside volume surges, higher-timeframe trend alignment, and ATR

Strategy v6 TrendMoving averages Repaints
Updated 2 months ago · None stated GitHub repository of TnSovereign Fakeout Filter V6

8 Day Run

by hasnocool
106 stars

Inspired by Linda Raschke's strategy for T-note futures, this script identifies extended trends where price remains on one side of a 5-period SMA for more than eight consecutive bars. It enters long on the first pullback below the SMA following an eight-bar bu

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of 8 Day Run

DMX plots the Jurik Directional Movement Index in a separate pane. The indicator computes a smoothed version of the directional movement index using Jurik smoothing applied to the ADX components derived from true range, up and down directional moves. It applie

Indicator v6 TrendOscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Jurik Directional Movement Index (DMX)

My Strategy

by be-thomas
65 stars

This strategy plots on the price chart and compares a 14-period simple moving average of close with a 28-period simple moving average. It opens a long when the faster average crosses above the slower average and opens a short when the faster average crosses be

Strategy v4 TrendMoving averages
Updated 5 days ago · GPL-3.0 GitHub repository of My Strategy

SMC Mod Nuburo 5

by alboogycOdR
6 stars

The indicator plots Smart Money Concepts market structure directly on the price chart. It detects real-time internal and swing structure breakouts, including Break of Structure and Change of Character, along with strong and weak high or low levels. It identifi

Indicator v5 SMC / ICT / price actionSupport & resistance Repaints
Updated 7 months ago · None stated GitHub repository of SMC Mod Nuburo 5

8 Whittle Down

by hasnocool
106 stars

This strategy executes short positions during the end-of-day session (14:29–15:00) when the price is below the 200-day simple moving average. If price moves higher against the initial short trade, it scales into the position by submitting a second short order

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of 8 Whittle Down
6 stars

SMC Scalping State Engine v2.2.1 is a Pine Script v5 strategy that plots Smart Money Concepts elements on the XAUUSD price chart. It uses a state transition system to detect market structure breaks, order blocks, fair value gaps, key levels and EMA alignments

Strategy v5 SMC / ICT / price actionTrend
Updated 7 months ago · None stated GitHub repository of SMC Scalping State Engine v2.2.1

MicroQuant Trend

by g-moe
3 stars

MicroQuant Trend is a Supertrend-based indicator that calculates dynamic bands using EMA of high and low prices adjusted by ATR. It plots green circles for uptrend direction and red for downtrend. Background colors change to green or red when the trend flips.

Indicator v5 TrendMoving averages
Updated 5 months ago · None stated GitHub repository of MicroQuant Trend
1 stars

The indicator combines pivot high and low points with multi-period slope and momentum analysis to identify market trends and range conditions. It calculates short- and medium-term price slopes, EMA slopes, and price acceleration against a statistical Z-Score t

Indicator v5 TrendOscillators & momentum
Updated 7 weeks ago · None stated GitHub repository of POT {Morindok} by @BITMOON618

888 BOT Backtest

by hasnocool
106 stars

888 BOT Backtest is a multi-indicator trading strategy that evaluates market conditions by combining a Jurik Moving Average, Range Filter, Average Directional Index (ADX), Parabolic SAR, volume-weighted RSI, MACD, and volume thresholds. Each individual filter

Strategy v4 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of 888 BOT Backtest

Kalman Filter (KALMAN)

by mihakralj
99 stars

This indicator applies a one-dimensional Kalman filter to a chosen price source and plots the filtered series on the price chart. Process noise and measurement noise set how quickly the estimate follows new data versus how much it trusts the measurement. The f

Indicator v6 Trend
Updated 4 weeks ago · Apache-2.0 GitHub repository of Kalman Filter (KALMAN)
3 stars

MicroQuant Trend Strat is a trend-following strategy overlaid on the price chart that utilizes a modified Supertrend calculation built with EMA bands and Average True Range volatility bounds. It opens long positions when the trend direction turns bullish and s

Strategy v5 TrendVolatility & bands
Updated 5 months ago · None stated GitHub repository of MicroQuant Trend Strat
1 stars

This strategy identifies trend changes using a dual moving average crossover. It computes fast and slow simple moving averages of the close price and generates long entry signals on fast SMA crossover above slow and short signals on crossover below. Upon entry

Strategy v6 Moving averagesTrend
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 97a - tp/sl bracket isolate

PPUO Forecast Signals

by morindok
1 stars

The PPUO Forecast Signals indicator derives a Parallel Universe Oscillator from detrended price series using slow and fast moving averages of varying lengths. It extracts smoothed angles from the detrended values, weights and aggregates them into a universe me

Indicator v5 TrendOscillators & momentum
Updated 7 weeks ago · None stated GitHub repository of PPUO Forecast Signals
1 stars

An overlay indicator that tries to show only larger reversals through a very wide ATR trail. A main buy or sell requires a trail break with confirmation closes, a swing high or low break, minimum travel from the last flip, and a minimum pullback from the leg p

Indicator v5 TrendVolatility & bands
Updated 2 months ago · None stated GitHub repository of Nexus Prime Engine v6 Major Only
106 stars

This strategy calculates an exponential moving average smoothed Vortex Indicator and plots the positive and negative vortex lines alongside a threshold in a separate pane. It enters long when the difference between VI+ and VI- crosses above a specified positiv

Strategy v4 Oscillators & momentumTrend
Updated 2 years ago · GPL-3.0 GitHub repository of [Guz] Vortex Indicator Custom V2

Vortex Indicator

by TWODS-CAPITAL
37 stars

This indicator plots the standard Vortex Indicator lines in a separate pane to identify trend direction and momentum. It calculates positive trend movement and negative trend movement relative to the true range over a user-defined length. The script outputs tw

Indicator v5 TrendOscillators & momentum
Updated 3 years ago · MIT GitHub repository of Vortex Indicator

Traiversal A001

by ruckard
13 stars

Traiversal A001 is a breakout reversal strategy designed primarily for cryptocurrency trading. It identifies reversal entry opportunities three candles following a breakout and closes positions when a breakout in the opposite direction occurs. The script inclu

Strategy v5 BreakoutMean reversion
Updated 1 year ago · None stated GitHub repository of Traiversal A001
3 stars

This strategy executes trades based on a modified Supertrend indicator combining exponential moving averages, price channels, and ATR bands. It enters long positions when the trend direction turns bullish and short positions when it turns bearish, filtered by

Strategy v5 TrendVolatility & bands
Updated 5 months ago · None stated GitHub repository of MicroQuant Trend Strat +TS
2 stars

This indicator adapts the classic MACD structure by replacing exponential moving averages with median calculations. It computes a fast median and a slow median of price, takes their difference to form the MCD line, and calculates a median-based signal line. Th

Indicator v5 Oscillators & momentumTrend
Updated 8 months ago · None stated GitHub repository of Median Convergence Divergence
1 stars

This strategy identifies long and short positions using a dual moving average crossover on the price chart. The fast and slow simple moving averages generate crossover signals that trigger market entries. The script caps the number of intraday filled orders to

Strategy v6 Moving averagesTrend
Updated 6 days ago · Apache-2.0 GitHub repository of PF probe 97b - intraday cap isolate

Williams Alligator

by TWODS-CAPITAL
37 stars

This indicator plots Bill Williams' Alligator system directly on the price chart. It calculates three smoothed moving averages based on the median price (hl2) representing the Jaw, Teeth, and Lips lines, each projected forward into future bars via plot offsets

Indicator v5 TrendMoving averages
Updated 3 years ago · MIT GitHub repository of Williams Alligator

UnfairValueGap A004

by ruckard
13 stars

UnfairValueGap A004 is a strategy that identifies value gaps on the price chart and trades based on gap filling dynamics. It calculates the distance between the current price and the far side of a recent gap, taking positions in anticipation of trend continuat

Strategy v5 SMC / ICT / price actionMoving averages
Updated 1 year ago · None stated GitHub repository of UnfairValueGap A004
3 stars

Miller Boy Custom Study calculates a 105-period Simple Moving Average (SMA) of close prices, functioning as a trend baseline. It identifies buy signals when a bar open price crosses above the SMA baseline and sell signals when the open price crosses below it.

Indicator v5 Moving averagesTrend
Updated 5 months ago · None stated GitHub repository of Miller Boy Custom Study

Minervini Qualifier

by regalouisei
2 stars

Calculates Mark Minervini Trend Template criteria to identify stocks in strong uptrends. It evaluates key conditions based on 50-day, 150-day, and 200-day Simple Moving Averages, 52-week high and low price ranges, and relative strength against a customizable r

Indicator v5 TrendMoving averages
Updated 8 months ago · None stated GitHub repository of Minervini Qualifier
1 stars

A basic Supertrend strategy with an optional volume filter, drawn on the price chart. The Supertrend line is calculated from ATR length and multiplier. A long or short entry is taken in the trend direction when volume exceeds a multiple of its moving average,

Strategy v6 TrendVolume
Updated 2 months ago · None stated GitHub repository of TnSovereign Supertrend Volume

This strategy calculates and plots smoothed Heikin-Ashi candles directly onto the main price chart using exponential moving averages of open, high, low, and close prices. It enters a long position after three consecutive bullish smoothed candles with sequentia

Strategy v4 TrendMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Abdoli's Heikin Ashi Smoothed Buy & Sell Strategy Rev.4

A breakout strategy that scores setups from 0 to 100 using a trend template of stacked moving averages, a volatility contraction check, a squeeze test with Bollinger and Keltner bands, and volume flow. A custom free energy versus fractal entropy measure acts a

Strategy v6 BreakoutVolatility & bands
Updated 2 months ago · None stated GitHub repository of TnSovereign Thermodynamic Breakout
13 stars

This strategy provides a moving average crossover system combined with Zignaly crypto platform alert integration and built-in risk management. It enters long positions when a 14-period simple moving average crosses above a 28-period SMA, and enters short posit

Strategy v5 TrendMoving averages
Updated 1 year ago · None stated GitHub repository of Zignaly Risk M. A079

Mrhyh21 Buy Sell

by g-moe
3 stars

Mrhyh21 Buy Sell combines Parabolic SAR trend tracking with a 14-period RSI filter to trigger entry signals. It plots buy, strong buy, sell, and strong sell labels directly on the price chart when the Parabolic SAR direction aligns with specified RSI threshold

Indicator v5 TrendOscillators & momentum
Updated 5 months ago · None stated GitHub repository of Mrhyh21 Buy Sell
1 stars

This strategy calculates Keltner Channels using an Exponential Moving Average (EMA) for the midline and Average True Range (ATR) scaled by a multiplier for band width. It triggers a long entry when the close price crosses above the upper band and a short entry

Strategy v6 TrendVolatility & bands
Updated 6 days ago · Apache-2.0 GitHub repository of PF Probe 99 - Keltner Channel Break
1 stars

An overlay indicator that plots a Hull moving average, fast and slow EMAs and a Supertrend, then prints buy or sell labels when all agree. A buy needs price above the Hull average, the fast EMA above the slow one, a bullish Supertrend, RSI above its level and

Indicator v5 TrendMoving averages
Updated 2 months ago · None stated GitHub repository of Ultimate Buy/Sell Signal Pro
106 stars

This strategy calculates weighted composite scores by evaluating conditions from multiple technical indicators, including EMAs, Supertrend, Parabolic SAR, HMA, RSI, MACD, WaveTrend, Stochastic, Bollinger Bands, and ATR. It plots signals directly on the price c

Strategy v4 TrendOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of Accurate BUY & SELL 5 mins TF by RR

Volume Delta Trailing Stop

by vedkanani123
1 stars

An overlay indicator that estimates up and down volume from lower-timeframe candles, from 1 second to 1 minute, and builds a trigger line when volume delta disagrees with the candle color. A signal appears when price breaks that line, and a trailing stop follo

Indicator v5 VolumeTrend Repaints
Updated 2 months ago · None stated GitHub repository of Volume Delta Trailing Stop

Zig Zag

by TWODS-CAPITAL
37 stars

This overlay indicator draws a zigzag of confirmed swing highs and lows on the price chart. It finds pivots with a depth window, then keeps a turn only when price moves beyond the deviation threshold. Lines connect successive reversals, and the last segment ca

Indicator v5 Support & resistanceTrend Repaints
Updated 3 years ago · MIT GitHub repository of Zig Zag

Mrhyh21 SMC

by g-moe
3 stars

This SMC indicator plots market structure features on the price chart. It identifies swing points based on a configurable length and marks internal order blocks, swing order blocks, and fair value gaps. Candles can be colored according to detected trend direct

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 5 months ago · None stated GitHub repository of Mrhyh21 SMC

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