MOMENTUM & OSCILLATORS

CCI

How far today's price sits from its normal range, on a scale where roughly ±100 marks the edges of ordinary.

spec id: ccilength (default 20)

What does CCI measure?

How far today's price sits from its normal range, on a scale where roughly ±100 marks the edges of ordinary. Beyond that, the move is unusual for this stock.

How is CCI calculated?

Take each candle's typical price (high, low and close averaged). Compare today's to its 20-candle average, then divide by how far prices usually stray from that average over the same window, scaled so ordinary moves land inside ±100.

Written by reading the engine’s real computation, not a textbook — where the two differ, the page describes what actually runs.

How do I use CCI in a bot?

In the builder, add an indicator of type cci (parameters: length, default 20). Its value becomes an operand you can compare in any entry or exit rule. The engine grades the whole rule honestly: real fills, no look-ahead, half the history held back.

Related indicators

Or browse all 158 indicators in the full library.

Build a bot that trades on CCI — the first backtest is free.

Run a free backtest