OPEN-SOURCE SCRIPT
已更新 Opening Range and Market Boundaries

Opening Range and Market Boundaries
This versatile and insightful indicator combines two powerful concepts frequently used by professional traders: Opening Range Analysis and Market Boundaries derived from previous high/low levels. It is specifically designed to support intraday trading strategies and helps you identify key price zones for entries, exits, and breakout confirmations.
🔍 Features & Utility
1. Opening Range Box
What it does:
Highlights the high and low of the first candle after market open (9:15 AM IST) with a shaded box. This box spans the full trading session, from 9:15 AM to 3:30 PM, representing the key price range where the initial balance is formed.
Timeframe Compatibility:
The Opening Range box is optimized for 1-minute to 1-hour charts. It is most effective on lower timeframes (1m, 5m, 15m, 30m) where intraday price movements and breakout patterns can be clearly observed.
Usage Tips:
Breakouts above or below the Opening Range box can signal potential directional bias for the rest of the trading day.
Price consolidating within the range may indicate a choppy or range-bound session.
Works well with volume and momentum indicators for confirmation.
2. Market Boundaries
What it does:
Plots horizontal lines at:
Previous Day High/Low
Previous Week High/Low
Previous Month High/Low
Why it matters:
These levels act as natural support and resistance zones, and are commonly watched by institutional traders, making them crucial for:
Spotting reversals or breakouts
Planning stop-loss and target zones
Avoiding trades around high-rejection areas
Customization Options:
Toggle ON/OFF for Daily, Weekly, and Monthly levels.
Independent colors and line thickness for each level, enabling you to distinguish between different timeframes easily.
🛠️ How to Use Effectively
Use during market open:
Switch to a 5-minute or 15-minute chart during the first few candles of the session. Observe the Opening Range box formation and plan trades based on breakout direction.
Confluence Trading:
Look for price action near previous session highs/lows in confluence with the Opening Range box edges. These intersections often become high-probability zones for breakouts or reversals.
Session Preparation:
Before the market opens, analyze where the price is relative to past high/low boundaries. If it's near a weekly/monthly level, be cautious — those areas can cause whipsaws or false breakouts.
Avoid low-volume breakouts:
Use this indicator in conjunction with volume tools or price action confirmation to validate the strength of a move outside the Opening Range or Market Boundaries.
📌 Summary
This indicator is designed for intraday traders, scalpers, and swing traders who want a reliable structure to guide their decisions. It visually marks the opening balance of the market and essential higher timeframe boundaries, helping you trade with discipline and precision.
This versatile and insightful indicator combines two powerful concepts frequently used by professional traders: Opening Range Analysis and Market Boundaries derived from previous high/low levels. It is specifically designed to support intraday trading strategies and helps you identify key price zones for entries, exits, and breakout confirmations.
🔍 Features & Utility
1. Opening Range Box
What it does:
Highlights the high and low of the first candle after market open (9:15 AM IST) with a shaded box. This box spans the full trading session, from 9:15 AM to 3:30 PM, representing the key price range where the initial balance is formed.
Timeframe Compatibility:
The Opening Range box is optimized for 1-minute to 1-hour charts. It is most effective on lower timeframes (1m, 5m, 15m, 30m) where intraday price movements and breakout patterns can be clearly observed.
Usage Tips:
Breakouts above or below the Opening Range box can signal potential directional bias for the rest of the trading day.
Price consolidating within the range may indicate a choppy or range-bound session.
Works well with volume and momentum indicators for confirmation.
2. Market Boundaries
What it does:
Plots horizontal lines at:
Previous Day High/Low
Previous Week High/Low
Previous Month High/Low
Why it matters:
These levels act as natural support and resistance zones, and are commonly watched by institutional traders, making them crucial for:
Spotting reversals or breakouts
Planning stop-loss and target zones
Avoiding trades around high-rejection areas
Customization Options:
Toggle ON/OFF for Daily, Weekly, and Monthly levels.
Independent colors and line thickness for each level, enabling you to distinguish between different timeframes easily.
🛠️ How to Use Effectively
Use during market open:
Switch to a 5-minute or 15-minute chart during the first few candles of the session. Observe the Opening Range box formation and plan trades based on breakout direction.
Confluence Trading:
Look for price action near previous session highs/lows in confluence with the Opening Range box edges. These intersections often become high-probability zones for breakouts or reversals.
Session Preparation:
Before the market opens, analyze where the price is relative to past high/low boundaries. If it's near a weekly/monthly level, be cautious — those areas can cause whipsaws or false breakouts.
Avoid low-volume breakouts:
Use this indicator in conjunction with volume tools or price action confirmation to validate the strength of a move outside the Opening Range or Market Boundaries.
📌 Summary
This indicator is designed for intraday traders, scalpers, and swing traders who want a reliable structure to guide their decisions. It visually marks the opening balance of the market and essential higher timeframe boundaries, helping you trade with discipline and precision.
發行說明
Opening Range Box and Price Ranges (Enhanced Version)Overview: The Opening Range Box and Price Ranges indicator is a powerful tool for both intraday traders and swing traders. It automatically plots the Opening Range Box (ORB), which identifies the high and low of the market's opening range, as well as Price Ranges from previous trading sessions (daily, weekly, and monthly high/low levels). This tool provides valuable support and resistance zones, offering traders clear reference points for making informed trading decisions.
The Opening Range Box is widely used for intraday breakout strategies, while the Price Ranges are effective for identifying key support/resistance areas that can guide swing trading decisions. This tool works globally across any asset class, including stocks, forex, commodities, and cryptocurrency, making it versatile for traders in any market.
Key Features:
Opening Range Box (ORB): Automatically plots the first candle's high and low of the trading day, providing a reference for potential breakouts and intraday trends.
Past Trading Ranges: Displays the high and low for the previous day, week, and month, which are critical for understanding market structure and identifying potential support and resistance zones.
Global Market Compatibility: The indicator works universally across all asset classes—whether you're trading stocks, forex, crypto, or commodities.
Customizable Inputs: Fully customizable inputs for adjusting box fill colors, border colors, and line thickness to suit your trading style and preferences.
Toggle Options: Easily toggle the visibility of Opening Range Box and Past Trading Ranges with checkboxes, allowing traders to choose the data they want to display.
How to Use:
Intraday Traders: The Opening Range Box (ORB) is key for breakout strategies. Price movements beyond the ORB range may signal a strong intraday trend.
Swing Traders: The Price Ranges (daily, weekly, and monthly highs/lows) help identify critical support and resistance levels for multi-day or multi-week price moves.
Customization: Adjust colors and line thicknesses based on your preferred chart setup. The indicator also provides toggles to control the display of ORB and Past Trading Ranges independently.
Global Application: Use this indicator in any market to identify levels where price could reverse or break out.
What's New in This Version:
Enhanced UI: The new version includes checkboxes to toggle the Opening Range Box and Past Trading Ranges, giving you more control over your chart’s display.
Broader Compatibility: This version is compatible with all global markets, making it useful for stocks, forex, cryptocurrencies, and commodities traders alike.
Versatile Trading Tool: Whether you trade intraday breakouts or longer-term swing trades, this tool adapts to your style, offering dynamic support and resistance zones.
發行說明
Opening Range Box and Price RangesThis indicator combines the Opening Range Box (ORB) strategy with key price level plotting from previous trading sessions to help traders make informed intraday decisions.
🔍 Features
✅ Opening Range Box (ORB)
Automatically draws a box using the high and low of the first candle of the day
Supports any timeframe from 1-minute to 1-hour
Highlights the day’s range early for breakout or range-bound strategies
✅ Previous High/Low Levels
Plots Daily, Weekly, and Monthly high/low levels
Color-coded and customizable line thickness for easy distinction
Helps identify key support/resistance levels from past sessions
✅ Flexible Controls
Enable/disable ORB box and past levels individually
Choose colors and thickness for each line
⚠️ IMPORTANT USAGE NOTE
This indicator is based on Regular Trading Hours (RTH).
If you have Extended Trading Hours (ETH) enabled in your chart layout, the Opening Range Box may not appear correctly (may show as a line or be misplaced).
🔧 To Fix This:
Please disable ETH in your chart’s "Symbol" settings → "Session" tab → uncheck "Extended Trading Hours".
This ensures the box is created using the true first candle of the regular session.
🔄 New Enhancements in This Version
Added visual alert comment in script regarding ETH vs. RTH behavior
Clarified usage and reliability expectations in various layouts
Cleaner and more intuitive control options for user customization
發行說明
Opening Range and Market BoundariesThis indicator combines the Opening Range Box (ORB) strategy with key price level plotting from previous sessions. It displays the opening range for the first Regular Trading Hours (RTH) candle and offers the option to show high/low levels for the previous day, week, and month. Users can customize the appearance, including line thickness, color, and more. The indicator also provides clear visibility for market boundaries from prior trading sessions, making it an ideal tool for day traders and swing traders looking to track significant price levels.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。