VALYNOXSTRATEGY RESEARCH TECHNOLOGY
AlphaPrimeAlphaPrime

Bollinger Bands: squeezes, reversion and riding the band

Bollinger Bands wrap a moving average in two envelopes that widen and narrow with the market, so a single glance tells you how far price has strayed from its average and whether volatility is contracting or breaking out. This page covers how futures traders read them and how a strategy generator can sort out which reading suits your contract.

FamilyVolatility
In AlphaPrimeBuilt-in generator familyEntry triggers and volatility switches
Where it plotsEnvelope on the price chartSame units as price; width follows the spread of closes

What it measures

Bollinger Bands start from a middle line that tracks the recent average price, then place an upper and a lower band around it. The distance between the middle line and each band is not fixed. It depends on how widely the recent closes have been scattered around that average. When closes are spread out, the envelope is wide; when they bunch together, it tightens. The indicator therefore answers two questions at once: how far is price from its average right now, and, given current conditions, is that distance unusual or ordinary?

The width comes from a statistical measure of dispersion, which is the key to the indicator's personality. A short run of closes moving steadily in one direction is enough to push the bands apart quickly, and a few quiet sessions pull them back in just as fast. Compared with the Keltner Channel, whose width is built from the average true range, Bollinger Bands expand and contract more abruptly and more visibly. Traders often describe them as breathing, and that rhythm is what makes them so recognisable on a chart.

Because the bands are derived from the distribution of closes, touching a band is not by itself a sign that the market is overbought or oversold. It only says that the latest move sits far out relative to the recent spread. Many traders treat the bands as a relative-position ruler: near the upper band means relatively high, near the lower band relatively low, and a return to the middle line means price has moved back into its normal zone.

Concept sketch (not real market data)

How it behaves in real markets

In range-bound conditions, price tends to oscillate between the two bands, and moves that reach an outer band often drift back toward the middle line. The width stays fairly even through these phases. This is the picture mean-reversion traders know best, and it is why the bands are a popular way to locate the edges of a range.

When a trend takes hold, the picture changes. Price can walk along the upper or lower band, tagging it bar after bar while the envelope opens up in the direction of the move. Treating every upper-band touch as a reason to sell during that kind of advance usually means being dragged along by the market. Experienced traders who see price hugging a band tend to switch to a trend-following reading instead.

The best-known behaviour is the squeeze. Volatility contracts for an extended stretch, the bands pinch close together, and a directional expansion often follows. The squeeze says nothing about which way the break will go; it only suggests that energy is building. The contraction-then-expansion cycle is especially easy to see on thin overnight sessions, ahead of major economic releases and around long holiday breaks.

Common ways to use it (concepts)

Mean reversion

Back inside after an outer close

Price closes beyond the lower band and then closes back inside the envelope, which is read as a sign that selling pressure has run out for now. The target is usually the middle line. Most common on range-bound contracts, often with RSI confirming that momentum is turning at the same time.

Volatility breakout

Expansion after a squeeze

Once the band width has narrowed to a relatively tight state, a push through either band is taken in the direction of the break. ADX is a common follow-up check to see whether trend strength is actually building or the move is fading straight back.

Trend riding

Holding while price hugs a band

While price keeps pressing against the upper band, only long trades are taken, and a pullback toward the middle line is treated as a place to re-enter or add. A close on the far side of the middle line signals that the trend is cooling and the position is closed.

Pairing it with other indicator families

Bollinger Bands already carry two kinds of information, position and volatility, so the natural complement is something that supplies direction. Letting the slope of a moving average decide whether you trade long or short, and then using the middle line or the lower band to time pullbacks, gives each rule its own job and keeps the two from pulling against each other.

Overlaying the Keltner Channel is a classic approach. When both Bollinger Bands slip inside the Keltner envelope, the dispersion of closes has become smaller than the average bar range, which marks an unusually quiet market. When the Bollinger Bands push back outside, many traders treat it as the squeeze releasing. The two look alike on a chart, and it is precisely because their widths come from different sources that stacking them adds information.

To translate the distance to an outer band into actual points, look at ATR, and let stops and targets scale with the current range. Oscillators that measure how far price has moved from its average, such as CCI, overlap heavily with the relative-position reading of the bands, so running both often states the same idea twice. That choice is better left to a backtest.

In AlphaPrime

Inside the AlphaPrime strategy generator, Bollinger Bands usually play one of two parts. They can act as a relative-position entry trigger, for example price closing back inside after an outer-band close. Or they can act as a volatility switch, allowing breakout rules to fire only while the envelope is widening out of a tight phase. The generator pairs both roles with conditions from trend, momentum, volume and session families.

Reversion rules and breakout rules built on the same bands often behave in opposite ways on the same contract: one holds up while the other falls apart. Every combination is backtested on the GPU and then tested on a stretch of data that was never used for selection. Rather than committing to one school in advance, you let that out-of-sample check reveal which character your market shows on the timeframe you trade.

Combinations that survive can be exported as strategy code for your trading platform. The band settings and the entry and exit logic travel together, so the envelope you see on your own chart is the same one the generator evaluated, ready for simulation and the final checks before going live.

FAQ

How do Bollinger Bands differ from the Keltner Channel?

Both are envelopes around a moving average. Bollinger width comes from the dispersion of closing prices, so it reacts quickly to a run of one-directional closes and shows squeezes and expansions clearly. The Keltner Channel takes its width from the average true range, which includes gaps and intrabar highs and lows, so its edges are smoother. Bollinger is better at catching shifts in volatility; Keltner works well as a steady price frame.

Should I sell when price touches the upper band?

Not necessarily. In a range the upper band is often a relative high, but in a trend price can ride that band for a long time. Decide which regime you are in first, for example by checking trend strength with ADX, and only then decide whether the band marks a reversal zone or evidence of continuation.

Can a Bollinger-based strategy run on my own trading platform?

Yes. Combinations that pass out-of-sample validation are exported as strategy code with the band settings and the trade logic included, so you can line up each signal on your platform chart and confirm it matches what the generator evaluated.