OPEN-SOURCE SCRIPT
Context Fibonacci Key Levels

Context Fibonacci Key Levels automatically plots Fibonacci retracement and extension levels using the most recently completed Day, Week and Month candles while preserving the directional context of each timeframe.
Rather than treating every Fibonacci equally, the indicator determines whether the previous higher timeframe candle closed bullish or bearish and automatically adjusts the Fibonacci orientation to reflect that completed price movement.
This creates objective reference levels that remain consistent across every chart timeframe.
Optional labels:
Full Name or Shorthand display mode
How it works
The indicator evaluates the previous completed candle of each selected higher timeframe.
If the candle closed bullish, the Fibonacci is drawn from Low to High.
If the candle closed bearish, the Fibonacci is drawn from High to Low.
This allows every Fibonacci to represent the completed directional movement of its corresponding candle.
Included Fibonacci Levels
Customization
Use Cases
These levels can be used as objective higher timeframe reference zones for technical analysis, confluence studies, liquidity mapping, retracement analysis, extension targets and general market structure observations.
Because the calculations are always based on the latest completed higher timeframe candle, the levels automatically update whenever a new Day, Week or Month closes.
Disclaimer
This indicator is designed as a technical analysis tool and does not generate trading signals or predict future market direction. It is intended to be used alongside your own trading methodology and additional sources of market confluence.
Rather than treating every Fibonacci equally, the indicator determines whether the previous higher timeframe candle closed bullish or bearish and automatically adjusts the Fibonacci orientation to reflect that completed price movement.
This creates objective reference levels that remain consistent across every chart timeframe.
- Automatic Past Day Fibonacci
- Automatic Past Week Fibonacci
- Automatic Past Month Fibonacci
- Automatic bullish or bearish orientation
- Retracement and extension levels
- Works on every timeframe
- Independent colors for each timeframe
Optional labels:
Full Name or Shorthand display mode
How it works
The indicator evaluates the previous completed candle of each selected higher timeframe.
If the candle closed bullish, the Fibonacci is drawn from Low to High.
If the candle closed bearish, the Fibonacci is drawn from High to Low.
This allows every Fibonacci to represent the completed directional movement of its corresponding candle.
Included Fibonacci Levels
- 0%
- 23.6%
- 38.2%
- 50%
- 61.8%
- 78.6%
- 100%
Customization
- Enable or disable Past Day Fibonacci.
- Enable or disable Past Week Fibonacci.
- Enable or disable Past Month Fibonacci.
- Choose an individual color for each timeframe.
- Adjust line width.
- Show or hide labels.
- Display labels using Full Name (Past Day, Past Week and Past Month) or Shorthand (PD, PW and PM).
Use Cases
These levels can be used as objective higher timeframe reference zones for technical analysis, confluence studies, liquidity mapping, retracement analysis, extension targets and general market structure observations.
Because the calculations are always based on the latest completed higher timeframe candle, the levels automatically update whenever a new Day, Week or Month closes.
Disclaimer
This indicator is designed as a technical analysis tool and does not generate trading signals or predict future market direction. It is intended to be used alongside your own trading methodology and additional sources of market confluence.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.