🎁 Free Pine Script Code — No Signup Required

5 Free TradingView
Indicators With
Pine Script Code

Copy-paste Pine Script code ready to paste into TradingView's editor right now. Each indicator includes the exact JSON alert message for automation via Traders Post or any webhook tool.

📋
How to add any indicator to TradingView
1 Copy the Pine Script code
2 Open TradingView → Pine Script Editor
3 Paste & click Add to chart
4 Set up alert with the JSON message provided
Jump to indicator
📈
Indicator 01
Extended VWAP Reversal
Identifies high-probability mean-reversion setups at VWAP standard deviation extensions
FREE CODE Forex · Futures · Crypto 1m – 1H

The Extended VWAP Reversal identifies when price has extended significantly beyond VWAP's standard deviation bands and shows signs of reversing back toward the mean. It fires long alerts when price is below the -1.5 SD band and a reversal candle forms, and short alerts when price is above the +1.5 SD band. Works best on ES/NQ futures during the NY session open (9:30–11am ET) and on forex major pairs during London session.

Pine Script Code
How to Set Up
JSON Alert Message
Trading Tips
Pine Script v5
// ═══════════════════════════════════════════════
// Extended VWAP Reversal Indicator
// PropHub — Free for everyone
// TradingView Pine Script v5
// ═══════════════════════════════════════════════

//@version=5
indicator("PropHub — Extended VWAP Reversal", overlay=true, max_lines_count=500)

// ── INPUTS ──────────────────────────────────────
sd_mult_1   = input.float(1.0,  "SD Band 1 Multiplier", minval=0.1)
sd_mult_2   = input.float(1.5,  "SD Band 1.5 Multiplier (Entry Zone)", minval=0.1)
sd_mult_3   = input.float(2.0,  "SD Band 2 Multiplier (Stop Zone)", minval=0.1)
show_bands  = input.bool(true, "Show VWAP Bands")
show_alerts = input.bool(true, "Enable Alert Conditions")
bar_lookback = input.int(3, "Reversal Candle Lookback", minval=1, maxval=5)

// ── VWAP CALCULATION ────────────────────────────
// Standard VWAP with standard deviation bands
vwap_val    = ta.vwap(hlc3)
variance    = ta.sma(math.pow(hlc3 - vwap_val, 2), 20)
stdev       = math.sqrt(variance)

upper_1     = vwap_val + (stdev * sd_mult_1)
upper_2     = vwap_val + (stdev * sd_mult_2)
upper_3     = vwap_val + (stdev * sd_mult_3)
lower_1     = vwap_val - (stdev * sd_mult_1)
lower_2     = vwap_val - (stdev * sd_mult_2)
lower_3     = vwap_val - (stdev * sd_mult_3)

// ── REVERSAL CONDITIONS ─────────────────────────
// Bullish: Price below lower 1.5SD band + reversal candle
price_below_band = ta.lowest(low, bar_lookback) < lower_2
bull_reversal    = close > open                        // Green candle
bull_engulf      = close > open[1] and open < close[1]  // Engulfing pattern
bull_signal      = price_below_band and (bull_reversal or bull_engulf) and close > lower_2

// Bearish: Price above upper 1.5SD band + reversal candle
price_above_band = ta.highest(high, bar_lookback) > upper_2
bear_reversal    = close < open                         // Red candle
bear_engulf      = close < open[1] and open > close[1]  // Engulfing pattern
bear_signal      = price_above_band and (bear_reversal or bear_engulf) and close < upper_2

// ── PLOTS ────────────────────────────────────────
plot(vwap_val, "VWAP", color=color.new(color.white, 0), linewidth=2)

if show_bands
    plot(upper_1, "Upper 1SD",  color=color.new(color.blue, 60), linewidth=1)
    plot(upper_2, "Upper 1.5SD", color=color.new(color.orange, 30), linewidth=1)
    plot(upper_3, "Upper 2SD",  color=color.new(color.red, 30), linewidth=1)
    plot(lower_1, "Lower 1SD",  color=color.new(color.blue, 60), linewidth=1)
    plot(lower_2, "Lower 1.5SD", color=color.new(color.orange, 30), linewidth=1)
    plot(lower_3, "Lower 2SD",  color=color.new(color.red, 30), linewidth=1)

