Strategy · Pine Script v6 · On the chart

ORB Strategy - Solo Long XAUUSD 30min

by Alberto082544

This strategy calculates the 30-minute opening range between 08:30 and 09:00 AM New York time for XAUUSD.

View on GitHub

GitHub stars1on the repository
Pine versionv6current
Lines of code98
Settings7inputs
LicenceNone stated
Last update5 months ago23 May 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

ORB Strategy - Solo Long XAUUSD 30min triggers long entries when the price crosses above the opening range high during the New York session, provided the bar closes above the 200-period EMA and the intraday VWAP. Entries also require the opening range size to stay within user-defined minimum and maximum point boundaries. The strategy places a stop loss below the session low with a point buffer, projects a take profit via a range multiplier, and caps trades per day.

Details

Published by

Alberto082544 on GitHub

Type

Strategy, Pine Script v6

Draws

On the price chart

Category

Breakout, Sessions & time, Moving averages

Markets

Gold

Timeframes

M15-H1

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
Buffer SL (pts)float2.0bufPts
Rango mínimo (pts)float5.0minRng
Rango máximo (pts)float50.0maxRng
TP Multiplicadorfloat4.0tpMult
EMA Tendenciaint200emaLen
Usar filtro EMAbooltrueusaEma
Máx. trades/díaint2maxTpd
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

39 stars

This intraday strategy implements Mark Fisher's Opening Range Breakout (ORB) methodology tailored for index futures like ES and NQ. It calculates session opening ranges, volume z-scores, and VWAP bands to plot support, resistance, and confirmation levels on th

Strategy v6 BreakoutSessions & time Repaints
Updated 4 days ago · MIT GitHub repository of Futures Intraday Pro (ES/NQ) Strategy
7 stars

This overlay strategy tracks the high and low of a user-defined London session and plots the previous session levels as support and resistance. It flags a break beyond a level when price closes past an ATR buffer, then waits a set number of bars for a retest w

Strategy v5 Sessions & timeSupport & resistance
Updated 3 months ago · None stated GitHub repository of London SR Cleaner WR (TP 0.20)
3 stars

This strategy overlays three Simple Moving Averages, one Exponential Moving Average, and a dynamic trailing swing line directly on the price chart. It determines market direction by tracking recent highest highs and lowest lows over a customizable swing period

Strategy v5 TrendMoving averages
Updated 5 months ago · None stated GitHub repository of EMA Crossover Scott Strategy

ORB Hunter

by nxtaiapp
2 stars

ORB Hunter is an Opening Range Breakout strategy that identifies price breakouts beyond a defined opening session window (such as 09:30 to 09:45 EST). It places long or short trades when price crosses the opening range bounds with buffer, confirmed by optional

Strategy v5 BreakoutSessions & time
Updated 11 months ago · MIT GitHub repository of ORB Hunter

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