# Volume-weighted MACD

Volume-weighted MACD is an indicator on [Vela](https://vela.luxalgo.com/chart), our next-generation charting platform, written in Pine Script®.

Rebuilds MACD on volume-weighted averages: a 12-period fast VWMA minus a 26-period slow VWMA with a 9-period signal line, so heavily traded bars drive the momentum read while quiet drift barely moves it. An optional classic price-only MACD overlay exposes where participation disagrees with price, alongside a histogram shaded by momentum expansion.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Apr 15, 2026.
- Access: free.
- Concepts: [Volume-weighted MACD](https://www.luxalgo.com/library/concept/volume-weighted-macd/) (primary)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=pss812jdtqpw783x5qot9ce5
- Page: https://www.luxalgo.com/library/indicator/volume-weighted-macd/

**Volume-weighted MACD** rebuilds the familiar momentum engine with participation deciding each bar's weight. Following the [Volume-weighted MACD](https://www.luxalgo.com/library/concept/volume-weighted-macd/) construction, it subtracts a 26-period slow VWMA from a 12-period fast VWMA, smoothing the spread with a 9-period signal line. Every close is multiplied by its volume before averaging, so busy bars drag the lines hard while thin drift barely registers. The optional price-only MACD overlay runs on the same source and lengths, making the disagreement between the two lines directly readable.

## How to Trade the Volume-weighted MACD?

- **Signal-line crosses**: volume-weighted momentum turning up or down, the standard crossover grammar with participation built in.
- **Zero-line crosses**: the fast VWMA moving above or below the slow, the regime boundary.
- **Histogram shading**: bright columns mark expanding momentum, faded columns a histogram already contracting toward its signal line.
- **VW-MACD versus the classic line**: the weighted line outrunning its price-only twin says volume sits behind the move; a weaker line warns participation is thinning as price advances.

Six alerts cover both signal crosses, both zero crosses, and both histogram turns. It sits naturally in the [momentum toolkit](https://www.luxalgo.com/library/family/momentum/) wherever the price-only version would.

## Volume-weighted MACD Settings

- **Source** (default close): the series fed into both volume-weighted averages.
- **Fast VWMA Length** (default 12) and **Slow VWMA Length** (default 26): the familiar spans carried over from the classic formulation.
- **Signal Smoothing** (default 9, EMA): signal-line length, with an SMA option for the smoothing type.
- **Classic MACD Comparison** (default enabled): overlays the price-only line for the participation read.
- Style toggles cover **Show Histogram** (default enabled), **Gradient Fill** (default enabled), and the directional colors.

## Frequently Asked Questions

### When does this diverge from the classic MACD?

The [MACD](https://www.luxalgo.com/library/indicator/macd/) weighs every bar equally, so the two agree whenever volume is uniform. They separate when volume concentrates on one side of the move: heavy trade behind a rally pulls the weighted line ahead, a thin climb leaves it trailing. That separation is the distinctive read.

### What happens on symbols without volume data?

When a window reports no volume at all, every bar carries equal weight and the average falls back to a simple mean, so the line stays defined instead of breaking.

### Should the signal line be an EMA or SMA?

The 9-period EMA is the most common choice and the default. An SMA weighs the window evenly, which slows the crossover slightly; it is a preference call, not a different indicator.

## Related indicators

- [Adaptive MACD](https://www.luxalgo.com/library/indicator/adaptive-macd/) (MACD): markdown at https://www.luxalgo.com/library/indicator/adaptive-macd.md
- [MACD Based Price Forecasting](https://www.luxalgo.com/library/indicator/macd-based-price-forecasting/) (MACD): markdown at https://www.luxalgo.com/library/indicator/macd-based-price-forecasting.md
- [Impulse MACD](https://www.luxalgo.com/library/indicator/impulse-macd/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/impulse-macd.md
- [MACD-V](https://www.luxalgo.com/library/indicator/macd-v/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/macd-v.md
- [Schaff Trend Cycle](https://www.luxalgo.com/library/indicator/schaff-trend-cycle/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/schaff-trend-cycle.md
- [Zero-lag MACD](https://www.luxalgo.com/library/indicator/zero-lag-macd/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/zero-lag-macd.md
- [MACD](https://www.luxalgo.com/library/indicator/macd/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/macd.md
- [OsMA](https://www.luxalgo.com/library/indicator/osma/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/osma.md

---

Source: https://www.luxalgo.com/library/indicator/volume-weighted-macd/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
