Pine Library · 3,040 open-source scripts

Free TradingView Strategy Scripts (page 37)

Open-source Pine Script strategies: scripts that place simulated trades, so TradingView's Strategy Tester can report how the rules did on past data.

Pine scripts3,040
Code shown here1,833open licence
Updated in a year1,781
No repaint flag2,645

Strategies: All

MA Strategy

by amico1234
1 stars

This Pine Script v4 strategy generates crossover signals using two simple moving averages on the price chart. The fast SMA in red crosses above the slow SMA in blue for long entries and below for short entries. Signals activate only during a defined trading se

Strategy v4 Moving averagesSessions & time
Updated 2 years ago · None stated GitHub repository of MA Strategy
1 stars

The KSMBTC EMA Cross Strategy plots an exponential moving average of the closing price on the price chart. It signals long positions when the open price crosses above the EMA with a green candle and short positions with a red candle. The strategy enters long w

Strategy v4 TrendMoving averages
Updated 4 years ago · None stated GitHub repository of KSMBTC EMA Cross Strategy
330 stars

The EMA Moving Away Strategy calculates an Exponential Moving Average (EMA) to identify mean-reversion trade opportunities when price stretches significantly away from the line. A long entry triggers when the close drops below the EMA by a specified percentage

Strategy v5 TrendMoving averages
Updated 2 months ago · None stated GitHub repository of EMA Moving away Strategy [Alorse]
257 stars

This strategy overlays Fibonacci standard deviation bands based on volume-weighted moving averages (VWMA) alongside 10-period open moving averages and pivot high/low levels directly on the price chart. It defines percentage-based stop-loss and take-profit targ

Strategy v5 Volatility & bandsMoving averages Repaints
Updated 7 weeks ago · None stated GitHub repository of Futures - No Repain ES

@@rp_Indicator

by hasnocool
106 stars

This overlay strategy plots exponential moving averages of length 21, 55, 100, and 200 on the price chart. It is declared as a strategy that sizes orders as a percentage of equity and applies a percent commission and slippage, with pyramiding disabled. The mom

Strategy v5 Moving averages
Updated 2 years ago · GPL-3.0 GitHub repository of @@rp_Indicator

This strategy implements a multi-stage trend following system inspired by John W. Seykota. It generates long and short entries when price breaks above or below Donchian channels of specified length. Each entry adds a unit sized to risk a fixed percentage of cu

Strategy v6 TrendVolatility & bands
Updated 12 months ago · None stated GitHub repository of Seykota Alt 29: Multi-Stage Scaling

Diverlong A002

by ruckard
13 stars

Diverlong A002 is an automated trading strategy designed for cryptocurrency pairs on intraday timeframes. It detects classic bullish and bearish divergences by comparing price changes against transitions in the Squeeze Momentum Indicator. Positions are exited

Strategy v5 DivergenceOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Diverlong A002

WR-SR + SMC Strategy

by alboogycOdR
6 stars

This overlay strategy looks for wick rejections near support and resistance levels and scores them with smart-money confluence. It can plot fair value gaps, order blocks, change-of-character and break-of-structure labels, higher-timeframe structure lines, and

Strategy v5 SMC / ICT / price actionSupport & resistance
Updated 7 months ago · None stated GitHub repository of WR-SR + SMC Strategy

Ichimoku Cloud STEPFUN

by eltonaguiar
4 stars

This Ichimoku Cloud strategy plots the cloud and price action on the chart for trend analysis. It generates long signals when price is above the cloud with a Tenkan-Kijun bullish crossover and bullish cloud, optionally confirmed by Chikou span. Short signals f

Strategy v5 TrendMoving averages
Updated 2 days ago · None stated GitHub repository of Ichimoku Cloud STEPFUN
4 stars

This trend-following strategy generates long and short entries when a fast EMA crosses a slow EMA, overlaying directly on the price chart. To reduce false signals, it applies four configurable fakeout filters: volume moving average threshold, consecutive bar c

Strategy v6 TrendMoving averages
Updated 2 months ago · MIT GitHub repository of Fakeout-Confirmed Strategy

ALGOX

by IAMATOMIC001
3 stars

ALGOX is a multi-indicator trend-following strategy plotted directly on the main chart. It generates trade entries based on configurable setups, moving average trends, and higher-timeframe inputs. Users can apply sideways market filters using customizable RSI

Strategy v5 TrendMoving averages Repaints
Updated 12 months ago · None stated GitHub repository of ALGOX

