Strategy · Pine Script v6 · On the chart

MTF Mean Reversion Scalper Long Only

by MuhammadMuhamid

A long-only strategy for crypto spot that builds support zones from pivot lows on a higher timeframe, 15 minutes by default, and watches the chart timeframe for a liquidity sweep below a swing low followed by a reclaim and a higher low.

View on GitHub

GitHub stars1on the repository
Pine versionv6current
Lines of code571
Settings40inputs
LicenceNone stated
Last update12 days ago17 Oct 2026

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
  2. 2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
  3. 3Paste over the templateCreate a new strategy, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart. The trades and results appear in the Strategy Tester tab; adjust the settings with the gear icon.

Source Code

The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.

Overview

Reclaim confirmation can use an engulfing candle, a volume spike and close strength. Optional filters include a higher-timeframe EMA trend check, an ADX ceiling, a session window and a manual pause switch. Higher-timeframe values are shifted to closed bars.

Details

Published by

MuhammadMuhamid on GitHub

Type

Strategy, Pine Script v6

Draws

On the price chart

Category

Mean reversion, SMC / ICT / price action, Scalping

Markets

Crypto

Timeframes

M1-M5

Risk Notes

No repainting, lookahead or stacked entries were found in its code or README. That says nothing about how well it works: test it first.

Settings

The inputs you can change from the gear icon on the chart. Defaults are the author's.

SettingTypeDefaultVariable
HTF resolutiontimeframe15htfRes
HTF pivot length (bars each side)int10htfPivotLen
HTF confirm offset (0=live bar, 1=closed bar)int1htfConfirmOffset
Size zones with ATR (off = %)booltrueuseAtrZone
Zone half-width — ATR multfloat0.5zoneAtrMult
Zone half-width — % of pricefloat0.25zonePct
HTF ATR lengthint14htfAtrLen
HTF trend filter (close > HTF EMA)booltrueuseTrendFilter
HTF EMA lengthint200htfEmaLen
HTF ADX ceiling filterboolfalseuseAdxFilter
ADX — DI lengthint14adxDiLen
ADX — smoothingint14adxSmooth
Show all 40 settings
SettingTypeDefaultVariable
Max HTF ADXfloat35.0adxMax
LTF swing-low pivot lengthint5ltfPivotLen
Setup expiry (bars after zone touch)int60setupMaxBars
Max bars to reclaim swept levelint5reclaimMaxBars
Higher-low pivot lengthint2hlPivotLen
Max bars from reclaim to HLint20hlMaxBars
Require close above post-sweep high (strict MSS)boolfalserequireMss
Bullish engulfingbooltrueuseEngulf
Volume spikebooltrueuseVolSpike
Volume MA lengthint20volMaLen
Volume > MA xfloat1.5volMult
Close strength (close in top X of range)booltrueuseCloseStrength
Close strength ratiofloat0.6closeStrength
⛔ PAUSE TRADING (manual news filter)boolfalsepauseTrading
Enable session windowboolfalseuseTimeFilter
Window start — hour (UTC)int9sessStartHour
Window start — minuteint30sessStartMin
Window end — hour (UTC)int12sessEndHour
Window end — minuteint0sessEndMin
Flatten when window closesboolfalsecloseOnSessionEnd
SL from ATR (off = %)booltrueuseAtrSl
SL — ATR mult below sweep lowfloat0.5slAtrMult
SL — % below sweep lowfloat0.30slPct
LTF ATR lengthint14ltfAtrLen
Skip trade if SL wider than % of pricefloat2.0maxSlPct
Take profit modestringNearest (Swing High or RR)tpMode
RR targetfloat2.0rrTarget
Skip trade if final RR belowfloat1.2minRr
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.

Similar Pine Scripts

105 stars

Gold Scalping BOS & CHoCH is an overlay strategy designed for detecting market structure shifts. It calculates rolling swing highs and lows to identify Break of Structure (BOS) and Change of Character (CHoCH) events. Long signals trigger when bullish BOS and C

Strategy v6 SMC / ICT / price actionSupport & resistance
Updated 1 year ago · None stated GitHub repository of Gold Scalping BOS & CHoCH

FVG RSI Strategy (Optimized)

by skywalker0803r
42 stars

This strategy plots on the price chart and trades fair value gaps filtered by RSI and two EMAs. It opens a long when a bullish gap, a rising candle, RSI below the oversold level, and price under both EMAs align, and a short on the opposite conditions. Each tra

Strategy v5 SMC / ICT / price actionOscillators & momentum
Updated 2 months ago · None stated GitHub repository of FVG RSI Strategy (Optimized)

FairValueGap B002

by ruckard
13 stars

This price-chart strategy measures the distance from the current price to the opposite end of the latest fair value gap and enters on the idea that price fills much of that gap. Take profit is set toward a large share of that distance, with a wider stop meant

Strategy v5 SMC / ICT / price actionMean reversion
Updated 1 year ago · None stated GitHub repository of FairValueGap B002
12 stars

This is a Pine Script strategy that executes a fixed historical backtest on BTC-USD. It places multiple manual trades using strategy.order at specific timestamps and prices, with corresponding close conditions based on time. Some trades are long and some are s

Strategy v4 Mean reversionScalping
Updated 5 years ago · None stated GitHub repository of Lazarus3 BTC Backtest

Enhanced DCA Strategy

by SynergOps
7 stars

The Enhanced DCA Strategy invests a fixed dollar amount at regular intervals (daily, weekly or monthly) into the asset after start date, deducting trading fees and tracking total invested, units acquired, current value, profit, ROI, Sharpe ratio, Sortino ratio

Strategy v6 ScalpingMean reversion Repaints
Updated 1 year ago · MPL-2.0 GitHub repository of Enhanced DCA Strategy

More strategys

Trade Your Charts With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers