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.
סקריפט קוד פתוח
ברוח האמיתית של TradingView, יוצר הסקריפט הזה הפך אותו לקוד פתוח, כך שסוחרים יוכלו לעיין בו ולאמת את פעולתו. כל הכבוד למחבר! אמנם ניתן להשתמש בו בחינם, אך זכור כי פרסום חוזר של הקוד כפוף ל־כללי הבית שלנו.
כתב ויתור
המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.
סקריפט קוד פתוח
ברוח האמיתית של TradingView, יוצר הסקריפט הזה הפך אותו לקוד פתוח, כך שסוחרים יוכלו לעיין בו ולאמת את פעולתו. כל הכבוד למחבר! אמנם ניתן להשתמש בו בחינם, אך זכור כי פרסום חוזר של הקוד כפוף ל־כללי הבית שלנו.
כתב ויתור
המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.