Alpy Spot

by avatar-lavventura
2 stars

Alpy Spot is an oscillator and trend strategy that calculates a WaveTrend indicator alongside a multi-timeframe 60-minute Volume Weighted Moving Average (VWMA) with percentage band offsets. It plots WaveTrend lines, overbought and oversold threshold levels, an

Strategy v4 Oscillators & momentumMoving averages Repaints
Updated 7 months ago · None stated GitHub repository of Alpy Spot
2 stars

This strategy detects adaptive market regimes by combining ATR volatility with fast and slow EMA moving averages to determine trend direction. It applies multi-timeframe confirmation using RSI and MACD on a higher timeframe. Signals appear as buy and sell arro

Strategy v6 Volatility & bandsMoving averages Repaints

超级趋势RSI

by wynnforthework
2 stars

This strategy applies a Supertrend calculation directly to Relative Strength Index values rather than raw price, plotting the result in a separate pane. Traders can enable optional RSI smoothing via a Hull Moving Average and overlay a secondary moving average

Strategy v5 TrendOscillators & momentum
Updated 1 year ago · None stated GitHub repository of 超级趋势RSI

Trendsignal Strategy

by DaniilOkrug
2 stars

The Trendsignal Strategy identifies trend flips using dynamic channel boundaries derived from high and low price ranges over a set lookback period. It calculates upper and lower thresholds based on a customizable risk setting. When price closes above the upper

Strategy v4 TrendBreakout
Updated 4 years ago · MIT GitHub repository of Trendsignal Strategy
1 stars

This multi-model strategy combines kinematic price modeling, Bayesian inference forecasts, volume profile consolidation zones, and automated pattern recognition directly on the price chart. It evaluates market trajectory using weighted kinematic regression, un

Strategy v5 AI / machine learningSupport & resistance
Updated 2 days ago · None stated GitHub repository of JAT+BSM Pro v13 Extended

Risk Managed Strategy

by jayadevrana
1 stars

This strategy executes long trades when the closing price crosses above an Exponential Moving Average (EMA) and displays the EMA trend line directly on the price chart. Position sizing is calculated dynamically to risk a fixed percentage of current equity base

Strategy v6 TrendMoving averages
Updated 4 days ago · MPL-2.0 GitHub repository of Risk Managed Strategy

Elder Ray Index

by pineforge-4pass
1 stars

Calculates Elder Ray Bull Power and Bear Power by measuring differences between price extremes and an exponential moving average. It takes long entries during an uptrend when Bear Power is negative but rising, and short entries during a downtrend when Bull Pow

Strategy v6 Oscillators & momentumTrend
Updated 7 days ago · Apache-2.0 GitHub repository of Elder Ray Index
1 stars

A strategy that builds a structural delta volume profile with point of control, value area and high-delta liquidity zones, plus a rolling P0 equilibrium and an acceptance and rejection scoring dashboard. Entries come from the flip of an adaptive ATR band that

Strategy v6 VolumeSupport & resistance Repaints
Updated 8 days ago · GPL-3.0 GitHub repository of Dynamic P0 Delta Profile Strategy v1.0.4

This intraday strategy fades tests of the previous day high and low during the New York morning session. It identifies mean-reversion opportunities when price touches within a few ticks of the prior day high or low, closes back inside, confirms with above-aver

Strategy v6 Mean reversionSupport & resistance
Updated 2 months ago · None stated GitHub repository of TeleNexus Sovereign PDH/PDL Fade V6
1 stars

This strategy serves as a test corpus script demonstrating the use of Pine Script map data structures for state management alongside exponential moving averages. It tracks closing prices and EMA gaps in a key-value map during initial bars, then triggers long e

Strategy v5 TrendMoving averages
Updated 4 months ago · MIT GitHub repository of Corpus Map Basic State

Stochastic RSI Crossover

by Basant1Saini
1 stars

This strategy calculates Stochastic RSI crossovers occurring in extreme overbought or oversold zones, filtered by an optional Exponential Moving Average trend filter. Long positions enter when the %K line crosses above %D from below the oversold threshold whil

Strategy v5 Oscillators & momentumTrend
Updated 8 months ago · None stated GitHub repository of Stochastic RSI Crossover
1 stars

VABOAlgo is a Pine Script v5 strategy that detects breakouts from a value area. It uses VWAP as a POC proxy and ATR to calculate VAH and VAL, requiring volume above average for confirmation and prior bar consolidation within the VA. Long entries trigger on bre

