CABAC is the final compression step inside H.264, HEVC and several other codecs — the part that takes everything the encoder already figured out about a frame and squeezes it into the smallest possible sequence of bits before storage. The full name is Context-Adaptive Binary Arithmetic Coding, but the practical effect is what matters: CABAC alone makes H.264 files about 10–20 % smaller than the simpler entropy coder (cavlc) that early H.264 implementations used.

What makes CABAC clever is the "context-adaptive" part. Instead of assigning fixed bit lengths to symbols, it constantly updates its statistics based on what it's already seen in the current frame and adjusts the encoding on the fly. A symbol that's been common gets a very short code; a symbol that's been rare gets a longer one. The result is mathematically close to the theoretical minimum number of bits needed to encode the data (the entropy limit).

The catch is that CABAC is computationally heavier than its predecessor and is inherently serial — each symbol's decoding depends on the state left by the previous one, which makes parallelisation hard. That's why early H.264 hardware decoders sometimes only supported the simpler CAVLC mode, and why the Baseline profile of H.264 (used for video calls and low-power devices) doesn't include CABAC at all. For business-level decisions you rarely touch CABAC directly — it's just part of why "Main" and "High" profiles look the same as Baseline at noticeably lower bitrates.

Book cover: Video Encoding, Volume 1 of the Fora Soft Video Engineering Handbook

The book · Volume 1 of 7

Video Encoding: A Complete Guide to Video Compression — From Pixels and Color to H.264, HEVC, AV1, Quality Metrics, and AI

CABAC saves 10 to 20 percent over CAVLC in H.264 but costs decode time, which matters on low-end devices. The Video Encoding volume covers CABAC in depth: entropy coding, CAVLC versus CABAC, H.264 profiles and how HEVC builds on it. Written by Nikolay Sapunov, CEO at Fora Soft.

Read it on Amazon →Kindle & paperback · Fora Soft Video Engineering Handbook

Choosing CABAC or CAVLC profiles for low-power playback devices?

We will measure decode load and bitrate for each H.264 profile on your devices and give you a profile plan per device class. 250+ video products shipped since 2005.

Book a 30-min call →WhatsApp →Email us →