The commodity channel index is one of those indicators people add to a chart, glance at once, and then misread for months. The name doesn’t help. It sounds like something only a crude oil trader would care about, yet you’ll find it sitting under plenty of Nifty stock charts on Indian trading platforms. What it actually measures is simple: how far today’s price has wandered from its recent average, scaled by how much prices normally wander. Once that clicks, the +100 and -100 lines stop looking like magic thresholds and start looking like what they are, a rough boundary for “unusual”.
This guide walks through the formula with a small worked example you can redo in a spreadsheet, then covers the three ways traders use CCI (trend signals, extremes and divergences) and the traps in each. All the stock prices below are hypothetical numbers we made up for illustration, not real quotes.
In this article
- Where the commodity channel index came from
- The CCI formula, piece by piece
- A worked example you can check by hand
- Reading +100 and -100 as trend filters
- Overbought and oversold: why ±100 isn’t enough
- Divergences, and the confirmation step people skip
- Choosing the lookback period
- What CCI won’t tell you
- A simple CCI checklist before you act
Where the commodity channel index came from
CCI was developed by Donald Lambert and featured in Commodities magazine in 1980, according to StockCharts ChartSchool. Lambert built it to spot cyclical turns in commodities. But nothing in the maths is specific to commodities, and ChartSchool notes it applies just as well to indices, ETFs and stocks. Investopedia makes the same point: despite the name, it can be used in any market.
So think of it as a momentum oscillator, in the same family as RSI and the stochastic oscillator, with one big difference we’ll come to shortly. It has no ceiling and no floor.
The CCI formula, piece by piece
There are four moving parts. For a lookback of P periods (20 is the common choice and the default on StockCharts):
- Typical price for each period = (High + Low + Close) ÷ 3.
- Moving average (MA) = the simple average of the last P typical prices.
- Mean deviation = the average of the absolute gaps between each of those P typical prices and the MA. You ignore minus signs.
- CCI = (Latest typical price − MA) ÷ (0.015 × Mean deviation).
The top half of that fraction tells you how far price is from its average. The bottom half tells you how far price usually strays. Divide one by the other and you get a reading that compares today’s stretch with the stock’s normal behaviour. A sleepy stock and a jumpy one get judged on their own terms.
And the odd-looking 0.015? Lambert picked that constant so that roughly 70 to 80 percent of CCI values would land between -100 and +100, as ChartSchool explains. That’s the whole reason ±100 matters. It isn’t a law of markets. It’s a scaling choice that makes readings beyond ±100 relatively uncommon.
A worked example you can check by hand
A 20-day example would mean typing out 20 rows, which is tedious to read. So we’ll use a five-day lookback on a made-up stock. The steps are identical for 20 days; only the row count changes.
| Day | High (₹) | Low (₹) | Close (₹) | Typical price (₹) |
|---|---|---|---|---|
| 1 | 812 | 798 | 806 | 805.33 |
| 2 | 815 | 801 | 812 | 809.33 |
| 3 | 820 | 808 | 817 | 815.00 |
| 4 | 826 | 812 | 823 | 820.33 |
| 5 | 842 | 824 | 840 | 835.33 |
Step 1, the average. Add the five typical prices and divide by five: 4,085.33 ÷ 5 = ₹817.06 (rounded).
Step 2, the mean deviation. Take each typical price’s distance from ₹817.06, ignoring the sign: 11.73, 7.73, 2.06, 3.27 and 18.27. Their average is 43.06 ÷ 5 = 8.61.
Step 3, the reading. Day 5’s typical price is ₹835.33. That’s 18.27 above the average. Divide by 0.015 × 8.61, which is about 0.129, and you get a CCI of roughly +141.
What does +141 tell us? Day 5 was a wide, strong session that closed near its high, and it pushed the typical price well beyond the stock’s usual daily wobble. On the textbook reading, that’s a move into “unusual strength” territory.
Here’s a quicker example with round numbers, the kind you might jot in a notebook. Say a 20-day CCI on another stock has an average typical price of ₹1,020 and a mean deviation of 16. If today’s typical price is ₹1,052, CCI = 32 ÷ (0.015 × 16) = 32 ÷ 0.24 = +133. If instead today’s typical price had been ₹1,004, CCI = -16 ÷ 0.24 = -67. Below average, but still inside the normal band.
CCI doesn’t ask whether a stock is “high”. It asks whether today’s distance from the average is large compared with how far this particular stock usually strays.
Reading +100 and -100 as trend filters
The most common use is as a trend trigger. Investopedia describes it this way: when CCI moves from negative or near-zero readings to above +100, price may be starting a new uptrend. When it drops from positive or near-zero readings below -100, a downtrend may be starting, which is a cue to exit longs or start looking at shorts.
Why not just use the zero line? CCI above zero means price is above its average, below zero means below. ChartSchool says simple zero-line crossovers produce many whipsaws. Demanding a push above +100 for a bullish signal, or below -100 for a bearish one, lags more but cuts down those false starts. You trade a later entry for fewer fake ones. Most of us would take that deal.
In practice, a swing trader might use the +100 cross not as a buy button but as a change of mood. Once CCI has crossed +100 on a daily chart, they only look for long setups: a pullback toward a moving average, a tight consolidation, a breakout from a small flag. Investopedia describes a similar idea, waiting for a pullback after the cross and then a fresh rally in both price and CCI before buying.
One caveat from ChartSchool that’s easy to forget: a 20-day CCI is a short-term tool. If you want long-term trend signals, they suggest weekly or monthly charts instead.
Overbought and oversold: why ±100 isn’t enough
This is where most beginners go wrong. RSI and the stochastic oscillator are bounded. The stochastic lives between 0 and 100, which Investopedia flags as one of the main differences from CCI. CCI is unbounded. In theory it can run to +400 and keep going.
That has two consequences.
- No universal overbought line. Investopedia’s suggestion is to look back at a stock’s own history and note where price actually reversed. One stock might tend to turn near +200 and -150; another market might turn near +325 and -350. Those are their illustrative numbers, and the point is that every chart has its own personality.
- ±100 is often too tight. ChartSchool says ±100 may work in a trading range, but more extreme levels are needed in other conditions. It treats ±200 as a much harder level to reach and more representative of a true extreme. It also notes that the CCI range for a broad index ETF is usually narrower than for most individual stocks, because volatility differs.
For an Indian trader, the practical version is this. A Nifty 50 index chart and a volatile smallcap chart shouldn’t share the same overbought line. Scroll back a year on each, mark the CCI readings at the obvious turning points, and set your levels from what you see.
Then there’s timing. ChartSchool suggests waiting for CCI to cross back inside the extreme level, say from above +200 to below it, before acting on an overbought reading. Fading a stock simply because CCI is at +250 means stepping in front of strong momentum, and strong momentum can stay strong. ChartSchool’s own example shows a stock that kept rising even after CCI became overbought and slipped back below 200. The rule helps. It doesn’t save you every time.
Divergences, and the confirmation step people skip
A bullish divergence is when price makes a lower low but CCI makes a higher low, so the selling is losing force. A bearish divergence is the mirror image: price makes a higher high while CCI makes a lower high.
Sounds great. The trouble is that strong trends throw off divergences constantly. ChartSchool warns that a strong uptrend can show numerous bearish divergences before an actual top, and extended downtrends are full of bullish ones. Investopedia goes further and calls divergence a poor trade signal on its own, because it can persist for a long time without a reversal, though it’s useful as a warning to tighten stops or hold off on new trades in the trend’s direction.
The fix is confirmation. ChartSchool’s approach: confirm a bearish divergence with a CCI break below zero or a support break on the price chart, and a bullish one with a CCI break above zero or a resistance break. So the divergence tells you to pay attention, and the zero-line cross or price break tells you something has actually changed.
Here’s a hypothetical sequence. A stock tops at ₹1,480 with CCI at +190. Three weeks later it makes a marginally higher high at ₹1,495, but CCI peaks at only +110. That’s a bearish divergence. A disciplined trader doesn’t short it there. They wait. If CCI then slips below zero and the stock breaks under the swing low between the two peaks, the divergence is confirmed. If neither happens, they’ve lost nothing by waiting.
A divergence is a question, not an answer. The zero-line cross or the support break is where the market replies.
Choosing the lookback period
The lookback changes the indicator’s character more than any other setting. ChartSchool spells out the trade-off: a 10-period CCI is more volatile, with a smaller share of values between ±100, while a 40-period CCI is smoother, with a larger share inside that band. Investopedia says the same in simpler terms. Fewer periods make it jumpier, more periods make it smoother.
A rough way to think about it:
- Short lookback (around 10). More signals, more noise. If you use it, widen your extreme levels, because ±100 will be crossed all the time.
- Standard lookback (20). The default most platforms ship with, and what the textbook levels were discussed around.
- Longer lookback (around 40). Fewer, slower signals. ChartSchool uses a 40-day CCI in one divergence example specifically to reduce volatility.
Whatever you pick, stick with it long enough to learn how it behaves on the stocks you trade. Switching settings every week because the last signal failed is how people end up with a chart full of curve-fitted nonsense.
What CCI won’t tell you
Let’s be blunt about the limits. Investopedia calls CCI’s overbought and oversold calls highly subjective, precisely because the indicator is unbounded and old extremes may not repeat. It’s also a lagging indicator. By the time CCI clears +100, a chunk of the move may already be done, and the stock might be about to correct. Those failed signals, where the indicator fires but price doesn’t follow through, are whipsaws, and they can come in clusters.
CCI also says nothing about volume, liquidity or news. A results-day gap will send it flying, and that reading tells you about the gap, not about whether the trend will continue.
The usual advice is to pair it with something that measures a different thing. ChartSchool points out that adding another momentum oscillator would be redundant and suggests volume-based tools such as On Balance Volume or the Accumulation Distribution Line instead. Price structure works too. Support, resistance and trend channels like the Keltner Channel give context that CCI can’t.
A simple CCI checklist before you act
If we had to boil this down to something you could tape next to the screen, it would look like this:
- Know your lookback. Twenty periods is standard; shorter means noisier.
- Use ±100 as a trend filter, not a reversal signal.
- Set overbought and oversold levels from the stock’s own history. Try ±200 as a starting point for “extreme”.
- Wait for CCI to come back inside an extreme before fading a move.
- Treat divergences as warnings until a zero-line cross or a price break confirms them.
- Check volume or price structure before committing money.
- Decide your stop-loss before entry, because whipsaws will happen.
CCI is a useful lens, and a cheap one, since it’s free on just about every charting platform. Used as one input among several, it can help you separate ordinary drift from genuine momentum. For a broader framework of how indicators, patterns and price levels fit together, see our guide to technical analysis for Indian stocks.
Disclaimer: This article is for educational purposes only and is not investment advice. The prices and indicator readings in the examples are hypothetical. Trading in stocks and derivatives involves risk of loss. Please do your own research or consult a SEBI-registered investment adviser before making any investment decision.

Leave a Reply
Join the conversation
Commenting is open to registered readers. Sign up with just your email — no password needed, and it takes under a minute.
Sign up to comment Log in