Bollinger Bands: calculation and how to use them
Bollinger Bands draw two bands around a moving average that widen and narrow with volatility. John Bollinger developed them in the 1980s; they show both how high or low price is relative to its recent past and how volatile the market is.
How are Bollinger Bands calculated?
- Middle band: the simple moving average of the last 20 closes.
- Upper band: middle band + 2 × standard deviation.
- Lower band: middle band − 2 × standard deviation.
The standard deviation measures how far the last 20 closes have strayed from the average. When price is calm it shrinks and the bands narrow; when price moves sharply it grows and the bands widen.
Example: with a middle band of 100 and a standard deviation of 4, the upper band = 100 + 2 × 4 = 108 and the lower band = 100 − 2 × 4 = 92. Assuming a normal distribution, most closes are expected to stay between the two bands.
How to read Bollinger Bands
- Touching the bands: price touching the upper band is not a sell signal on its own, nor is touching the lower band a buy signal. It means price is high or low relative to its recent past.
- Walking the band: in a strong trend, price can move along the upper (or lower) band for days. That is a sign of trend strength.
- The squeeze: bands staying narrow for a long time show falling volatility. A sharp move often follows; the breakout after the squeeze sets its direction.
- Return to the middle: in sideways markets, price tends to turn from the edges of the bands back toward the middle band.
%B and bandwidth
- %B: where price sits within the bands:
%B = (price − lower band) / (upper band − lower band). In the example, with price at 106, %B = (106 − 92) / (108 − 92) = 0.875, so price is in the upper part of the band. Above 1 is outside the upper band, below 0 outside the lower band. - Bandwidth:
(upper band − lower band) / middle band. In the example, (108 − 92) / 100 = 16%. This value falling to the lowest levels in the stock's own history signals a squeeze.
Settings and limitations
20 periods and 2 standard deviations is the most common setting. For shorter periods a slightly lower multiplier is suggested (for example 10 periods, 1.5), and for longer periods a slightly higher one (for example 50 periods, 2.5). Bollinger Bands don't predict direction; they only show relative price level and volatility. Use them with direction indicators such as MACD, the RSI or moving averages.
Bollinger Bands in Gonofin
- Bollinger Bands are drawn over price on the technical chart; the default setting is 20 periods, 2 standard deviations, and both can be changed.
- You can set alerts on the bands, for example “price crosses above the upper band” or “price crosses below the lower band”. See price and indicator alerts.
This guide is for information only and is not investment advice. No indicator guarantees future price movements.
Last updated: