OPEN-SOURCE SCRIPT
Fibonacci Zones and Rejections

This tool combines swing structure, Fibonacci retracements and candle-wick rejection logic to highlight high-probability reversal or continuation zones.
What it does
Tracks market structure automatically
Detects swing highs and swing lows based on a user-defined Structure Period.
Marks bullish shifts in structure and bearish shifts with CHoCH labels and Break of Structure (BoS) lines.
Optionally draws a dotted swing trend line between the active swing high and swing low and can show price labels at those swing points.
Draws dynamic Fibonacci retracements on the latest swing
Automatically anchors a Fibonacci retracement between the current swing high and swing low.
Lets you enable/disable individual Fibonacci levels and customize their values, colors and line width.
Can extend Fib levels forward to the latest bar and optionally keep previous Fib structures on the chart for context.
Optionally fills the “Golden Zone” (by default the first two levels, e.g. 0.50 and 0.618) so the core pullback area is visually obvious.
Defines an OTE / “Gold Zone” band from the active Fib levels
Uses the first two Fib lines (by default 0.50 and 0.618 or set another zone such as 61.8% to 78.6%) to form a live “Optimal Trade Entry” band.
Continuously updates this band as new structure forms and swings develop.
Detects rejection candles inside the Fib OTE band
Breaks each candle into upper wick, lower wick, body and total range.
A bullish rejection is a candle where:
Price trades into the OTE band,
The lower wick is a large portion of the bar’s range, and
The body is not tiny (minimum body-to-range ratio is configurable).
A bearish rejection is the mirror condition using the upper wick.
Only candles whose range overlaps the OTE band are considered; this filters for true reactions to the Fib zone.
Plots clear signals and alerts
Bullish OTE rejection is plotted as a large cross at the low of the candle.
Bearish OTE rejection is plotted as a large cross at the high of the candle.
Built-in alertcondition calls allow you to set alerts for:
Bullish OTE Rejection
Bearish OTE Rejection
Optional “debug” markers can show all raw rejection candles and all bars that sit inside the OTE band, to help you understand how the logic behaves.
Use cases
Identify pullback entries into the desired Fib zone after a clear structural move.
Confirm reversals or continuations using wick-based rejection inside a pre-defined Fib discount/premium zone.
Combine with your own higher-timeframe bias or ICT / SMC tools to refine entry timing around key levels.
What it does
Tracks market structure automatically
Detects swing highs and swing lows based on a user-defined Structure Period.
Marks bullish shifts in structure and bearish shifts with CHoCH labels and Break of Structure (BoS) lines.
Optionally draws a dotted swing trend line between the active swing high and swing low and can show price labels at those swing points.
Draws dynamic Fibonacci retracements on the latest swing
Automatically anchors a Fibonacci retracement between the current swing high and swing low.
Lets you enable/disable individual Fibonacci levels and customize their values, colors and line width.
Can extend Fib levels forward to the latest bar and optionally keep previous Fib structures on the chart for context.
Optionally fills the “Golden Zone” (by default the first two levels, e.g. 0.50 and 0.618) so the core pullback area is visually obvious.
Defines an OTE / “Gold Zone” band from the active Fib levels
Uses the first two Fib lines (by default 0.50 and 0.618 or set another zone such as 61.8% to 78.6%) to form a live “Optimal Trade Entry” band.
Continuously updates this band as new structure forms and swings develop.
Detects rejection candles inside the Fib OTE band
Breaks each candle into upper wick, lower wick, body and total range.
A bullish rejection is a candle where:
Price trades into the OTE band,
The lower wick is a large portion of the bar’s range, and
The body is not tiny (minimum body-to-range ratio is configurable).
A bearish rejection is the mirror condition using the upper wick.
Only candles whose range overlaps the OTE band are considered; this filters for true reactions to the Fib zone.
Plots clear signals and alerts
Bullish OTE rejection is plotted as a large cross at the low of the candle.
Bearish OTE rejection is plotted as a large cross at the high of the candle.
Built-in alertcondition calls allow you to set alerts for:
Bullish OTE Rejection
Bearish OTE Rejection
Optional “debug” markers can show all raw rejection candles and all bars that sit inside the OTE band, to help you understand how the logic behaves.
Use cases
Identify pullback entries into the desired Fib zone after a clear structural move.
Confirm reversals or continuations using wick-based rejection inside a pre-defined Fib discount/premium zone.
Combine with your own higher-timeframe bias or ICT / SMC tools to refine entry timing around key levels.
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.