VWAP Pine Script Strategy for Futures
Banks and large algorithmic systems use VWAP as an execution benchmark, which is exactly why price tends to gravitate back toward it, reject from it, or break through it with real momentum. A VWAP reclaim is one of the cleanest setups available for a prop firm account.
Why VWAP suits prop firm trading
Most evaluation accounts carry a drawdown limit that punishes random, low-conviction entries and rewards a clearly defined edge. VWAP fits that requirement for three reasons:
- High-probability reversion. Price that dips below VWAP during a bullish session tends to reclaim it within the same session — a bias-confirmed entry with a specific, measurable stop.
- Clean risk definition. The stop sits below the reclaim candle's low, or below VWAP itself — a technical level, not an arbitrary tick count that ignores current volatility.
- Institutional alignment. The entry sits where large participants are also transacting, which puts the trade in line with real order flow rather than against it.
The VWAP reclaim setup
- Price opens above VWAP, establishing a bullish session bias
- Price dips below VWAP in the first 30–60 minutes of RTH
- Price closes back above VWAP on a confirmed bar
- Long entry fires on the next bar's open
- Stop sits below the reclaim candle's low
- Target sits at roughly 1.5–2x the risk
In Pine Script, the entry condition combines three checks:
close[1] < vwap[1]— the previous bar closed below VWAPclose > vwap— the current bar closed back above itbarstate.isconfirmed— the bar is fully closed, not repainting mid-candle
barstate.isconfirmed. An unconfirmed bar can cross VWAP mid-candle and
trigger a signal that disappears by the close — one of the most common ways a backtest ends up looking better
than live trading actually is.
Complete VWAP reclaim strategy — Pine Script
Drop this into TradingView on a 1- or 3-minute MNQ or MES chart. Inputs default to a 50k Apex evaluation
($2,500 trail) — adjust dailyLossLimit to match a different firm's rules.
//@version=5
strategy("VWAP Reclaim — Prop Firm", overlay = true,
default_qty_type = strategy.fixed, default_qty_value = 1)
// ── inputs ───────────────────────────────────────────────────────────
dailyLossLimit = input.float(800.0, "Daily Loss Limit ($)")
atrMult = input.float(0.8, "ATR Stop Multiplier")
rrRatio = input.float(1.5, "Reward:Risk Ratio")
// ── session filter: 9:30–11:00 ET ───────────────────────────────────
inSession = not na(time("1", "0930-1100:23456", "America/New_York"))
// ── daily P&L tracking ────────────────────────────────────────────────
isNewSession = ta.change(time("D")) != 0
var float dayOpenEq = na
dayOpenEq := isNewSession ? strategy.equity : dayOpenEq
dailyPnl = strategy.equity - nz(dayOpenEq, strategy.equity)
tradingHalted = dailyPnl <= -dailyLossLimit
// ── VWAP reclaim conditions ──────────────────────────────────────────
vwapVal = ta.vwap(hlc3)
atrVal = ta.atr(14)
volOk = volume > ta.sma(volume, 20)
longCond = close[1] < vwapVal[1] and close > vwapVal and barstate.isconfirmed and volOk
shortCond = close[1] > vwapVal[1] and close < vwapVal and barstate.isconfirmed and volOk
if longCond and inSession and not tradingHalted and strategy.position_size == 0
stopDist = atrMult * atrVal
strategy.entry("L", strategy.long)
strategy.exit("L-x", "L", profit = stopDist * rrRatio / syminfo.mintick,
loss = stopDist / syminfo.mintick)
if shortCond and inSession and not tradingHalted and strategy.position_size == 0
stopDist = atrMult * atrVal
strategy.entry("S", strategy.short)
strategy.exit("S-x", "S", profit = stopDist * rrRatio / syminfo.mintick,
loss = stopDist / syminfo.mintick)
// ── EOD / Friday flatten ─────────────────────────────────────────────
eodWindow = not na(time("1", "1530-1600:23456", "America/New_York")) or
(dayofweek == dayofweek.friday and
not na(time("1", "1500-1601:6", "America/New_York")))
if eodWindow and strategy.position_size != 0
strategy.close_all("EOD Flat") Built-in VWAP vs. a custom anchor
TradingView's ta.vwap is session-anchored by default and resets at the RTH open — sufficient for
most evaluation strategies. For more specific use cases, VWAP can be anchored elsewhere:
| Anchor type | Use case | How |
|---|---|---|
| Session (default) | Standard intraday setups | ta.vwap |
| Week | Multi-day swing context | Custom cumulative sum from Monday's open |
| Month | Institutional positioning level | Custom cumulative sum from the month's open |
| Event-anchored | Post-earnings or post-FOMC context | Manual anchor bar tracked in a variable |
VWAP bands for stop and target sizing
Standard-deviation bands around VWAP — the same underlying math as Bollinger Bands, anchored to the session's cumulative mean instead — give a volatility-adjusted stop and target that scale with the current session rather than a fixed tick distance.
- 1st standard deviation: the normal noise zone — price here is simply consolidating near VWAP
- 2nd standard deviation: an extension zone — price this stretched relative to session flow makes a reversion trade a stronger technical bet
When a reclaim fires with price near the 2nd standard deviation below VWAP, the risk/reward improves meaningfully — a technically stronger entry with a larger realistic target (back to VWAP or the 1st band) relative to the stop.
Session anchoring: NQ vs. ES
NQ and ES behave differently around VWAP due to their composition:
- NQ reclaims tend to happen faster with less pullback, which argues for a slightly more aggressive entry
- ES setups are more orderly — the dip is often shallower and the reclaim more gradual
- NQ's strongest reclaim window is roughly 9:30–10:15 AM ET; after that, continuation setups tend to outperform reversion
- ES's VWAP setups stay valid through noon ET on most sessions
Adding a volume confirmation filter
The most common failure mode for a VWAP reclaim is entering on a thin, low-volume cross that doesn't hold.
Requiring the reclaim bar's volume to exceed its 20-bar average (volume > ta.sma(volume, 20))
confirms real participation behind the move rather than noise.
Risk sizing on a prop firm account
Because a VWAP reclaim stop sits below a specific candle rather than a fixed distance, stop size varies day to day — 25 points on a volatile NQ session, 8 points on a quiet one. Using ATR keeps risk proportional:
- Calculate
atrVal = ta.atr(14) - Skip the trade if the entry-to-stop distance exceeds roughly 1.5x
atrVal— the reclaim candle is unusually large relative to normal range
Short-side VWAP rejection
The inverse setup works the same way: price sits below VWAP, bounces up to touch it, then gets rejected back down. Short entry fires on the close below VWAP after the failed reclaim attempt — the bearish mirror of the long setup, and a strong performer on trend-down days.