Bollinger Bands frame price with a volatility envelope around a 20-session average. Where the close sits within the bands and how wide they are describe recent behavior; a band touch or a squeeze does not predict the next move.
What Bollinger Bands are
Bollinger Bands, developed by John Bollinger in the 1980s, are three lines drawn over the price chart: a 20-session simple moving average in the middle, an upper band two standard deviations above it and a lower band two standard deviations below it. Because the distance to the bands is a standard deviation of recent closes, the bands widen when closes swing more and narrow when they settle.
| Property | Bollinger Bands |
|---|---|
| Middle band | 20-session simple moving average of the close |
| Upper band | Middle band + 2 standard deviations |
| Lower band | Middle band − 2 standard deviations |
| Standard deviation | Of the same 20 closes, in the population form |
| Companion measures | %B for the close’s position, BandWidth for the width |
| First value | After 20 closes |
The bands are a relative frame, not support, resistance or price targets. They show whether the latest close is high or low compared with the recent average, measured in units of recent volatility.
Bollinger Bands calculation
All three lines use the same 20 closes. The standard deviation measures how far those closes spread around their mean.
middle band = SMA(20) = (sum of the last 20 closes) ÷ 20
variance = (sum of (close − middle band)²) ÷ 20
SD = √variance
upper band = middle band + 2 × SD
lower band = middle band − 2 × SDSD- The population standard deviation of the same 20 closes.
2- The band multiplier. Twenty sessions and two standard deviations are Bollinger’s defaults.
Population or sample? Statistics distinguishes the population standard deviation, which divides by n, from the sample standard deviation, which divides by n − 1. Bollinger’s construction uses the population form, dividing by 20, and so does the Bollinger Bands overlay in TradeClever’s Stock Charts. Software that uses the sample form draws bands about 2.6% farther from the middle, because √(20 ÷ 19) = 1.026.
Edge case: if all 20 closes are identical, the standard deviation is 0 and both bands collapse onto the middle band. BandWidth is then 0, and %B, which divides by the distance between the bands, is undefined for that session.
A worked Bollinger Bands example
The example uses 22 hypothetical daily closes. The first table computes the bands for session 20 from sessions 1 to 20; the second shows how the bands respond to the next two sessions.
| Session | Close ($) | Close − mean ($) | Squared deviation |
|---|---|---|---|
| 1 | 40.10 | -0.25 | 0.0625 |
| 2 | 40.35 | 0.00 | 0.0000 |
| 3 | 39.90 | -0.45 | 0.2025 |
| 4 | 40.20 | -0.15 | 0.0225 |
| 5 | 40.55 | +0.20 | 0.0400 |
| 6 | 40.30 | -0.05 | 0.0025 |
| 7 | 39.95 | -0.40 | 0.1600 |
| 8 | 40.15 | -0.20 | 0.0400 |
| 9 | 40.45 | +0.10 | 0.0100 |
| 10 | 40.70 | +0.35 | 0.1225 |
| 11 | 40.40 | +0.05 | 0.0025 |
| 12 | 40.05 | -0.30 | 0.0900 |
| 13 | 40.25 | -0.10 | 0.0100 |
| 14 | 40.60 | +0.25 | 0.0625 |
| 15 | 40.35 | 0.00 | 0.0000 |
| 16 | 40.50 | +0.15 | 0.0225 |
| 17 | 40.20 | -0.15 | 0.0225 |
| 18 | 40.65 | +0.30 | 0.0900 |
| 19 | 40.80 | +0.45 | 0.2025 |
| 20 | 40.55 | +0.20 | 0.0400 |
middle band = 807.00 ÷ 20 = 40.35
variance = 1.2050 ÷ 20 = 0.06025
SD = √0.06025 = 0.2455
upper band = 40.35 + 2 × 0.2455 = 40.84
lower band = 40.35 − 2 × 0.2455 = 39.86
%B = (40.55 − 39.86) ÷ (40.84 − 39.86) = 0.70
BandWidth = (40.84 − 39.86) ÷ 40.35 × 100 = 2.43%| Session | Close ($) | Middle band ($) | SD ($) | Upper band ($) | Lower band ($) | %B | BandWidth (%) |
|---|---|---|---|---|---|---|---|
| 20 | 40.55 | 40.35 | 0.2455 | 40.84 | 39.86 | 0.70 | 2.43 |
| 21 | 41.70 | 40.43 | 0.3766 | 41.18 | 39.68 | 1.34 | 3.73 |
| 22 | 42.05 | 40.52 | 0.5153 | 41.55 | 39.48 | 1.24 | 5.09 |
Session 21 closes at 41.70, above the upper band of 41.18, so %B exceeds 1 (1.34). The jump also enters the standard deviation: BandWidth rises from 2.43% to 3.73% in one session and to 5.09% in the next. The bands react to the move that crossed them.
With the sample standard deviation, dividing by 19, the session 20 bands would be 40.85 and 39.85 instead of 40.84 and 39.86. Values are rounded for display; each step uses the unrounded figures.
Bollinger Bands %B explained
%B, which Bollinger introduced alongside the bands, turns the close’s position relative to the bands into a number: 1 at the upper band, 0.5 at the middle band and 0 at the lower band.
%B = (close − lower band) ÷ (upper band − lower band)| Close ($) | %B | Position |
|---|---|---|
| 41.00 | 1.16 | Above the upper band |
| 40.84 | 1.00 | At the upper band |
| 40.35 | 0.50 | At the middle band |
| 39.86 | 0.00 | At the lower band |
| 39.50 | -0.37 | Below the lower band |
%B above 1 or below 0 is not an error: it says the close is outside the bands. Because %B is normalized, it can be compared across stocks and used to look for divergence. A new price high with a lower %B means the close is less extended, relative to recent volatility, than it was at the prior high.
Bollinger Band width calculation
BandWidth measures the distance between the bands relative to the middle band, so it can be compared over time and across stocks.
BandWidth = (upper band − lower band) ÷ middle band
BandWidth (%) = BandWidth × 100With 2 standard deviations the bands are 4 SD apart, so BandWidth equals 4 × SD ÷ middle band: four times the coefficient of variation of the 20 closes. For session 20 of the example that is 4 × 0.2455 ÷ 40.35 × 100 = 2.43%.
Some platforms show BandWidth as a ratio, 0.0243, and others as a percentage, 2.43; the information is the same. The middle band of a stock price is always positive, so the division is always defined.
The Bollinger Band squeeze explained
A squeeze is a period when BandWidth falls to an unusually low level for that stock. Bollinger’s own benchmark is BandWidth at its lowest reading in about six months. It describes a quiet market in which closes cluster tightly around their average.
In the illustration on this page, BandWidth contracts from 15.35% to 1.67% while price moves sideways, then expands to 17.84% after price breaks upward.
Bollinger observed that periods of low volatility tend to give way to periods of higher volatility, which is why traders watch for squeezes. A squeeze does not say when the expansion comes or in which direction, and the first move out of a squeeze can reverse. Many readers wait for a close outside the bands and look at volume and the broader trend before drawing conclusions.
A squeeze is relative to the stock’s own history. A BandWidth of 3% can be a squeeze for one stock and an ordinary reading for another.
How to read Bollinger Bands on a stock chart
Read the bands in three steps: the middle band’s direction, the close’s position within the bands and the width of the bands.
- Direction. A rising middle band means the 20-session average is climbing; in an advance, pullbacks that hold near the middle band describe an orderly trend.
- Position. Closes near the upper band are high relative to recent volatility, and closes near the lower band are low; %B puts a number on it.
- Width. Widening bands mean rising volatility and narrowing bands falling volatility; BandWidth puts a number on it.
- Context. A touch of an outer band means different things in a range and in a trend. In a range, the outer bands often frame the swings; in a trend, repeated touches of one band are normal.
In TradeClever, open Stock Charts and add Bollinger Bands. The period and the number of standard deviations are configurable, with 20 and 2 as defaults. For the basics of candles and chart ranges, see reading a stock chart.
Stock price walking the upper Bollinger Band
In a strong advance, price can close at or near the upper band session after session, a behavior Bollinger calls walking the band. It happens because each high close lifts the average and widens the standard deviation, so the band climbs along with price.
In the illustration, %B stays at 0.90 or higher for 15 consecutive sessions after the squeeze breaks, while the close climbs from 38.22 to 42.75.
A close at the upper band is therefore not evidence that an advance is exhausted. A walk ends when closes stop reaching the band; many readers watch whether pullbacks hold above the middle band. The mirror image, walking down the lower band, occurs in strong declines.
Touching or closing above the upper band describes strength relative to recent volatility. On its own it is not a reason to expect a reversal.
Bollinger Bands versus Keltner Channels
Keltner Channels are another envelope around an average. In the form popularized by Linda Bradford Raschke, the center is an exponential moving average and the width is a multiple of average true range, commonly a 20-period EMA with bands 2 ATRs away. Chester Keltner’s original 1960 version used a moving average of the daily high–low range around an average of the typical price.
| Aspect | Bollinger Bands | Keltner Channels (ATR form) |
|---|---|---|
| Center line | 20-session SMA of the close | EMA, often 20 periods |
| Width set by | Standard deviation of closes | Average true range |
| Responds to | How far closes spread from their average | How large each session’s range is, gaps included |
| Reaction to one large close | Widens at once, then narrows when that close leaves the window | Widens gradually, following ATR’s smoothing |
Because the two envelopes measure volatility differently, some traders compare them. Bollinger Bands drawn inside Keltner Channels mark a period when closes are tightly clustered relative to typical ranges, one way of defining a squeeze. TradeClever’s charts draw Bollinger Bands; average true range explains the measure behind Keltner widths, and a moving average envelope uses a fixed percentage instead.
Limitations of Bollinger Bands
Bollinger Bands describe recent closes. Their limits come from the window, the settings and the statistics behind them.
- Two standard deviations is a scale, not a probability. Price data are not normally distributed, and the share of closes outside the bands varies by stock and period.
- They lag. Both the average and the standard deviation use the last 20 closes.
- One large move distorts them for 20 sessions and then drops out of the window at once.
- Settings matter. The defaults of 20 and 2 are conventions, not values tuned to any stock.
- A band is not a level. Touches happen in trends as well as at turning points.
- They see closes only. Intraday ranges and gaps enter only through the closes they leave behind.
Continue with
- Volatility stock screenerStock lists built on volatility measures.
- Consolidation and pullback stocksStock lists of quiet ranges and pullbacks.
- Breakouts and pullbacksHow price leaves and retests a range.
- Compare technical indicatorsHow common indicators differ.
Sources
- John Bollinger, Bollinger on Bollinger Bands (McGraw-Hill, 2001)
- John Bollinger, Bollinger Band Rules (checked October 1, 2026)
- Chester W. Keltner, How to Make Money in Commodities (1960)
Read our data and methodology notes for calculation context. This guide explains research tools and observations. It does not recommend a trade or investment.