// Background highlight when in entry zone
bgcolor(price_below_band ? color.new(color.green, 93) : na)
bgcolor(price_above_band ? color.new(color.red, 93) : na)

// Signal arrows on chart
plotshape(bull_signal, "Long Signal",  shape.labelup,   location.belowbar, color.new(color.green, 0), text="▲ VWAP REV", textcolor=color.white, size=size.small)
plotshape(bear_signal, "Short Signal", shape.labeldown, location.abovebar, color.new(color.red, 0),   text="▼ VWAP REV", textcolor=color.white, size=size.small)

// ── ALERT CONDITIONS ────────────────────────────
if show_alerts
    alertcondition(bull_signal, "VWAP Reversal — LONG",
         "PropHub VWAP Reversal: LONG signal on " + syminfo.ticker)
    alertcondition(bear_signal, "VWAP Reversal — SHORT",
         "PropHub VWAP Reversal: SHORT signal on " + syminfo.ticker)
1
Copy the code above
Click "Copy Code" on the Pine Script tab. The entire indicator code is copied to your clipboard.
2
Open Pine Script Editor in TradingView
At the bottom of any TradingView chart, click Pine Editor. Delete any existing code, paste yours in, and click Add to chart.
3
Apply to the right chart
Works best on ES1!, NQ1!, EURUSD, or GBPUSD on 5m or 15m timeframes during the NY or London session open.
4
Create the alert
Right-click the chart → Add Alert. Under Condition, select PropHub — Extended VWAP Reversal and choose either the LONG or SHORT alert condition. Set Trigger: Once Per Bar Close.
5
Add webhook URL
In the alert settings, enable Webhook URL and paste your Traders Post webhook URL. Then paste the JSON message from the JSON tab into the Message box.
⚠️
TradingView Pro Required for Webhooks
Webhook alerts require TradingView Pro or higher (~£12/month). The Essential (free) plan does not support webhooks. Standard alerts still work on free plans — you'll just need to act on them manually.

Paste this into the Message box of your TradingView alert. Replace YOUR_ACCOUNT_ID with your Traders Post account ID.

▲ LONG ALERT MESSAGE:

JSON — Traders Post Long
{
  "account": "YOUR_ACCOUNT_ID",
  "ticker": "{{ticker}}",
  "action": "buy",
  "order_type": "market",
  "quantity": 1,
  "comment": "VWAP_REV_LONG_{{timenow}}"
}

▼ SHORT ALERT MESSAGE:

JSON — Traders Post Short
{
  "account": "YOUR_ACCOUNT_ID",
  "ticker": "{{ticker}}",
  "action": "sell",
  "order_type": "market",
  "quantity": 1,
  "comment": "VWAP_REV_SHORT_{{timenow}}"
}
💡
Position Sizing
Set "quantity" to your desired lot size. For prop firm accounts, configure your stop loss and take profit inside Traders Post's position settings rather than in the JSON — this gives you more control and lets you adjust without changing your TradingView alert.
Best Conditions for This Indicator
Works best in the first 90 minutes of the NY session (9:30–11am ET) on ES or NQ futures. Also reliable on EUR/USD and GBP/USD during the London session overlap. Avoid using it in low-volume, slow markets (Asian session on equity futures, pre-market).
⚠️
Prop Firm Risk Rule
Always configure your position size for maximum 1% account risk per trade in Traders Post. On a $50K Apex account, that's a maximum $500 risk per trade. The indicator fires the signal — your risk management in Traders Post controls the size.
🔗
Pairs Well With
Use alongside the Session Open Lines indicator (below) to ensure you're only trading during the highest-probability session windows. The VWAP Reversal without session context generates too many signals in slow markets.
🔄
Indicator 02
WCR — Weekly & Daily Close Reversal
Identifies key reversal setups at weekly and daily close price levels
FREE CODE Forex · All Markets 1H – Daily

The WCR (Weekly/Daily Close Reversal) system identifies when price returns to the previous week's or day's closing price and shows a reversal pattern. These close levels are watched by institutional traders — making them high-probability reaction zones. The indicator plots the levels and fires alerts when price touches and rejects from them.

Pine Script Code
How to Set Up
JSON Alert Message
Trading Tips
Pine Script v5
// ═══════════════════════════════════════════════
// WCR — Weekly & Daily Close Reversal
// PropHub — Free for everyone
// TradingView Pine Script v5
// ═══════════════════════════════════════════════

