Anchored VWAP Indicator for NinjaTrader 8

Created 10 May 2025 · Updated 25 Dec 2025

The Anchored VWAP[Advanced] is a Premium NinjaTrader 8 indicator.

Prerequisites

To use this indicator you should have the following prerequisites available.


  • NinjaTrader 8, with any license type. Click here to download
  • Order Flow data is not required to use this indicator — you don't need a NinjaTrader Lifetime license.
  • An automated-trading.ch account with an active Premium Subscription

Description

The Anchored VWAP[Advanced] is a premium NinjaTrader 8 indicator which has the following features:

  • Display of VWAP in 2 modes:
    • Session Mode: Display VWAPs defined on a time interval for each trading session
    • Click & Drag Mode: This mode allows you to interactively create VWAPs on the chart using mouse clicks
  • Works seamlessly with or without OrderFlow data or Tick Replay
  • Works seamlessly on any timeframe, including Renko bars
  • Export of VWAP levels as Plots that can be used from the NinjaTrader Strategy Builder, AlgoStudio, or Bloodhound 3rd-party software

Examples

Here are a few examples of the indicator in action:

RTH Session VWAP

The most straightforward usage of the indicator is to draw the VWAP on the RTH (Regular Trading Hours) session times of a US futures instrument.

Of course you can change the session time interval to whatever suits the instrument. The time interval works seamlessly on time-based timeframes and on price-based timeframes such as Renko bars or Range bars. If you want to draw the VWAP indicator on two or more separate intervals for the same trading session, you can add as many instances of the indicator to the chart, each with its own session interval.

RTH Session VWAP
Click to enlarge
Click & Drag Mode

The Anchored VWAP indicator can be operated under the Click & Drag mode, which allows you to add VWAPs on the chart with mouse clicks. First you click on a start index, then drag the mouse to the target index, then click a second time to transform the selection into a VWAP.

Click & Drag Mode
Click to enlarge
Click & Drag to Anchor VWAPs from Price Swings

One of the usage cases of the indicator is to draw VWAPs from anchor price points such as price swings. In this case, the VWAP can be used as an alternative to moving averages, and signals can be generated where inverse VWAPs intersect.

Click & Drag to anchor VWAPs from price swings
Click to enlarge

Parameters

We always try to keep the parameters to a minimum.

License
License This is the license key you get when you create an account on automated-trading.ch. After creating an account, copy your license key from the billing page. You need to set this parameter only once per month — once the license key is validated, it will be remembered for the rest of the month.
VWAP
VWAP Mode This parameter allows you to switch between two modes:
  • Session Interval: Draws one VWAP per trading session according to the Session Interval parameter below
  • Click & Drag: Draws VWAPs interactively based on your click-and-drag mouse commands, letting you place VWAPs on the chart at custom start and end points
  • Click & Auto Extend: Draws a new VWAP at each click on the chart and extends it into the last bar of the chart
Time Zone This parameter sets the time zone used for the Session Interval parameter below. Since futures markets open and close based on US market time (EST — US Eastern, New York), this parameter allows you to specify the trade time interval in another time zone, such as your own machine's local time zone or Central European time.
  • EST: Uses the EST (Eastern Time) time zone for the Session Interval
  • CET: Uses the CET (Central European Time) time zone for the Session Interval
  • Local Time: Uses your local machine's time zone
Session Interval (hh:mm-hh:mm) This parameter sets the time interval that defines the trading session. For example, if you want to draw the VWAP on the RTH session, set this parameter to "09:30-16:15" while setting the time zone to EST.
Std Dev BandsSelects the number of standard deviation bands to display, from None to 3.
Std Dev 1 MultiplierSets the multiplier for the first standard deviation band.
Std Dev 2 MultiplierSets the multiplier for the second standard deviation band.
Std Dev 3 MultiplierSets the multiplier for the third standard deviation band.
DataSeries Source This parameter sets the source for the VWAP calculation. You can choose among the following options:
  • Open: Calculate VWAP based on bars' open prices
  • High: Calculate VWAP based on bars' high prices
  • Low: Calculate VWAP based on bars' low prices
  • Close: Calculate VWAP based on bars' close prices
  • (H + L) / 2: Calculate VWAP based on bars' high+low prices
  • (H + L + C) / 3: Calculate VWAP based on typical prices
  • (O + H + L + C) / 4: Calculate VWAP based on open+high+low+close prices
  • (H + L + C + C) / 4: Calculate VWAP based on high+low+close×2 prices