Strategy v5 BreakoutVolume
Updated 8 months ago · None stated GitHub repository of VABOAlgo (Value Area Breakout)
1 stars

High-Frequency Swing Reversal is a Pine Script v5 strategy that computes a reversal score from Bollinger Bands distance, RSI exhaustion, and candlestick rejection patterns such as hammers and stars. It plots VWAP, Bollinger Bands, and EMA20 on the price chart.

Strategy v5 Oscillators & momentumVolatility & bands
Updated 9 months ago · None stated GitHub repository of High-Frequency Swing Reversal

LINKBTC Binance 3h

by tseitz
1 stars

A Pine v4 strategy that colours candles and plots VWAP with wide bands at one percent, inner bands at 0.8 percent and a tight pair at 0.1 percent around the close. A green non-doji candle opening above the tight upper band, or reaching the inner one, triggers

Strategy v4 Volume
Updated 4 years ago · None stated GitHub repository of LINKBTC Binance 3h
330 stars

HA UnivLong&Short Futures calculates Heikin Ashi candles and builds a channel using simple moving averages of Heikin Ashi highs and lows. It enters long positions when the upper channel line crosses above the lower channel line and opens short positions on the

Strategy v5 TrendMoving averages
Updated 2 months ago · None stated GitHub repository of HA UnivLong&Short Futures
257 stars

This strategy overlay calculates custom pivot high and low levels, averaged price sources, and Ichimoku Cloud components (Tenkan-sen, Kijun-sen, Senkou Span A/B). It also requests lower low price data from a 360-minute timeframe with lookahead enabled, introdu

Strategy v5 TrendSupport & resistance Repaints
Updated 7 weeks ago · None stated GitHub repository of Futures - No Repaint ES 1.0

ABCD Strategy

by hasnocool
106 stars

Identifies harmonic ABCD chart patterns using pivot highs and pivot lows over a configurable lookback length. The strategy evaluates price retracement and extension ratios across four consecutive alternating pivot points to trigger long or short positions. It

Strategy v5 Support & resistanceMean reversion
Updated 2 years ago · GPL-3.0 GitHub repository of ABCD Strategy
16 stars

This trend-following strategy generates trades using Donchian channel breakouts combined with higher-timeframe trend filters and chart-timeframe momentum. It confirms breakout entries against a higher-timeframe moving average and rate of change, while optional

Strategy v6 TrendBreakout
Updated 12 months ago · None stated GitHub repository of Seykota Alt 2: Dual-Timeframe

Diverlong B002

by ruckard
13 stars

This strategy enters when Squeeze Momentum color-section changes diverge from price, comparing the latest change with a prior one and confirming the divergence across two pairs. A smaller squeeze value with a higher price opens a short, while a larger squeeze

Strategy v5 DivergenceOscillators & momentum
Updated 1 year ago · None stated GitHub repository of Diverlong B002
6 stars

This hybrid trading strategy combines wick rejection support and resistance levels with Smart Money Concepts. It calculates entry confidence scores based on multi-timeframe structure, Fair Value Gap taps, Order Block alignment, and recent Change of Character o

Strategy v5 SMC / ICT / price actionSupport & resistance
Updated 7 months ago · None stated GitHub repository of WR-SR + SMC Strategy ENHANCED
5 stars

This strategy trades long only on the price chart. It enters when the current bar opens at or below the prior close, opens below the prior open, and closes above the prior open, after a chosen backtest start. It exits at a percent profit and stop, or at ATR mu

Strategy v4 Candlestick patterns
Updated 3 years ago · Apache-2.0 GitHub repository of Engulfing Candle Long Strategy (D)

MACD_Crossover_STEPFUN

by eltonaguiar
4 stars

This strategy enters long when the MACD line crosses above its signal line and short when it crosses below. Optional filters require the histogram to exceed a threshold, price to sit on the matching side of a simple moving average, and a simplified three-bar d

Strategy v5 Oscillators & momentumMoving averages
Updated 2 days ago · None stated GitHub repository of MACD_Crossover_STEPFUN
4 stars

This strategy trades GBP/USD on the price chart. It enters long when a fast EMA crosses above a slow EMA while price stays above a trend EMA, and enters short on the opposite cross below that EMA. Signals are allowed only in the London session, 07:00 to 17:00

Strategy v6 TrendMoving averages
Updated 2 months ago · MIT GitHub repository of GBP/USD Forex Strategy [trugurpala]