//@version=5
indicator("PropHub — WCR Weekly & Daily Close Reversal", overlay=true)

// ── INPUTS ──────────────────────────────────────
show_weekly      = input.bool(true,  "Show Weekly Close Level")
show_daily       = input.bool(true,  "Show Daily Close Level")
touch_threshold  = input.float(0.0010, "Touch Threshold (pips)", step=0.0001)
reversal_bars    = input.int(2, "Reversal Confirmation Bars", minval=1, maxval=5)
weekly_col       = input.color(color.new(color.yellow, 0),  "Weekly Close Line Color")
daily_col        = input.color(color.new(color.aqua, 0),    "Daily Close Line Color")

// ── GET CLOSE LEVELS ────────────────────────────
// Previous week's close (request weekly data)
weekly_close = request.security(syminfo.tickerid, "W", close[1], lookahead=barmerge.lookahead_on)

// Previous day's close (request daily data)
daily_close  = request.security(syminfo.tickerid, "D", close[1], lookahead=barmerge.lookahead_on)

// ── TOUCH & REVERSAL LOGIC ──────────────────────
// Did price touch or come within threshold of the level?
near_weekly_bull = low <= weekly_close + touch_threshold and low >= weekly_close - touch_threshold
near_weekly_bear = high >= weekly_close - touch_threshold and high <= weekly_close + touch_threshold
near_daily_bull  = low <= daily_close + touch_threshold and low >= daily_close - touch_threshold
near_daily_bear  = high >= daily_close - touch_threshold and high <= daily_close + touch_threshold

// Reversal candle confirmation
bull_candle = close > open and close > open[1]
bear_candle = close < open and close < open[1]

// Combined signals
wcr_weekly_long  = near_weekly_bull and bull_candle
wcr_weekly_short = near_weekly_bear and bear_candle
wcr_daily_long   = near_daily_bull  and bull_candle
wcr_daily_short  = near_daily_bear  and bear_candle

// ── PLOT LEVELS ─────────────────────────────────
if show_weekly
    hline(weekly_close, "Prev Week Close", color=weekly_col, linestyle=hline.style_dashed, linewidth=2)

if show_daily
    hline(daily_close, "Prev Day Close", color=daily_col, linestyle=hline.style_dotted, linewidth=1)

// Plot dynamic lines for current session
weekly_line = line.new(bar_index - 50, weekly_close, bar_index, weekly_close,
              extend=extend.right, color=weekly_col, style=line.style_dashed, width=2)
daily_line  = line.new(bar_index - 50, daily_close,  bar_index, daily_close,
              extend=extend.right, color=daily_col,  style=line.style_dotted, width=1)

// Add labels at line price
label.new(bar_index, weekly_close, " PWC: " + str.tostring(weekly_close, "#.#####"),
          style=label.style_label_left, color=weekly_col, textcolor=color.black, size=size.small)
label.new(bar_index, daily_close,  " PDC: " + str.tostring(daily_close,  "#.#####"),
          style=label.style_label_left, color=daily_col,  textcolor=color.black, size=size.small)

// Signal markers
plotshape(wcr_weekly_long,  "WCR Weekly Long",  shape.triangleup,   location.belowbar, color.new(color.yellow, 0), size=size.normal)
plotshape(wcr_weekly_short, "WCR Weekly Short", shape.triangledown, location.abovebar, color.new(color.yellow, 0), size=size.normal)
plotshape(wcr_daily_long,   "WCR Daily Long",   shape.triangleup,   location.belowbar, color.new(color.aqua, 20),   size=size.small)
plotshape(wcr_daily_short,  "WCR Daily Short",  shape.triangledown, location.abovebar, color.new(color.aqua, 20),   size=size.small)

