Bollinger Bands
Two lines drawn 2 standard deviations above and below a 20-day average, so they widen when prices swing more.
4 min readLesson 43 of 57
In short
A close near the upper band is high compared with the last month's range, and one near the lower band is low. Narrow bands mean a calm stretch, which often comes before a bigger move, in either direction.
Why it matters
Is a $5 move big? For a calm stock it might be the biggest move in months; for a volatile one it's an ordinary Tuesday. Fixed rules like "sell after a 5% rise" ignore that. Bollinger Bands measure moves against the stock's own recent swings, so the same rule adjusts to each stock and each period.
John Bollinger introduced them in the 1980s, and they're now standard on charting sites. They're used in two opposite ways: some traders buy when the price touches the lower band, expecting a bounce, and others buy when it breaks above the upper band, expecting a trend. Knowing what the bands measure helps you see why both can fail.
How it works
Start with the 20-day simple moving average of the close: that's the middle band. Then work out the standard deviation of the same 20 closes, a measure of how far they spread around the average. The upper band is the average plus 2 standard deviations; the lower band is the average minus 2.
When prices swing a lot, the standard deviation grows and the bands widen. In a calm stretch they squeeze together. A narrow squeeze is often watched as a sign that a bigger move is coming, though it doesn't say which way.
%B says where the latest close sits between the bands: 0 is on the lower band, 1 on the upper band and 0.5 at the middle. It can go below 0 or above 1 when the price closes outside the bands. MarketLab uses the population standard deviation of the 20-day window, dividing by 20 rather than 19, as John Bollinger does. Some tools divide by 19, which makes the bands slightly wider.
If prices followed a bell curve, about 95% of closes would land inside 2 standard deviations. Real prices trend and have fat tails, so closes outside the bands are more common than that, and a close outside them isn't rare or automatically extreme.
Bands = 20-day average ± 2 × standard deviation of the 20 closes; %B = (close − lower) ÷ (upper − lower)
A channel around the recent average, as wide as the recent swings, and where today's close sits in it.
A worked example
To keep the arithmetic short, use a 5-day window instead of 20. A stock closed at $97, $101, $99, $100 and $103. Work out the bands and %B.
- Middle band: (97 + 101 + 99 + 100 + 103) ÷ 5 = 500 ÷ 5 = $100.
- Distances from the average: −3, +1, −1, 0 and +3. Their squares: 9, 1, 1, 0 and 9, which add up to 20.
- Population standard deviation: √(20 ÷ 5) = √4 = $2.
- Upper band: $100 + 2 × $2 = $104. Lower band: $100 − 2 × $2 = $96.
- %B for the last close: ($103 − $96) ÷ ($104 − $96) = 7 ÷ 8 = 0.875.
Result: The bands run from $96 to $104, and the last close of $103 sits at a %B of 0.875, near the top of the recent range. That says the price is high compared with the last few days' swings, not that it's about to fall.
How to read it
- %B above 1
- The close is above the upper band: unusually high compared with the last 20 days. In a strong uptrend, the price can ride the upper band for weeks.
- %B around 0.5
- The close is near the 20-day average, in the middle of its recent range.
- %B below 0
- The close is below the lower band. Some read it as oversold, but in a sharp fall the price can keep hugging the lower band.
- Bands squeezing together
- Swings have been small lately. Calm stretches often end with a bigger move, in either direction.
In the real world
- Mean-reversion traders buy near the lower band and sell near the middle or upper band, betting that stretched prices snap back. It tends to work in sideways markets and fail badly in strong downtrends, where "cheap" keeps getting cheaper.
- Breakout traders do the opposite: a close above the upper band after a squeeze is read as the start of a trend. John Bollinger himself advised combining the bands with other indicators, such as RSI or volume, rather than trading touches alone.
- Options traders watch the width of the bands as a rough view of recent Volatility, since a wider channel means bigger recent swings.
Common mistakes
- Treating a touch of the upper band as a sell signal by itself. In strong trends, prices often stay near or above the upper band for a long time.
- Assuming 95% of closes stay inside the bands. That would only hold for a bell curve; real prices break out more often.
- Forgetting the bands lag. They're built from the last 20 closes, so after a sudden jump they take days to catch up.
- Mixing up the standard deviations. Bands built with the sample version (dividing by 19) come out slightly wider than with the population version (dividing by 20).
See it in MarketLab
Stock pages →
The Technicals card shows the lower and upper Bollinger Bands for the last 20 days and the latest %B.
Backtest: buy below the lower band →
Test a mean-reversion rule on Coca-Cola: buy when the price is below the lower Bollinger band, and sell once it's back above the 20-day average. Change the rules under Custom rules.
Test yourself
Optional: 4 quick questions on the words, using the idea, and how it plays out in real markets.
Loading your answers…