This strategy evaluates market conditions on the price chart by combining composite RSI STARC bands, an EMA and SMA crossover, VWAP standard deviation bands, and security-derived volume metrics. It enters long positions when cumulative delta, momentum breakout

Strategy v5 Oscillators & momentumMoving averages Repaints
Updated 2 years ago · GPL-3.0 GitHub repository of Version Alpha: Composite Momo + Volume + Price Strategy

Alpy Vix

by avatar-lavventura
2 stars

This strategy plots the Williams Vix Fix in a separate pane with Bollinger Bands and VWMA lines. It signals long entries when the Vix Fix color shifts from lime to gray, meets VWMA long conditions and close is lower. Short signals trigger on the opposite color

Strategy v4 Volatility & bandsOscillators & momentum Repaints
Updated 7 months ago · None stated GitHub repository of Alpy Vix

Dskyz Adaptive Futures Elite (DAFE)

by mushroom-men-Trading
2 stars

Dskyz Adaptive Futures Elite (DAFE) is an automated strategy designed for intraday trading. It generates long and short entries by pairing fast and slow moving average crossovers with candlestick pattern detection, filtered by RSI, volume, volatility, and a hi

Strategy v6 Moving averagesCandlestick patterns
Updated 9 months ago · None stated GitHub repository of Dskyz Adaptive Futures Elite (DAFE)

饥饿者~01

by wynnforthework
2 stars

This strategy overlays execution signals directly on the main price chart. It calculates entry points using a Kalman gain filter and dynamic approach percentages. Positions execute in both long and short directions, scaling out across three predefined take-pro

Strategy v5 Moving averagesTrend
Updated 1 year ago · None stated GitHub repository of 饥饿者~01

Yaroslav93rus

by DaniilOkrug
2 stars

This TradingView Pine Script strategy overlays two exponential moving averages (lengths 10 and 28) on the price chart along with markers for pivot highs and lows. It optionally displays support and resistance levels based on user settings. The script includes

Strategy v4 Moving averagesSupport & resistance Repaints
Updated 4 years ago · MIT GitHub repository of Yaroslav93rus
1 stars

JAT+BSM Pro v13 Extended is a multi-timeframe trading strategy overlay that combines kinematic regression models, Bayesian inference, and consolidation zone analysis. It processes multi-layer volatility bands, volume profile buckets, and pattern structure targ

Strategy v5 TrendVolatility & bands
Updated 2 days ago · None stated GitHub repository of JAT+BSM Pro v13 Extended

EMA Ribbon

by pineforge-4pass
1 stars

This strategy calculates three exponential moving averages with adjustable lengths for the fast, mid, and slow periods. It enters a long position when the moving averages form a bullish stack and a short position during a bearish stack, utilizing a transition

Strategy v6 TrendMoving averages
Updated 7 days ago · Apache-2.0 GitHub repository of EMA Ribbon

A strategy that first classifies the market using ADX and a Bollinger-inside-Keltner squeeze check, then switches between two sub-strategies. In ranging conditions it fades asymmetric Bollinger Band extremes with a 200 EMA trend filter. In trending conditions

Strategy v6 Mean reversionBreakout
Updated 8 days ago · GPL-3.0 GitHub repository of Hierarchical HTS v6 Markov-Proxy Regime Switcher

A scalping strategy on the price chart built around market structure: change of character, break of structure and inducement sweeps, filtered by RSI extremes, volume, trend EMA, ATR range, session hours and signal confluence. A mode selector switches between C

Strategy v6 ScalpingSMC / ICT / price action Repaints
Updated 2 months ago · None stated GitHub repository of TeleNexus Sovereign Scalping Pro
1 stars

This strategy draws on the price chart and uses a 21-period EMA of the current symbol close as a fast line and a 55-period SMA of the close price from a higher timeframe (default 60 minutes) as a slow line. Long conditions trigger on EMA crossover above the sl

Strategy v5 Moving averagesTrend
Updated 4 months ago · MIT GitHub repository of Corpus MTF Security Close

Volume Spike Reversal

by Basant1Saini
1 stars

The Volume Spike Reversal strategy identifies potential price reversals driven by high volume activity. It triggers long entries when a volume spike occurs while price is below a 20-period simple moving average, combined with oversold RSI readings and bullish

Strategy v5 VolumeOscillators & momentum
Updated 8 months ago · None stated GitHub repository of Volume Spike Reversal

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