// ── ALERT CONDITIONS ────────────────────────────
alertcondition(wcr_weekly_long,  "WCR Weekly LONG",  "WCR: Weekly Close LONG on " + syminfo.ticker)
alertcondition(wcr_weekly_short, "WCR Weekly SHORT", "WCR: Weekly Close SHORT on " + syminfo.ticker)
alertcondition(wcr_daily_long,   "WCR Daily LONG",   "WCR: Daily Close LONG on "  + syminfo.ticker)
alertcondition(wcr_daily_short,  "WCR Daily SHORT",  "WCR: Daily Close SHORT on " + syminfo.ticker)
1
Best timeframes
Apply on 1H or 4H charts. The weekly close level is significant on higher timeframes. The daily close works well on 1H for intraday setups.
2
Adjust the touch threshold
Default is 0.0010 (10 pips for forex). For indices or futures, adjust to match the typical pip/tick value. For ES futures use approximately 2.0, for gold use 1.5.
3
Set up both alert conditions
Create separate alerts for Weekly Long, Weekly Short, Daily Long and Daily Short. Set each to trigger Once Per Bar Close on your chosen timeframe.
4
Monday morning routine
Every Sunday/Monday morning, note where the PWC (Previous Week Close) sits on EUR/USD, GBP/USD and your primary pairs. These are your key levels for the entire week.

Four separate JSON messages — one for each alert condition. Create four separate alerts in TradingView, each pointing to the same webhook URL with its corresponding message.

WCR Weekly Long
{
  "account": "YOUR_ACCOUNT_ID",
  "ticker": "{{ticker}}",
  "action": "buy",
  "order_type": "market",
  "quantity": 1,
  "comment": "WCR_WEEKLY_LONG"
}
WCR Daily Long
{
  "account": "YOUR_ACCOUNT_ID",
  "ticker": "{{ticker}}",
  "action": "buy",
  "order_type": "market",
  "quantity": 1,
  "comment": "WCR_DAILY_LONG"
}

For Short alerts, change "action": "buy" to "action": "sell"

The Weekly Close is the Priority Level
The previous week's close (PWC) is the more significant level. Institutional rebalancing and position-taking often occurs around these levels. Focus on the Weekly Close signals first, using Daily Close signals as secondary confirmation or for lower-timeframe precision entries.
⚠️
Don't Trade Every Touch
The WCR works best when the touch happens with broader market context aligned. A bullish WCR setup is much stronger when the Daily and Weekly trend is also bullish. Always check the higher timeframe structure before acting on a WCR signal.
💡
Prop Firm Compatibility
WCR setups typically produce slow, measured moves with clear stop placement behind the close level. This makes them ideal for prop firm trading — defined risk, clear target. Works on all forex firms (FTMO, The5ers, FundedNext) and overnight-capable accounts.
🌅
Indicator 03
London Breakout Marker
Marks Asian session range and fires alert on London open breakout
FREE CODE Forex 15m – 1H

Automatically identifies the Asian session high and low (midnight–7am GMT) and fires an alert when price breaks out of the range at the London open. Fully automated set-and-forget — mark the range before work, get alerted to the breakout, Traders Post executes the trade.

Pine Script Code
JSON Alert
Pine Script v5
// PropHub — London Breakout Marker
//@version=5
indicator("PropHub — London Breakout Marker", overlay=true)

// ── INPUTS ──────────────────────────────────────
asian_start  = input.int(0,  "Asian Session Start (GMT Hour)", minval=0,  maxval=23)
asian_end    = input.int(7,  "Asian Session End (GMT Hour)",   minval=0,  maxval=23)
london_start = input.int(7,  "London Open (GMT Hour)",         minval=0,  maxval=23)
buffer_pips  = input.float(2, "Breakout Buffer (pips)",         step=0.5)

// ── SESSION TIME CHECK ───────────────────────────
is_asian_session = (hour(time, "GMT+0") >= asian_start and hour(time, "GMT+0") < asian_end)
is_london_open   = (hour(time, "GMT+0") >= london_start and hour(time, "GMT+0") < london_start + 4)

// ── TRACK ASIAN RANGE ───────────────────────────
// Reset daily and build range during Asian session
var float asian_high = na
var float asian_low  = na
var bool  range_set  = false

if dayofweek(time) != dayofweek(time[1])
    asian_high := na
    asian_low  := na
    range_set  := false

if is_asian_session
    asian_high := na(asian_high) ? high : math.max(asian_high, high)
    asian_low  := na(asian_low)  ? low  : math.min(asian_low,  low)
    range_set  := true

// ── BREAKOUT CONDITIONS ──────────────────────────
buffer    = buffer_pips * syminfo.mintick * 10
bull_break = range_set and is_london_open and close > asian_high + buffer and close[1] <= asian_high + buffer
bear_break = range_set and is_london_open and close < asian_low  - buffer and close[1] >= asian_low  - buffer

