OPEN-SOURCE SCRIPT
HTF Levels | 1H 4H Daily

HTF Levels | 1H 4H Daily
Plots the current and previous High, Low, and Midpoint for the 1-Hour, 4-Hour, and Daily timeframes directly on your chart — regardless of which timeframe you are trading on.
What makes this original:
Most HTF level tools simply draw static lines from request.security() on every bar, cluttering historical price action. This script draws only on the current bar (barstate.islast), keeping the chart clean. It also includes an automatic level merging algorithm — when levels from different timeframes fall within a configurable percentage threshold of each other, they are averaged into a single line with a combined label (e.g. 4H H | Prv D H), visually identifying high-confluence zones without requiring manual comparison.
Levels plotted:
Current period: High, Midpoint ((H+L)/2), Low — lines extend across the full chart
Previous period: High, Midpoint, Low — lines extend left only for visual separation
Confluence Merging:
When two or more levels are within the merge threshold (default 0.05%), they collapse into one averaged line with a merged label. Adjust the threshold in settings to suit your instrument's tick size.
Alerts:
Every level has its own named alert condition. Use individual alerts (e.g. "4H High", "Prev Daily Low") or the master "Any HTF Level" alert to get notified when price enters proximity of any key zone. The alert buffer % is fully adjustable.
Settings:
Toggle each timeframe independently
Custom color per timeframe
Line width and label size controls
Merge threshold % — how close levels must be to combine
Alert buffer % — how close price must be to trigger
Best used on intraday timeframes (1m–30m) where 1H, 4H, and Daily levels act as key support and resistance.
Plots the current and previous High, Low, and Midpoint for the 1-Hour, 4-Hour, and Daily timeframes directly on your chart — regardless of which timeframe you are trading on.
What makes this original:
Most HTF level tools simply draw static lines from request.security() on every bar, cluttering historical price action. This script draws only on the current bar (barstate.islast), keeping the chart clean. It also includes an automatic level merging algorithm — when levels from different timeframes fall within a configurable percentage threshold of each other, they are averaged into a single line with a combined label (e.g. 4H H | Prv D H), visually identifying high-confluence zones without requiring manual comparison.
Levels plotted:
Current period: High, Midpoint ((H+L)/2), Low — lines extend across the full chart
Previous period: High, Midpoint, Low — lines extend left only for visual separation
Confluence Merging:
When two or more levels are within the merge threshold (default 0.05%), they collapse into one averaged line with a merged label. Adjust the threshold in settings to suit your instrument's tick size.
Alerts:
Every level has its own named alert condition. Use individual alerts (e.g. "4H High", "Prev Daily Low") or the master "Any HTF Level" alert to get notified when price enters proximity of any key zone. The alert buffer % is fully adjustable.
Settings:
Toggle each timeframe independently
Custom color per timeframe
Line width and label size controls
Merge threshold % — how close levels must be to combine
Alert buffer % — how close price must be to trigger
Best used on intraday timeframes (1m–30m) where 1H, 4H, and Daily levels act as key support and resistance.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
profitgang
haze
haze
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
profitgang
haze
haze
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.