# Video Codec

> A way to shrink video so it can be sent. It opens it up again to play.

**Field:** Design  
**Category:** Motion & Video  
**Also known as:** Codec, Video Compression Format, Video Encoder

## Think of it like

It is like folding clothes to fit a suitcase. You pack them small, then unfold them at the other end.

## Definition

A video codec is a method for shrinking video and playing it back. Raw video is huge, so the codec throws away detail the eye will not miss. It also stores only what changes from frame to frame. To play the file, the same codec unpacks it. Common codecs are H.264, H.265 and AV1. The file type, like MP4, is only the box the video sits in.

## Example

YouTube suggests H.264 in an MP4 file. Packed this way, a 10-minute HD clip fits in about 600 megabytes.

## Why it matters

The codec decides the file size, the quality and which devices can play it. The wrong one can make a file fail to open.

## Common mistake

Mixing up the codec with the file type. One MP4 file can hold different codecs inside.

## Three principles

- **Shrinks video.** Drops detail the eye misses.
- **Codec in a box.** MP4 is the box, not the codec.
- **Both ends.** Packing and playing need the same codec.

## Related terms

- [Bitrate](https://learn.benibix.com/term/design/bitrate)
- [Video Resolution](https://learn.benibix.com/term/design/video-resolution)
- [Image Compression](https://learn.benibix.com/term/design/image-compression)
- [Frame Rate](https://learn.benibix.com/term/design/frame-rate)
- [Video Editing](https://learn.benibix.com/term/design/video-editing)
- [Video Export](https://learn.benibix.com/term/design/video-export)
- [Video Container Format](https://learn.benibix.com/term/design/video-container-format)

## Told apart from

- [Video Container vs Video Codec](https://learn.benibix.com/compare/video-container-format-vs-video-codec): People think MP4 is a codec, and it is not. The codec is how the picture is shrunk to a small size, like H.264 or AV1. The container is the box that holds that picture, the sound and the subtitles in one file, like MP4 or WebM. A video plays only when the device can open both the box and what is inside.

![On the left, three nested boxes for frame size: 1280 by 720, 1920 by 1080 and 3840 by 2160. On the right, a stack of raw frames goes through a funnel marked codec and comes out as one small file. Under it, two pipes, a thin one marked low bitrate with a blocky picture and a wide one marked high bitrate with a sharp picture.](https://learn.benibix.com/diagrams/des2-video-files.svg)

---

Source: https://learn.benibix.com/term/design/video-codec
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
