Pine Library · 483 open-source scripts

Free Forex Pine Scripts for TradingView (page 9)

Open-source Pine scripts written for currency pairs: session ranges, currency strength, pip-based tools and forex strategies.

Pine scripts483
Code shown here245open licence
Updated in a year304
No repaint flag402

Forex: Indicators, Strategies and Libraries

257 stars

An overlay indicator that combines an ATR-based SuperTrend trailing stop with an integrated RSI-derived midline calculation on the price chart. The SuperTrend uses an ATR period and factor multiplier to plot dynamic green or red trend lines based on price dire

Indicator v5 TrendVolatility & bands
Updated 6 weeks ago · None stated GitHub repository of SuperTrend ATR + RSI
46 stars

This overlay indicator maps Asia, London, and New York session ranges on the price chart and compares later price action with the Asia range. It draws optional session boxes, a grid of Asia-range multiples from the New York open, and statistical extension and

Indicator v5 Sessions & timeSupport & resistance
Updated 7 weeks ago · None stated GitHub repository of NY vs Asia Statistical Levels
106 stars

Automatic Grid Bot Strategy simulates a grid trading system directly on the main price chart. It sets upper and lower price range boundaries and splits the defined range into grid levels to trade long, short, or both directions simultaneously. Users can config

Strategy v5 Support & resistanceMean reversion
Updated 2 years ago · GPL-3.0 GitHub repository of Automatic Grid Bot Strategy
4 stars

This strategy trades USD/JPY on the price chart during Tokyo and London sessions. It enters long when the fast EMA crosses above the slow EMA while price is above the trend EMA and RSI is above its midpoint, and it enters short on the opposite cross. Position

Strategy v6 TrendMoving averages
Updated 2 months ago · MIT GitHub repository of USD/JPY Carry Trend [trugurpala]
4 stars

This strategy trades USD/JPY on the price chart. It enters long when a fast EMA crosses above a slow EMA and short when the fast EMA crosses below, but only during the Tokyo or London sessions in GMT. Each entry places an ATR-based stop loss and take profit us

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

SW's Asia/London H/L's

by alvinng214
2 stars

This indicator draws high and low levels for the Asia, London, New York, and Sydney sessions on the price chart. Each session can be enabled separately, with its own line color, thickness, opacity, labels, and an optional vertical line at the session start. It

Indicator v5 Sessions & timeSupport & resistance
Updated 2 months ago · None stated GitHub repository of SW's Asia/London H/L's

An overlay indicator that tracks pivot, session, previous-day and flipped support and resistance levels and records how price reacts when it tests them. Each trial resolves into break, fade, fail or expire, and a Bayesian-style model sorted into twelve context

Indicator v6 Support & resistanceSessions & time Repaints
Updated 7 days ago · GPL-3.0 GitHub repository of Trading Coach - Hybrid S/R Reaction Probability

Session Statistical Levels

by TamaraKGreen
46 stars

This indicator overlays statistical price range levels across key trading sessions, including Asia, London, NY Morning, and NY Afternoon, as well as an optional custom session. It calculates and plots symmetric percentile range bands such as the median (P50),

Indicator v5 Sessions & timeSupport & resistance
Updated 7 weeks ago · None stated GitHub repository of Session Statistical Levels
1 stars

This strategy calculates rate of change momentum across multiple user-defined symbols and ranks them using arrays. It rotates capital into the highest-performing asset symbol at scheduled bar intervals by closing all existing positions and entering a long trad

Strategy v6 Oscillators & momentumScreeners & dashboards
Updated 2 months ago · None stated GitHub repository of TN Momentum Swarm Sovereign v6

CRT Bias Scanner v4

by alboogycOdR
6 stars

This overlay indicator presents a multi-asset CRT bias scanner as a table on the price chart. It watches up to sixteen symbols, grouped by preset lists or custom slots, and refreshes the scan at a user-set interval in minutes. Optional alerts can fire for stro

Indicator v5 Screeners & dashboards
Updated 7 months ago · None stated GitHub repository of CRT Bias Scanner v4

CRT Mapper Complete

by alboogycOdR
6 stars

