Skip to content
AlgoBeam

Volume Weighted Average PriceVWAP

What has the average participant actually paid since the session began, and is the current price above or below that?

VolumeOverlayIntermediate

On a chart

Volume Weighted Average Price on NASDAQ:TSLA, 15-minute bars. The widget is interactive — change the instrument or the timeframe and check whether the description still holds.

StudySTD;VWAP
Live market data by TradingView

How it works

VWAP is the average price of every unit traded over a period, with each print weighted by its size. Because it is weighted by quantity rather than by time, it answers a question no ordinary moving average can: relative to everyone who has transacted in this window, is the current price a good fill or a bad one? A ten-thousand-share trade moves it a hundred times as much as a hundred-share trade at the same price.

The defining property is that it accumulates rather than rolls. It resets at the start of each session and then sums every subsequent bar, which gives it a distinctive character over the day: jumpy and close to meaningless in the first few bars, when the denominator is tiny, and progressively anchored as the session fills up, until by the afternoon it barely moves at all. That is a feature for its original purpose and a trap for anyone who reads it as a signal line late in the day.

It exists because of execution, not because of chart analysis. A desk instructed to accumulate a large position over a day is measured against the session VWAP: fill below it and the trader beat the benchmark. That mandate creates genuine mechanical demand around the line — execution algorithms slow down when price runs above it and speed up when it dips below — which is why intraday traders treat VWAP as both a magnet and a bias line rather than as a mystical level. Above a rising VWAP is a structurally different environment from chopping across a flat one.

Bands extend the idea. Adding one, two and three volume-weighted standard deviations of price either side of the running line gives a channel that expresses how stretched the current price is against the day's own distribution of trade. In a trending session price rides the first band; in a balanced session the outer bands mark the edges where responsive traders fade the move.

The anchored variant runs identical arithmetic from a chosen bar instead of the session open — an earnings gap, a swing low, the first trade of the year. The line then shows the average cost of everyone who has transacted since that event, which is a good proxy for the price at which a whole cohort of positions flips from profitable to underwater. Anchored VWAP is the version that works on daily and weekly charts, where a session-resetting VWAP has nothing useful to accumulate.

Calculation

The arithmetic in words, in the order it happens.

Cumulative, not rolling. For each bar take a typical price, conventionally (high + low + close) / 3, and multiply it by that bar's volume. VWAP is the running sum of those products divided by the running sum of volume, restarted at the beginning of each anchor period. Bands are built from the volume-weighted variance of price around the running average: accumulate volume multiplied by the squared deviation of the typical price from the running VWAP, divide by cumulative volume, take the square root, and add multiples of that above and below the line. Anchored VWAP applies exactly the same steps from a user-selected starting bar.

Source

An AlgoBeamScript implementation of the formula above, written by us from the arithmetic so the code and the calculation agree line for line.

Loading the implementation…

Runs unchanged on the platform and in the AlgoBeamTS runtime. The language reference is in the documentation.

Inputs

Defaults are the values most charting packages ship with. They are conventions, not optimal settings — the right length depends on your instrument and your holding period.

InputDefaultWhat it changes
Anchor periodSessionWhere the accumulation restarts. Session is the intraday default. Week, month, quarter and year produce progressively slower reference lines that are usable on higher timeframes, and an event anchor — earnings, a gap, a swing extreme — turns it into the anchored variant.
Sourcehlc3The price each bar contributes. The (high + low + close) / 3 average is the convention because it approximates the average traded price of the bar better than the close does. Using the close makes the line jumpier and slightly biased toward end-of-bar prints.
Bands multiplier1, 2 and 3How many volume-weighted standard deviations each band sits from the line. Lower multipliers give a channel price touches constantly; higher ones isolate genuinely stretched excursions but fire rarely.
Bands calculation modeStandard deviationStandard-deviation bands adapt to how dispersed the session's trade has been. A fixed percentage offset instead gives evenly spaced lines that are easier to compare across days but ignore the character of the session.

How to read it

What practitioners take from the plot. Read these as descriptions of market state, not as entry signals.

Price holding above a rising VWAP all session
Buyers are paying above the day's average cost and the average itself is being pulled up. A trend-day signature; pullbacks to the line are where trend traders look to add rather than to fade.
Price crossing back and forth over a flat VWAP
Balance. The session has no directional agreement, and both breakout and reversion rules built on the line will be chopped up. Usually a reason to trade smaller or not at all.
Price extended to the second or third band
The move is stretched relative to the session's own distribution of trade. In a balanced day that is a reversion reference; on a trend day price can ride the first and second bands for hours, so the band alone is not a fade.
Repeated rejection of VWAP from below
Sellers are defending the average cost. Every attempt to reclaim the benchmark is being met, which keeps the session bias negative until the line is closed above and held.
An anchored VWAP from a major event acting as support
Price is finding buyers at the average cost of everyone who transacted since that event. It marks the boundary at which that cohort collectively moves from gain to loss, which is why it often produces a reaction.

Limitations

Where this indicator misleads. None of these are fixed by a better parameter.

  • The cumulative construction cuts both ways. In the first bars of a session the line is built from almost no data and swings wildly; by the last hour it is so heavily weighted by the morning that genuinely new information barely moves it.
  • It is only as good as the volume feed. Fragmented equity trading, venue-specific crypto volume and unreported off-exchange prints all mean two providers can draw materially different lines for the same instrument.
  • It is unusable on spot forex and on any instrument without real traded quantity, since tick counts are not volume and the weighting then means nothing.
  • Crossing VWAP is a fact about the day, not a trade. Used mechanically as a long or short trigger it whipsaws badly on balanced sessions, which are the majority of sessions.

Educational reference. This page explains how an indicator is built and how it is commonly read. It is not investment advice, not a recommendation and not a signal service. No indicator is profitable on its own — each is a way of describing a market, and any rule built on one has to be tested with realistic costs before it is traded.

Ready when you are

Reading it is half of it.

The write-up tells you how Volume Weighted Average Price is supposed to behave. A backtest tells you how it actually behaved on your instrument, over your timeframe, with spread and commission included.

  • No card required
  • Cancel anytime
  • 14-day Ultimate trial