All indicators

VWAP From Pivots Lows and Highs

Dec 9, 2025

Static chart image
Dynamic OverlaysSupport and ResistanceVolume BasedPivot Based (Retrospective)

The VWAP From Pivots Lows and Highs indicator automatically calculates and plots Volume Weighted Average Price (VWAP) lines anchored to the most recent pivot high and low points. This tool allows traders to identify dynamic support and resistance levels based on significant structural turning points in price action.

Usage

The Usage section describes how the script can be used to track institutional value areas relative to recent market turns. By default, the tool tracks the three most recent pivot points, providing a layered view of volume-weighted support and resistance.

  • Identifying Support/Resistance: VWAP lines originating from pivot lows often act as support, while those from pivot highs act as resistance.
  • Trend Confirmation: When price remains above a pivot low VWAP, it suggests bullish momentum relative to that specific structural low.
  • Layered Analysis: By displaying up to three VWAPs for highs and lows simultaneously, users can see where multiple volume-weighted levels converge, indicating stronger potential areas of interest.

Details

The script utilizes the ta.pivothigh() and ta.pivotlow() functions to detect significant price peaks and troughs based on user-defined left and right bar requirements. Once a pivot is confirmed, the script initiates a cumulative calculation of price-volume (using the average price (H+L+C)/3) and total volume starting from the bar where the pivot occurred.

The indicator manages multiple VWAP instances dynamically. As new pivots are formed, older VWAP lines are replaced or updated in color to reflect their recency, ensuring the chart remains focused on relevant data.

Settings

Length Highs

  • Pivot High Left: The number of bars to the left of a potential pivot high required to confirm the peak.
  • Right: The number of bars to the right required to confirm the peak.

Length Lows

  • Pivot Low Left: The number of bars to the left of a potential pivot low required to confirm the trough.
  • Right: The number of bars to the right required to confirm the trough.

General Settings

  • Show all low pivots: Toggles the visibility of VWAP lines anchored to pivot lows.
  • Show all high pivots: Toggles the visibility of VWAP lines anchored to pivot highs.
  • Number of pivots: Determines how many historical pivots (up to 3) will have active VWAP lines drawn.

Colors

  • Color Pivot Lows (1-3): Sets the color for the 1st, 2nd, and 3rd most recent pivot low VWAPs.
  • Color Pivot Highs (1-3): Sets the color for the 1st, 2nd, and 3rd most recent pivot high VWAPs.

FAQ

How do I access VWAP From Pivots Lows and Highs?

You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.

Why do the lines start several bars back?

The VWAP lines are anchored to the actual pivot bar. Because pivots require a "Right Length" of bars to be confirmed, the line will appear to "backfill" once the pivot condition is met.

Can I change the sensitivity of the pivot detection?

Yes, by adjusting the "Left" and "Right" length settings in the inputs, you can make the indicator detect either minor local pivots or major macro structural turns.

Free indicator

Get free access to this indicator on the platforms below.

TradingView
NinjaTrader
MetaTrader 4/5

Unlock the entire LuxAlgo Library

Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.