volume
Cumulative Volume
Beginner
OBV

On-Balance Volume

A cumulative volume indicator that adds volume on up days and subtracts it on down days to track buying and selling pressure.

Overview

On-Balance Volume (OBV) was developed by Joseph Granville and introduced in his 1963 book "Granville's New Key to Stock Market Profits." It is one of the first indicators to use volume to predict price movements. The concept is simple: when the stock closes higher, all the day's volume is classified as "up volume" (smart money buying); when it closes lower, all volume is "down volume" (smart money selling). The cumulative sum of these volumes gives OBV.

How it looks on a chart

Illustration only — synthetic data generated for visual reference.

Beginner

OBV keeps a running total of volume, adding it on days when price closes up and subtracting it on days when price closes down. The idea is that volume flows where the smart money goes. If a stock's price is going sideways but OBV is rising, it suggests that buyers are quietly accumulating shares — a bullish signal that often precedes a price rise. The absolute value of OBV is meaningless — it depends on where you start counting. What matters is the trend and direction of OBV relative to price. When OBV is making new highs alongside price, the trend has good volume confirmation. When price makes new highs but OBV does not, this divergence warns the rally lacks support. Granville's key insight was that volume precedes price. OBV divergences — where OBV moves in a different direction from price — were his primary trading signal. A rising OBV below a flat price, for example, often leads to an eventual price breakout to the upside.

Intermediate

OBV calculation: if Close > Prev Close, OBV = Prev OBV + Volume; if Close < Prev Close, OBV = Prev OBV − Volume; if Close = Prev Close, OBV = Prev OBV. A simple EMA or SMA overlay on OBV can serve as a signal line, similar to MACD — when OBV crosses above its moving average, it generates a buy signal. OBV divergence is the primary signal. Bullish divergence: price makes a lower low but OBV makes a higher low — selling pressure declining. Bearish divergence: price makes a higher high but OBV makes a lower high — buying pressure declining. These signals typically precede price reversals by 1–3 weeks on daily charts. One weakness of OBV is its binary volume assignment — all volume goes to either up or down regardless of whether the close was barely up or strongly up. The Chaikin Money Flow and Accumulation/Distribution indicators address this by using the position of the close within the high-low range to prorate the volume, giving a more nuanced picture of buying versus selling pressure.

Advanced

OBV is a non-stationary time series that grows indefinitely, which creates challenges for statistical analysis. Practitioners often normalize OBV by a rolling z-score or compare it to its own moving average to make it stationary. Some researchers use the rate of change of OBV (OBV momentum) rather than the level, which addresses non-stationarity. Empirical research on OBV's predictive power is mixed. Blume, Easley, and O'Hara (1994) and Gervais, Kaniel, and Mingelgrin (2001) find volume-based signals have predictive power on short horizons, particularly for less liquid securities. However, the binary assignment in OBV is cruder than microstructure-based order flow metrics and likely misses important intraday volume patterns. In systematic strategies, OBV is most effectively used as a divergence filter rather than a standalone entry signal: only take trend-following entries when OBV is confirming the price trend (both making new highs/lows). This confirmation filter reduces the number of trades but improves the win rate by eliminating entries with poor volume support.

Formula

OBV(t) = OBV(t−1) + Volume(t) if Close(t) > Close(t−1)
OBV(t) = OBV(t−1) − Volume(t) if Close(t) < Close(t−1)
OBV(t) = OBV(t−1) if Close(t) = Close(t−1)
  1. 1.Start with an initial OBV value of 0 (or any arbitrary starting point).
  2. 2.Each period: if today's close > yesterday's close, add today's volume to OBV.
  3. 3.If today's close < yesterday's close, subtract today's volume from OBV.
  4. 4.If today's close = yesterday's close, OBV remains unchanged.
  5. 5.Plot OBV as a line; compare its trend direction to price to identify divergences.

Parameters

ParameterDefaultRangeDescription
Signal Period20550EMA period for the OBV signal line (optional overlay).

Trading signals

bullish: OBV making new highs alongside price new highs

Volume confirming price advance — trend has strong institutional backing.

bullish: OBV rising while price is flat or declining (bullish divergence)

Accumulation phase — smart money buying despite flat price, breakout likely.

bearish: OBV falling while price is flat or rising (bearish divergence)

Distribution phase — smart money selling into price strength, top may be near.

bullish: OBV breaks above a resistance level before price does

Volume leading price — early signal of impending price breakout.

Limitations

  • Binary volume assignment (all or nothing based on close direction) is crude and misses intraday dynamics.
  • Non-stationary series — absolute OBV values are meaningless; only relative changes matter.
  • Does not account for where the close fell within the day's range.
  • Heavy reliance on volume data accuracy — unreliable for assets with inconsistent volume reporting.
How Gilito AI uses OBV

Gilito uses OBV primarily as a divergence confirmation filter in trend-following strategies, requiring OBV to confirm price breakouts before activating entry signals. OBV momentum (rate of change of OBV) is also computed as a volume-based feature in its machine learning strategy selection models.

Related indicators