Rendering
Color for Above PriceDefines the color of the VWAP line when it is above the price.
Color for Below PriceDefines the color of the VWAP line when it is below the price.
Std Dev 1 Area ColorSets the fill color around the first standard deviation band's area.
Std Dev 1 Area OpacityDetermines the opacity of the first standard deviation band's area.
Std Dev 2 Area ColorSets the fill color around the second standard deviation band's area.
Std Dev 2 Area OpacityDetermines the opacity of the second standard deviation band's area.
Std Dev 3 Area ColorSets the fill color around the third standard deviation band's area.
Std Dev 3 Area OpacityDetermines the opacity of the third standard deviation band's area.

Interactive Commands on the Click & Drag Mode

Extend to Last Bar

The Extend to Last Bar command extends the clicked VWAP to the most recent bar on the chart. The VWAP stays active and will be extended to new bars as they're created, being recalculated at each new bar.

Extend to Last Bar command
Click to enlarge
Stop Extending & Remove VWAP

The Stop Extending command marks the clicked VWAP as inactive and stops extending it to new bars.

The Remove VWAP command removes the VWAP from the chart. This is required since the "Delete" keyboard button can't be used to remove it, so this menu entry was created for that purpose.

Stop Extending & Remove VWAP command
Click to enlarge
Toggle Enable/Disable Anchored VWAP

Manipulating VWAPs on the chart can interfere with trading, or lead to unwanted effects such as creating a click-and-drag VWAP when you only meant to scroll the chart or close a trade. For this, the indicator exposes a toolbar button that lets you toggle the VWAP mouse interactions on/off. When this button is lit green it is active; when it is grey it is deactivated.

Toggle Enable/Disable Anchored VWAP button
Click to enlarge
Change DataSource of Anchored VWAPs

On both Click & Drag and Click & Auto Extend VWAPs, the DataSource can be changed by right-clicking on the VWAP and selecting another DataSource from the available options. Once a selection is made, the VWAP updates instantaneously.

Change DataSource of Anchored VWAPs
Click to enlarge

Signals & Usage in Strategy Builder

The indicator exposes signals that can be used from the Strategy Builder and third-party software such as Bloodhound and AlgoStudio.

Signal plots exposed by the indicator
Click to enlarge

Those signal plots are transparent and are not drawn on the chart. To use them from the Strategy Builder you can select them and build logic based on their values.

Building logic on the signal plots in Strategy Builder
Click to enlarge

Download & Installation Instructions

License Requirements

At automated-trading.ch you can choose to either purchase a monthly subscription to use our premium products, or use our free products without subscribing.

In both cases, you need to create an account so you can get a License you can use for both premium and free products.

To obtain your license, simply sign up and then get your license on the billing page.

Important: This is a Premium product. It can be run in Backtest, Playback, and Optimization modes for free; an active Premium subscription is required to run it live.
Download
Sign in to download this file.
Latest Version v1.1.0.0 · Published 9 months ago
This file was downloaded 363 times. Last download was 1 day ago.

You can also download this strategy — and every other automated-trading.ch strategy or indicator — anytime from your centralized Downloads page.

Installation Steps
1
Import the downloaded .zip file into NinjaTrader using the Import NinjaScript menu item.
2
Open a new chart window.
3
Right-click on the chart and click on Indicators... to add the indicator to the chart.
4
Copy/paste your license key, found on the Billing page, into the license parameter.
5
This is a Premium product. It can be run in Backtest, Playback, and Optimization modes for free; an active Premium subscription is required to run it live.
6
After adding the indicator to the chart with a valid license, it will run on the historical data loaded on the chart.
7
After that, the indicator is added successfully and will continue to run on live market data.

Frequently Asked Questions

General

Yes — if you have an idea that you believe can improve this indicator, use the contact page to send us a message.

No, the source code of the indicator is protected for copyright reasons.

No, this indicator only does rendering and doesn't provide data that can be used from within a strategy — check out our other strategies for one based on this same concept.

Yes, you can use this indicator without TickReplay, but bear in mind that in this case the indicator will not detect events on historical candles — it will only start detecting them on real-time volume and price data.

Release Notes

  • Drawing of vwap pushed behind chart candlestick for better clarity; Added DataSource parameter (Open, close, High, Low, (H+L)/2, ...); Added new VWAP mode: Click & Auto Extend

  • Fix Bug: Import issue class conflict with Open Range Breakout strategy; Fix Bug: indicator hides Grid lines when added to chart

  • Fix Bug: Std Dev bands don't take the input parameters

  • Fix Bug: Std bottom Signals not having values; Fix Bug: Saving template file generates an error

  • Fix Bug related to Timezone

  • Fixed Importing Error

  • First Release of the indicator
discord
Join our Discord community
Questions, feedback, or just want to chat with other traders? Come say hi.
Join Discord
Quick Facts
Platform NinjaTrader 8
Category Indicator
Plan Required Premium
Latest Version v1.1.0.0
Last Updated 9 months ago
Downloads 363