// ── PLOTS ────────────────────────────────────────
plot(range_set ? asian_high : na, "Asian High", color=color.new(color.orange, 0), linewidth=1, style=plot.style_linebr)
plot(range_set ? asian_low  : na, "Asian Low",  color=color.new(color.orange, 0), linewidth=1, style=plot.style_linebr)

bgcolor(is_asian_session  ? color.new(color.blue,   95) : na, title="Asian Session")
bgcolor(is_london_open    ? color.new(color.yellow, 95) : na, title="London Session")

plotshape(bull_break, "Bullish Breakout", shape.labelup,   location.belowbar, color.new(color.green, 0), text="▲ LDN BRK", textcolor=color.white, size=size.small)
plotshape(bear_break, "Bearish Breakout", shape.labeldown, location.abovebar, color.new(color.red, 0),   text="▼ LDN BRK", textcolor=color.white, size=size.small)

alertcondition(bull_break, "London Breakout — LONG",  "London Breakout LONG: " + syminfo.ticker)
alertcondition(bear_break, "London Breakout — SHORT", "London Breakout SHORT: " + syminfo.ticker)
London Breakout Long
{
  "account": "YOUR_ACCOUNT_ID",
  "ticker": "{{ticker}}",
  "action": "buy",
  "order_type": "market",
  "quantity": 1,
  "comment": "LDN_BREAKOUT_LONG"
}
📊
Indicator 04
EMA Cross Alert System
20/50 EMA crossover with trend filter — fires only on high-quality signals
FREE CODE All Markets 1H – 4H

A clean 20/50 EMA crossover system with a higher-timeframe trend filter to reduce false signals. Only fires when the cross aligns with the higher timeframe trend direction — dramatically reducing noise compared to a standard EMA cross indicator.

Pine Script Code
JSON Alert
Pine Script v5
// PropHub — EMA Cross Alert System
//@version=5
indicator("PropHub — EMA Cross Alert System", overlay=true)

// ── INPUTS ──────────────────────────────────────
fast_len     = input.int(20,  "Fast EMA Length")
slow_len     = input.int(50,  "Slow EMA Length")
trend_len    = input.int(200, "Trend Filter EMA Length")
use_filter   = input.bool(true, "Use Trend Filter (200 EMA)")
atr_filter   = input.bool(true, "Use ATR Volatility Filter")
min_atr_mult = input.float(0.5, "Minimum ATR Multiplier for Signal", step=0.1)

// ── EMA CALCULATIONS ─────────────────────────────
fast_ema  = ta.ema(close, fast_len)
slow_ema  = ta.ema(close, slow_len)
trend_ema = ta.ema(close, trend_len)
atr_val   = ta.atr(14)

// ── TREND FILTER ─────────────────────────────────
bull_trend = not use_filter or close > trend_ema
bear_trend = not use_filter or close < trend_ema

// ── VOLATILITY FILTER ────────────────────────────
// Only trade when there's sufficient volatility
ema_distance  = math.abs(fast_ema - slow_ema)
min_distance  = atr_val * min_atr_mult
vol_ok        = not atr_filter or ema_distance >= min_distance

// ── CROSSOVER CONDITIONS ─────────────────────────
cross_up   = ta.crossover(fast_ema, slow_ema)
cross_down = ta.crossunder(fast_ema, slow_ema)

bull_signal = cross_up   and bull_trend and vol_ok
bear_signal = cross_down and bear_trend and vol_ok

// ── PLOTS ────────────────────────────────────────
plot(fast_ema,  "Fast EMA (20)",  color=color.new(color.aqua,  0),  linewidth=1)
plot(slow_ema,  "Slow EMA (50)",  color=color.new(color.orange, 0), linewidth=1)
plot(trend_ema, "Trend EMA (200)", color=color.new(color.white, 60), linewidth=1)

// Colour fill between EMAs
ema_col = fast_ema > slow_ema ? color.new(color.green, 90) : color.new(color.red, 90)
fill(plot(fast_ema, display=display.none), plot(slow_ema, display=display.none), color=ema_col)