CRT Mapper Complete plots Candle Range Theory (CRT) structures, Turtle Soup patterns, and supply and demand zones directly on the main price chart. It identifies time-based session ranges, tracks market structure shifts, and generates entry signals using rejec

Indicator v5 SMC / ICT / price actionSupport & resistance
Updated 7 months ago · None stated GitHub repository of CRT Mapper Complete
46 stars

This overlay indicator plots an average daily range and an optional median line from a chosen lookback, plus boxes and labels for four user-defined sessions defaulting to Asia, London, the New York open, and the New York initial balance. It can show a session

Indicator v5 Sessions & timeSupport & resistance
Updated 7 weeks ago · None stated GitHub repository of Statistcal Daily Profile & Ranges
3 stars

Farid Makram Custom Levels is a multi-signal indicator for TradingView that combines RSI momentum analysis with MOBO oscillator signals based on the DPO. It generates buy and sell signals when RSI crosses its moving average or when DPO crosses zero, with confi

Indicator v5 Oscillators & momentumMoving averages
Updated 5 months ago · None stated GitHub repository of Farid Makram Custom Levels

PF FX 5dp - SMA20/50 cross

by pineforge-4pass
1 stars

This strategy generates crossover signals using SMA20 and SMA50 on the EURUSD forex pair at 5 decimal places. It enters a long position when the fast SMA crosses above the slow SMA and immediately closes any existing short position. It enters a short position

Strategy v6 Moving averagesTrend
Updated 6 days ago · Apache-2.0 GitHub repository of PF FX 5dp - SMA20/50 cross

TN Multi-Confluence

by raybird
1 stars

A Pine v6 strategy that trades smart money concepts on the price chart. It combines a higher-timeframe bias with an EMA, equal highs and lows liquidity, order blocks, fair value gaps and an optional displacement confirmation. Entries are limited to New York an

Strategy v6 SMC / ICT / price actionSessions & time
Updated 2 months ago · None stated GitHub repository of TN Multi-Confluence

CRT State Engine

by alboogycOdR
6 stars

CRT State Engine plots time-based CRT models, session state ranges, and institutional market structure on the main price chart. It detects liquidity sweeps, order blocks, Fair Value Gaps, and volume profile imbalances across specified New York time sessions. T

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine
3 stars

FX Market Sessions highlights distinct trading sessions, such as London, New York, and previous day ranges, directly on the main chart using colored boxes and labels. It tracks session highs, lows, and pip spans, with configurable options for opening ranges, F

Indicator v5 Sessions & timeSupport & resistance
Updated 5 months ago · None stated GitHub repository of FX Market Sessions

Funded Range Gann Sniper

by vedkanani123
1 stars

A price-chart indicator that looks for fade setups after price raids the edge of a completed session or prior-day range and closes back inside. It requires the Gann half-range level to sit at least a set number of R away, sizes the stop beyond the raid using A

Indicator v6 SMC / ICT / price actionSupport & resistance Repaints
Updated 2 months ago · None stated GitHub repository of Funded Range Gann Sniper
114 stars

This strategy estimates price behavior using ordinary least squares regression between higher-timeframe data and a generated dataset, smoothed by a Karobein oscillator. It enters long positions when the oscillator turns upward and short positions when it turns

Strategy v4 Oscillators & momentumAI / machine learning Repaints

CRT State Engine

by alboogycOdR
6 stars

CRT State Engine is an overlay indicator that maps New York-timed CRT models, unmitigated order blocks, market structure, liquidity pools, and volume profile on the price chart. It can draw session boxes for Asia, London, London lunch, and New York and optiona

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine

CRT State Engine

by alboogycOdR
6 stars

CRT State Engine draws an institutional candle-range state model on the price chart. It tracks New York session models, market structure, unmitigated order blocks, liquidity pools, and optional volume profile and multi-pair correlation. Change-in-state detecti

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine

Currency test

by be-thomas
65 stars

This strategy sets the account currency to euros and, after the year 2020, opens a long position of one thousand units. It exits that position with a one-point profit target and a one-point stop. It plots the absolute bar-to-bar change in net profit, scaled by

