OPEN-SOURCE SCRIPT
OSOK SafePad

OSOK SafePad is a lightweight price-level tool for marking a configurable safety buffer above and below the current reference price. It is designed for traders who want a clean visual guide for breakout, stop-entry, or event-driven execution plans without cluttering the historical chart.
Key features
How it works
Before the freeze time, SafePad tracks the latest chart price and displays the pad levels from the current candle. When freeze mode is enabled and the chart enters the configured freeze window, the indicator captures that candle’s open as the reference price and locks the pad levels from that point onward.
For example, with a 25-point pad, the Upper Pad is drawn 25 points above the reference price and the Lower Pad is drawn 25 points below it.
Take-profit and stop-loss guides
The optional TP and SL lines are derived from the configured dollar target, order size, and the symbol’s point value. These levels are visual planning aids for a hypothetical buy-stop at the Upper Pad and sell-stop at the Lower Pad.
Notes and limitations
Key features
- Plots an Upper Pad and Lower Pad around the reference price.
- Configurable pad size in points.
- Optional freeze mode to lock levels at the start of a chosen session window, defaulting to 8:30 New York time.
- Optional take-profit and stop-loss guide levels for both long and short stop-entry scenarios.
- TP and SL levels are calculated from account-currency targets using the symbol point value and order size.
- Lines extend to the right for easier monitoring without leaving historical marks as new bars print.
- Clean, low-saturation colour palette designed to work on both dark and light charts.
How it works
Before the freeze time, SafePad tracks the latest chart price and displays the pad levels from the current candle. When freeze mode is enabled and the chart enters the configured freeze window, the indicator captures that candle’s open as the reference price and locks the pad levels from that point onward.
For example, with a 25-point pad, the Upper Pad is drawn 25 points above the reference price and the Lower Pad is drawn 25 points below it.
Take-profit and stop-loss guides
The optional TP and SL lines are derived from the configured dollar target, order size, and the symbol’s point value. These levels are visual planning aids for a hypothetical buy-stop at the Upper Pad and sell-stop at the Lower Pad.
Notes and limitations
- This is a visual planning indicator, not an automated trading system.
- TP/SL calculations depend on TradingView’s syminfo.pointvalue; verify values for the instrument and broker feed you trade.
- No trading signals, alerts, or order execution are included.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.