Bollinger Bands MTF
Jan 17, 2019

The Bollinger Bands MTF indicator provides a multi-timeframe approach to volatility analysis by plotting Bollinger Bands from both the current and a user-defined higher timeframe simultaneously on a single chart. This allows traders to identify confluence between local price action and broader market trends within a unified visual framework.
Usage
The tool displays two sets of Bollinger Bands: the standard bands for the current chart timeframe and a second set representing a higher timeframe (HTF). This configuration is particularly useful for identifying key support and resistance zones that may not be visible on a single timeframe.
Traders can use this script to:
- Identify Confluence: Look for instances where price interacts with both the current and higher timeframe bands simultaneously.
- Trend Filtering: Use the HTF basis line (middle band) to determine the primary trend direction while using current timeframe bands for entries.
- Smoothing Transitions: The indicator includes an optional smoothing feature to reduce the "stair-step" effect common in MTF data, providing a more fluid visual representation of higher-period volatility.
Details
Bollinger Bands consist of an N-period moving average (basis), an upper band (basis + standard deviation), and a lower band (basis - standard deviation). This script utilizes the request.security function to fetch these calculations from a higher timeframe. To prevent repainting and ensure data integrity, it references historical data from the higher timeframe. The smoothing option applies a simple moving average (SMA) to the fetched HTF values, which can help in visualizing the trend more clearly on lower timeframe charts.
Settings
- Higher time frame: Determines the timeframe from which the secondary Bollinger Bands are calculated (e.g., 60 minutes, Daily, Weekly).
- Smoothing: A toggle to enable or disable an 8-period SMA smoothing on the HTF bands to create cleaner lines.
- Length: Sets the lookback period for the Bollinger Bands calculation (default is 20).
- Mult: Sets the standard deviation multiplier for the width of the bands (default is 2.0).
FAQ
How do I change the higher timeframe?
You can adjust the "Higher time frame" setting in the indicator inputs. While the script often defaults to common logical steps (like 1h for a 15m chart), you can manually select any timeframe supported by your platform.
Why do the higher timeframe bands look different than the current ones?
The MTF bands represent data from a broader perspective. Because they cover more price action per bar than the current timeframe, they appear wider and move more slowly, acting as a "macro" filter for the "micro" movements of the current chart.
How can I get access to this tool?
You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
Free indicator
Get free access to this indicator on the platforms below.
Unlock the entire LuxAlgo Library
Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.