Strategy v4
Updated 5 days ago · GPL-3.0 GitHub repository of Currency test

Malaysian SnR Kai[DoN]

by eddiebelaval
7 stars

Calculates and plots support and resistance levels using pivot high and pivot low structures based on Malaysian SnR concepts. It draws active support and resistance price zones, tracks role reversal lines when levels break, includes a simple moving average fil

Indicator v6 Support & resistanceMoving averages
Updated 3 months ago · None stated GitHub repository of Malaysian SnR Kai[DoN]

CRT State Engine

by alboogycOdR
6 stars

CRT State Engine is an overlay indicator that maps New York time-based CRT models at 9PM, 1AM, 5AM, and 9AM. It tracks market structure, liquidity sweeps, change-in-state delivery, and unmitigated order blocks that stay drawn until mitigated. Optional modules

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine

CRT State Engine

by alboogycOdR
6 stars

Implements an institutional Candle Range Theory (CRT) framework aligned to New York market time windows at 1 AM, 5 AM, and 9 AM. It calculates Draw on Liquidity (DOL) levels using pivot points, manages session state machine boxes, and generates entry signals w

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine

CRT State Engine

by alboogycOdR
6 stars

This indicator overlays a CRT state engine on the price chart using New York time. It tracks optional 1AM, 5AM and 9AM models, session states, market structure, liquidity pools, and a volume profile with point of control and value area. Live entry markers need

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine

CRT State Engine Complete

by alboogycOdR
6 stars

This indicator overlays an institutional Candle Range Theory (CRT) framework directly on the price chart. It analyzes session states across New York time models (1 AM, 5 AM, and 9 AM), detects market structure breaks, identifies order blocks, and tracks liquid

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine Complete
46 stars

This overlay indicator marks Asia, London and New York sessions using New York clock times. It draws a session candle plus an optional vertical line at the session open, horizontal open, high, mid and low lines, and a 25 percent level of the session range. Use

Indicator v5 Sessions & timeSupport & resistance
Updated 7 weeks ago · None stated GitHub repository of Session Range Candles + 25% Level

CRT State Engine v7

by alboogycOdR
6 stars

CRT State Engine v7 is an overlay indicator that tracks institutional CRT session states on the price chart. It analyzes market structure, detects buy-side and sell-side liquidity pools, and plots a volume profile with point of control and value area. Optional

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine v7
6 stars