plotshape(bull_signal, "EMA Cross Long",  shape.labelup,   location.belowbar, color.new(color.green, 0), text="▲ EMA X", textcolor=color.white, size=size.small)
plotshape(bear_signal, "EMA Cross Short", shape.labeldown, location.abovebar, color.new(color.red, 0),   text="▼ EMA X", textcolor=color.white, size=size.small)

alertcondition(bull_signal, "EMA Cross — LONG",  "EMA Cross LONG: "  + syminfo.ticker)
alertcondition(bear_signal, "EMA Cross — SHORT", "EMA Cross SHORT: " + syminfo.ticker)
EMA Cross Long
{
  "account": "YOUR_ACCOUNT_ID",
  "ticker": "{{ticker}}",
  "action": "buy",
  "order_type": "market",
  "quantity": 1,
  "comment": "EMA_CROSS_LONG"
}
🕐
Indicator 05
Session Open Lines
Automatically plots London, New York and Asian session opens on any chart
FREE CODE All Markets Any

A utility indicator that automatically marks the open price of each major trading session — London (8am GMT), New York (1pm GMT), and Asian (midnight GMT). Session open levels act as significant intraday support and resistance — essential reference points for all session-based strategies.

Pine Script Code
Pine Script v5
// PropHub — Session Open Lines
//@version=5
indicator("PropHub — Session Open Lines", overlay=true, max_lines_count=500)

// ── INPUTS ──────────────────────────────────────
show_london  = input.bool(true,  "Show London Open (8am GMT)")
show_ny      = input.bool(true,  "Show NY Open (1pm GMT)")
show_asian   = input.bool(true,  "Show Asian Open (12am GMT)")
line_len     = input.int(80,  "Line Length (bars)")
london_col   = input.color(color.new(color.yellow, 20), "London Open Color")
ny_col       = input.color(color.new(color.green,  20), "NY Open Color")
asian_col    = input.color(color.new(color.blue,   20), "Asian Open Color")

// ── SESSION DETECTION ────────────────────────────
gmt_hour     = hour(time, "GMT+0")
gmt_minute   = minute(time, "GMT+0")

is_london_open = (gmt_hour == 8  and gmt_minute == 0)
is_ny_open     = (gmt_hour == 13 and gmt_minute == 0)
is_asian_open  = (gmt_hour == 0  and gmt_minute == 0)

// ── DRAW LINES AT SESSION OPENS ─────────────────
if show_london and is_london_open
    london_line = line.new(bar_index, open, bar_index + line_len, open,
                  extend=extend.right, color=london_col, style=line.style_dashed, width=2)
    london_lbl  = label.new(bar_index, open, " London Open: " + str.tostring(open, "#.#####"),
                  style=label.style_label_right, color=london_col, textcolor=color.black, size=size.small)

if show_ny and is_ny_open
    ny_line     = line.new(bar_index, open, bar_index + line_len, open,
                  extend=extend.right, color=ny_col, style=line.style_dashed, width=2)
    ny_lbl      = label.new(bar_index, open, " NY Open: " + str.tostring(open, "#.#####"),
                  style=label.style_label_right, color=ny_col, textcolor=color.black, size=size.small)

if show_asian and is_asian_open
    asian_line  = line.new(bar_index, open, bar_index + line_len, open,
                  extend=extend.right, color=asian_col, style=line.style_dotted, width=1)
    asian_lbl   = label.new(bar_index, open, " Asian Open: " + str.tostring(open, "#.#####"),
                  style=label.style_label_right, color=asian_col, textcolor=color.black, size=size.small)

// ── BACKGROUND SHADING ───────────────────────────
london_session = (gmt_hour >= 8  and gmt_hour < 13)
ny_session     = (gmt_hour >= 13 and gmt_hour < 21)
asian_session  = (gmt_hour >= 0  and gmt_hour < 8)

bgcolor(show_london and london_session ? color.new(color.yellow, 97) : na, title="London Session BG")
bgcolor(show_ny     and ny_session     ? color.new(color.green,  97) : na, title="NY Session BG")
bgcolor(show_asian  and asian_session  ? color.new(color.blue,   97) : na, title="Asian Session BG")
🔗
Now Connect These to Traders Post

You have the indicators. Now connect them to your prop firm broker so they execute automatically while you're at work.

Traders Post Setup Guide → JSON Messages Guide