VWAP Dev -- VWAP Deviation
Contents
Overview
VWAP Deviation measures how many standard deviations the current closing price is from VWAP. It adds statistical rigor to VWAP analysis by quantifying not just whether price is above or below VWAP, but how extreme the deviation is relative to recent behavior.
The calculation is:
VWAP Dev = (close - VWAP) / rolling_std(close - VWAP, period)
Where rolling_std is the standard deviation of the difference between close and VWAP over the lookback period. This is conceptually identical to a Z-Score, but measured relative to VWAP instead of a simple moving average. The result tells you: "the current close is X standard deviations away from VWAP."
The key insight: instead of just knowing "price is below VWAP," VWAP Deviation tells you "price is 2.5 standard deviations below VWAP" -- a statistically rare event. Under normal distribution assumptions, values beyond +/-2.0 occur only about 5% of the time. The further from zero, the more extreme and unusual the current price is relative to the volume-weighted average. This transforms VWAP from a simple level into a statistically grounded framework for identifying high-probability mean-reversion opportunities.
Format
vwap_dev_{period}
The period defines the lookback window used to calculate the rolling standard deviation of the close-to-VWAP difference.
| Example | Period | Use Case |
|---|---|---|
vwap_dev_20 | 20 | Standard -- responsive to recent VWAP deviation patterns |
vwap_dev_50 | 50 | Slower -- captures longer-term VWAP deviation norms, fewer false extremes |
vwap_dev_10 | 10 | Fast -- reacts quickly but noisier, more frequent extreme readings |
Period range: 5 to 500.
Value range: Typically -4.0 to +4.0 (like Z-Score). 0 = price is at VWAP. Negative = price is below VWAP. Positive = price is above VWAP. Extreme values beyond +/-3.0 are rare and represent significant statistical events.
Understanding VWAP Dev Values
VWAP Dev uses a standardized scale (standard deviations), so its thresholds are universal -- unlike raw VWAP which is denominated in the asset's price currency. A VWAP Dev of -2.0 means the same thing for BTC, ETH, or SOL: price is 2 standard deviations below VWAP.
| VWAP Dev Range | Zone | Interpretation |
|---|---|---|
| Below -2.0 | Extreme discount | Price is far below VWAP -- a statistically rare event. Strong mean-reversion potential. Institutional buyers may view this as a significant bargain. |
| -2.0 to -1.0 | Moderate discount | Price is meaningfully below VWAP. Discount is notable but not extreme. Worth watching for confirmation. |
| -1.0 to 0 | Slight discount | Price is near VWAP, slightly below. Weak directional signal. Normal variation. |
| 0 to +1.0 | Slight premium | Price is near VWAP, slightly above. Normal variation. No strong signal. |
| +1.0 to +2.0 | Moderate premium | Price is meaningfully above VWAP. Profits may be taken. Overbought relative to volume-weighted average. |
| Above +2.0 | Extreme premium | Price is far above VWAP -- a statistically rare event. Strong mean-reversion potential to the downside. Consider taking profits or exiting. |
VWAP Dev is based on the same statistical framework as Z-Score. Under a normal distribution, values beyond +/-2.0 occur about 5% of the time, and values beyond +/-3.0 occur about 0.3% of the time. Crypto markets are not perfectly normal (they have fat tails), so extreme values occur somewhat more often -- but they still represent meaningful statistical events.
Understanding Operators with VWAP Dev
Each operator behaves differently with VWAP Dev. Because VWAP Dev is a standardized measure of deviation, it excels at identifying extremes for mean-reversion strategies.
< (Less Than) -- State-Based
What it does: The trigger is true on every candle where VWAP Dev is below the threshold. This detects periods when price is trading at a statistically significant discount to VWAP.
On the chart: Price has drifted far below the VWAP line. The further negative the VWAP Dev reading, the more extreme the discount. This trigger stays active for as long as VWAP Dev remains below the threshold.
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = "<"
target = "-2.0"
timeframe = "1h"
Typical use: Mean-reversion buy signal. When VWAP Dev is below -2.0, price is at a statistically rare discount to VWAP. This is the primary VWAP Dev operator for entry strategies.
> (Greater Than) -- State-Based
What it does: The trigger is true on every candle where VWAP Dev is above the threshold. This detects periods when price is trading at a statistically significant premium to VWAP.
On the chart: Price has drifted far above the VWAP line. The higher the VWAP Dev reading, the more stretched the premium.
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = ">"
target = "1.5"
timeframe = "1h"
Typical use: Exit signal or overextension warning. When VWAP Dev exceeds +1.5 or +2.0, price is stretched above its volume-weighted average. Profits should be considered. For aggressive strategies, this can be a short signal.
cross_below -- Event-Based
What it does: Fires once, at the exact candle where VWAP Dev transitions from above the threshold to below it. The previous candle had VWAP Dev >= the target, and the current candle has VWAP Dev < the target.
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = "cross_below"
target = "-2.0"
timeframe = "1h"
Typical use: Detect the moment price enters extreme discount territory. This captures the exact candle where the deviation becomes statistically significant -- useful for precision entries that fire only once at the critical moment.
cross_above -- Event-Based
What it does: Fires once, at the exact candle where VWAP Dev transitions from below the threshold to above it. The previous candle had VWAP Dev <= the target, and the current candle has VWAP Dev > the target.
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = "cross_above"
target = "2.0"
timeframe = "1h"
Typical use: Detect the moment price enters extreme premium territory. Useful as an exit trigger -- the exact candle where the premium becomes statistically overextended.
= (Equal) -- Not Recommended for VWAP Dev
Why: VWAP Dev produces floating-point values that are rarely exactly equal to any specific number. Use < or > instead.
- Use
<for mean-reversion buys -- price is at a statistically significant discount to VWAP. This is the most common VWAP Dev operator. - Use
>for exit signals or profit-taking -- price is at a statistically significant premium. - Use
cross_below/cross_aboveto detect the exact moment price enters an extreme deviation zone.
TOML Examples
Extreme VWAP Discount
Buy when price is more than 2 standard deviations below VWAP. This is a statistically rare event that offers a high-probability bounce. The max_count prevents repeated entries while price remains deeply discounted.
[[actions]]
type = "open_long"
amount = "100 USDC"
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = "<"
target = "-2.0"
timeframe = "1h"
max_count = 2
VWAP Premium Exit
Take profits when price is extended more than 1.5 standard deviations above VWAP. The premium is significant enough that mean reversion is likely.
[[actions]]
type = "sell"
amount = "100%"
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = ">"
target = "1.5"
timeframe = "1h"
max_count = 1
VWAP Dev Combined with VWAP Level
Use both raw VWAP (the level) and VWAP Dev (the significance). Price must be below VWAP AND the deviation must be statistically meaningful. This ensures you are not just buying a trivial dip below VWAP but a significant one.
[[actions]]
type = "open_long"
amount = "100 USDC"
[[actions.triggers]]
indicator = "price"
operator = "<"
target = "vwap"
timeframe = "1h"
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = "<"
target = "-1.5"
timeframe = "1h"
[[actions.triggers]]
indicator = "sma_50"
operator = ">"
target = "sma_200"
timeframe = "1d"
VWAP Dev and RSI Confluence
Combine VWAP Dev with RSI for double confirmation. When both statistical deviation from VWAP AND momentum oscillator agree that price is oversold, the setup has strong confluence.
[[actions]]
type = "open_long"
amount = "100 USDC"
[[actions.triggers]]
indicator = "vwap_dev_20"
operator = "<"
target = "-2.0"
timeframe = "1h"
[[actions.triggers]]
indicator = "rsi_14"
operator = "<"
target = "30"
timeframe = "1h"
[[actions.triggers]]
indicator = "obv"
operator = ">"
target = "obv_sma_20"
timeframe = "1h"
Tips
Unlike raw VWAP (which is denominated in the asset's price currency), VWAP Dev is standardized in standard deviations. A reading of -2.0 means the same thing for BTC, ETH, SOL, or any asset: price is 2 standard deviations below VWAP. This makes it easy to apply the same threshold logic across your entire portfolio without recalibrating per asset.
Raw VWAP gives you the price level -- where institutional fair value sits. VWAP Dev gives you the statistical significance -- how extreme the current deviation is. Used together, they answer two questions at once: "Is price below fair value?" (VWAP) and "Is this discount large enough to matter?" (VWAP Dev). The combination is far more powerful than either alone.
Knowing that BTC is "$500 below VWAP" is not actionable -- you need context. Is $500 a big move or a small one? VWAP Dev normalizes this by telling you "price is 2.1 standard deviations below VWAP." Now you know it is statistically significant regardless of the dollar amount. This normalization is what makes VWAP Dev valuable for systematic trading.
VWAP Dev identifies statistically extreme deviations, not guaranteed reversals. In a strong trend, VWAP Dev can stay at -3.0 for extended periods as VWAP lags behind a rapidly falling price. Always pair VWAP Dev with trend filters (SMA crossovers) and risk management (stop-losses, max_count). A -2.0 reading during a confirmed downtrend may just be the beginning of a larger selloff.