CRT State Engine CURSOR is an overlay indicator that implements Candle Range Theory (CRT) models alongside Smart Money Concepts (SMC) frameworks. It tracks session ranges including Asia, London, New York, and CBDR, while identifying Direction of Liquidity (DOL

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine v7.2 CURSOR

AutoView Trailing Stop

by Web3Degenerate
2 stars

This indicator calculates an Average True Range (ATR) trailing stop level based on market structure swing points and outputs dynamic alert syntax formatted for the AutoView trading automation extension. Users select long or short direction, lookback length, an

Indicator v4 Volatility & bandsSupport & resistance
Updated 2 years ago · None stated GitHub repository of AutoView Trailing Stop
2 stars

Risk-Adjusted Momentum Oscillator plots a normalized momentum oscillator in a separate pane, dynamically scaling momentum by ongoing drawdown risk. It calculates momentum via Rate of Change, Price Momentum, or Log Returns, applying Z-score normalization and ad

Indicator v6 Oscillators & momentumVolatility & bands
Updated 8 months ago · None stated GitHub repository of Risk-Adjusted Momentum Oscillator

CRT State Engine v7.6

by alboogycOdR
6 stars

CRT State Engine is an institutional trading framework based on Smart Money Concepts and Candle Range Theory. It plots session ranges, order blocks, Fair Value Gaps, liquidity sweeps, and Draw on Liquidity levels directly on the main price chart. The indicator

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of CRT State Engine v7.6
3 stars

Hercules Indicator 1.7 is a multi-filter trade signal generator designed to overlay entry conditions directly on the price chart. It evaluates engulfing candle patterns alongside multiple configurable filters, including trading session windows (Sydney, Tokyo,

Indicator v5 Candlestick patternsSessions & time
Updated 5 months ago · None stated GitHub repository of Hercules Indicator 1.7

Hercules Rewrite

by g-moe
3 stars

Hercules Rewrite is a signal and visual trade management indicator that overlays entry setups directly on the price chart. It detects candle setups based on minimum tick movement and engulfing patterns, filtering entries through parameters like moving averages

Indicator v5 Candlestick patternsTrend
Updated 5 months ago · None stated GitHub repository of Hercules Rewrite
9 stars

Smart Money Dashboard plots key Smart Money Concepts on the price chart, including Order Blocks with mitigation tracking, Fair Value Gaps, and Equal Highs or Lows sweeps. It analyzes Cumulative Volume Delta for divergence and combines multi-timeframe structure

Indicator v6 SMC / ICT / price actionVolume
Updated 2 days ago · MIT GitHub repository of Smart Money Dashboard
3 stars

Hercules Strategy 1.7 is a price-chart strategy that gates trades with an engulfing-candle option, a lightning tick threshold, and a choice of long, short, or both directions. It can invert signals and stop the next trade from repeating the same side. Sydney,

Strategy v5 Candlestick patternsSessions & time
Updated 5 months ago · None stated GitHub repository of Hercules Strategy 1.7
6 stars

Forex Majors 4H Rejection Scanner tracks seven customizable currency pairs on a four-hour timeframe and displays their bias in a table overlay on the main price chart. It checks the last two closed four-hour candles for high or low price rejections, labeling a

Indicator v5 Screeners & dashboardsSupport & resistance Repaints
Updated 7 months ago · None stated GitHub repository of Forex Majors 4H Rejection Scanner
3 stars

Hercules Strategy Rewrite is an automated backtesting strategy that generates entry signals using engulfing candlestick patterns, tick thresholds, and support or resistance level breakouts. It offers multi-layer filtering including moving average trend checks,

Strategy v5 Candlestick patternsSessions & time
Updated 5 months ago · None stated GitHub repository of Hercules Strategy Rewrite
114 stars

Calculates normalized reversal metrics across up to ten Forex currency pairs using user-selected moving average methods, including HarmonicMA, EMA, SMA, or WMA. The indicator identifies overbought, oversold, and mean-crossing conditions using a configurable th

Indicator v4 Screeners & dashboardsMean reversion
Updated 1 year ago · None stated GitHub repository of Multi-Pair Trend Reversal Widget

This indicator computes the InPhase and Quadrature components of the Hilbert Transform Phasor using Ehlers' FIR filter algorithm. It processes the input source (default HLC3) through smoothing, detrender, and phase shift steps to generate the components. Plots

Indicator v6 Oscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Ehlers Hilbert Transform Phasor Components

ICT ORB

by alboogycOdR
6 stars

This overlay indicator marks a session opening range on the price chart and filters breakouts with relative volume. Session type, duration, and optional custom start time set the range, and historical ranges can stay on the chart. Full mode can require a liqui

Indicator v5 BreakoutSMC / ICT / price action
Updated 7 months ago · None stated GitHub repository of ICT ORB

S_pending_entries

by GammaExpansion
1 stars

S_pending_entries is a strategy that places different types of pending buy and sell orders including limit, stop, and stop-limit orders at specific phases in a 68-bar cycle. It calculates reference price levels around the current close and plots them along wit

Strategy v6 Support & resistanceSessions & time
Updated 6 days ago · MIT GitHub repository of S_pending_entries

This strategy calculates standard Bollinger Bands using a Simple Moving Average and standard deviation multiplier to identify entry conditions. It triggers pending stop orders and outputs formatted alert messages compatible with TradingConnector for automated

Strategy v5 Volatility & bandsMoving averages
Updated 2 years ago · GPL-3.0 GitHub repository of Bollinger Bands Strategy with TradingConnector Alerts

ICT State Machine

by alboogycOdR
6 stars

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

Indicator v5 SMC / ICT / price actionSessions & time
Updated 7 months ago · None stated GitHub repository of ICT State Machine

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