TL;DR
Bollinger Bands consist of a middle SMA with upper and lower bands set at 2 standard deviations. They expand during high volatility and contract during low volatility, helping traders identify squeezes, breakouts, and overbought/oversold conditions.
Bollinger Bands are a volatility indicator created by John Bollinger in the 1980s. The indicator consists of three lines plotted on a price chart: a middle band, which is typically a 20-period Simple Moving Average, and an upper and lower band set at a fixed number of standard deviations (usually 2) above and below the middle band. Because standard deviation measures how spread out prices are from their average, Bollinger Bands automatically widen when the market is volatile and narrow when the market is calm. Approximately 95% of price action falls within the 2-standard-deviation bands, making moves to or beyond the bands statistically significant events. Bollinger Bands are one of the most versatile indicators in technical analysis, used for trend identification, volatility assessment, mean reversion trading, and breakout detection.
The calculation of Bollinger Bands involves three components. The middle band is a Simple Moving Average (SMA) of the closing price over the lookback period, typically 20 periods. The upper band is calculated by adding a specified number of standard deviations (typically 2) to the middle band. The lower band is calculated by subtracting the same number of standard deviations from the middle band. Standard deviation is a statistical measure of how far individual prices deviate from the average price. When prices are clustered tightly around the average (low volatility), the standard deviation is small, and the bands are narrow. When prices are spread far from the average (high volatility), the standard deviation is large, and the bands are wide. This dynamic nature is what makes Bollinger Bands superior to fixed-width channels or envelopes.
Upper Band = SMA(20) + 2 x StdDev(20); Lower Band = SMA(20) - 2 x StdDev(20)SMA(20) — 20-period Simple Moving Average of closing prices
StdDev(20) — 20-period standard deviation of closing prices
2 — Standard deviation multiplier (default)
The Bollinger Band squeeze is one of the most valuable signals the indicator produces. A squeeze occurs when the bands narrow to unusually tight levels, indicating that volatility has compressed significantly. Low volatility periods are typically followed by high volatility periods, making the squeeze a powerful setup for anticipating breakout moves. The squeeze does not predict direction, only that a large move is likely coming. To measure the squeeze quantitatively, traders use Bollinger BandWidth, calculated as (Upper Band minus Lower Band) divided by the Middle Band. When BandWidth reaches its lowest level in 6 months or more, a significant breakout is likely imminent. Traders often combine the squeeze with other directional indicators such as momentum oscillators, volume analysis, or chart patterns to determine the likely breakout direction. Once the bands begin to expand from a squeeze, the first strong move usually sets the direction for the subsequent trend.
Pro Tip
The tighter and longer-lasting the squeeze, the more explosive the eventual breakout tends to be. Look for BandWidth at multi-month or multi-year lows for the most powerful setups. Combine with a momentum indicator like MACD to predict the breakout direction.
During strong trends, price frequently rides along the upper or lower Bollinger Band in a pattern known as walking the band. In a strong uptrend, price will repeatedly touch or slightly exceed the upper band, pull back to the middle band (20 SMA), and then push back to the upper band. This is not an overbought condition; it is a sign of strength. Similarly, in a strong downtrend, price walks along the lower band with pullbacks to the middle band representing selling opportunities. A common mistake is treating touches of the upper band as sell signals or touches of the lower band as buy signals. In trending markets, these touches indicate momentum, not reversal. The middle band (20 SMA) acts as dynamic support in uptrends and dynamic resistance in downtrends during band walks. A close below the middle band during an uptrend walk often signals the trend is weakening.
John Bollinger developed two derived indicators that quantify Bollinger Band readings numerically, removing subjectivity from visual interpretation. BandWidth measures how wide the bands are relative to the middle band: BandWidth = (Upper Band - Lower Band) / Middle Band x 100. For example, if the upper band is at 5,100, the lower band at 4,900, and the middle band at 5,000, BandWidth = (5,100 - 4,900) / 5,000 x 100 = 4.0%. A BandWidth reading below 2% in the S&P 500 futures typically indicates an extreme squeeze, while readings above 8% indicate high volatility. The %B indicator measures where the current price sits within the bands: %B = (Price - Lower Band) / (Upper Band - Lower Band). At the lower band, %B = 0. At the upper band, %B = 1. At the middle band, %B = 0.5. Values above 1.0 mean price is above the upper band, and values below 0.0 mean price is below the lower band. These extreme readings are powerful signals when combined with context. In a range-bound market, %B above 1.0 is a strong overbought signal, while %B below 0.0 is a strong oversold signal. In a trending market, %B staying above 0.5 confirms a healthy uptrend, and below 0.5 confirms a healthy downtrend. Using BandWidth and %B together creates a systematic framework: when BandWidth hits its 6-month low (squeeze) and %B subsequently breaks above 0.5, the upside breakout is underway. When BandWidth is at its low and %B drops below 0.5, the downside breakout has begun.
BandWidth = (Upper - Lower) / Middle x 100; %B = (Price - Lower) / (Upper - Lower)Upper — Upper Bollinger Band value
Lower — Lower Bollinger Band value
Middle — Middle band (20-period SMA)
Price — Current closing price
Detecting and trading the Bollinger Band squeeze requires a systematic method to avoid false signals. The most reliable approach uses BandWidth history to define what constitutes a squeeze for your specific market. Calculate the lowest BandWidth reading over the past 126 bars (approximately 6 months on a daily chart). When the current BandWidth drops below this 126-period low, a squeeze is in effect. Historically, squeezes on daily charts resolve within 5-15 bars, meaning a significant move typically begins within 1-3 weeks of the squeeze signal. To determine the breakout direction, apply two complementary filters. First, check the MACD histogram: if it is positive and rising during the squeeze, the breakout is more likely upward. If negative and falling, downward. Second, check whether price is above or below the 50-period SMA: above favors an upside breakout, below favors downside. A concrete example: ES futures consolidates in November with BandWidth dropping to 1.8%, the lowest in 7 months. The MACD histogram turns positive and price trades above the 50 SMA. Within 8 trading days, ES breaks above the upper band and rallies 150 points over the following three weeks. The entry is on the first daily close above the upper band after the squeeze, with a stop loss at the middle band (20 SMA). This systematic squeeze detection method removes the guesswork and provides clear, objective entry criteria. The key discipline is patience: do not anticipate the breakout direction during the squeeze. Wait for the first decisive move to tell you which way the market wants to go.
Pro Tip
In NinjaTrader, you can create a custom indicator that plots BandWidth as a separate panel below price. Add a horizontal line at the 126-bar BandWidth low. When the BandWidth line drops below this threshold, highlight the chart background to visually alert you that a squeeze is active. This makes squeeze detection automatic and impossible to miss.
In range-bound markets, Bollinger Bands excel as a mean reversion tool. When price touches the lower band and shows a bullish reversal candlestick pattern, it often signals a buying opportunity. When price touches the upper band and shows a bearish reversal pattern, it often signals a selling opportunity. The key is context: mean reversion works in range-bound markets, not trending ones. To determine whether to trade mean reversion (fading the bands) or trend continuation (walking the bands), assess whether the bands are flat and horizontal (range-bound) or angled in one direction (trending). Bollinger himself developed the %B indicator, which measures where the current price falls relative to the bands (0 at the lower band, 1 at the upper band, 0.5 at the middle). Values above 1 or below 0 indicate extreme moves outside the bands that often precede reversals in non-trending conditions.
| Market Condition | Band Shape | Strategy |
|---|---|---|
| Trending up | Angled upward, price walks upper band | Buy pullbacks to middle band |
| Trending down | Angled downward, price walks lower band | Sell rallies to middle band |
| Range-bound | Flat and horizontal | Buy at lower band, sell at upper band |
| Squeeze | Narrowing to tight levels | Prepare for breakout in either direction |
Mistake
Automatically selling when price touches the upper band
Correction
In strong uptrends, price walks along the upper band, and touching it is a sign of strength, not a sell signal. Only fade the bands in clearly range-bound markets where bands are flat and horizontal.
Mistake
Trading the squeeze without a directional confirmation
Correction
The squeeze only tells you that a big move is coming, not which direction. Always combine squeeze setups with a momentum indicator (MACD, RSI) or chart pattern to determine the likely breakout direction.