Updated August 11, 2026
Video formats & codecs reference
A video file is a container (the wrapper, e.g. MP4) holding streams encoded with a codec (e.g. H.264). This sheet separates the two so you can pick a target, then convert or compress locally.
Containers
The container is the file wrapper. The same codec can live in different containers.
| Container | Typical codecs | Best for |
|---|---|---|
MP4 | H.264, H.265, AAC | Universal sharing and playback; the safe default |
WebM | VP9, AV1, Opus | The web; royalty-free codecs, small files |
MOV | H.264, H.265, ProRes | Apple/QuickTime editing workflows |
MKV | Almost any | Flexible archiving; multiple tracks and subtitles |
Codecs
The codec decides how the video is compressed. Newer codecs are smaller at the same quality but need more compute and have patchier support.
| Codec | Efficiency | Support |
|---|---|---|
H.264 (AVC) | Baseline | Everywhere — browsers, phones, editors |
H.265 (HEVC) | ~50% smaller than H.264 | Good on Apple; patchy in browsers; licensing |
VP9 | Similar to H.265, royalty-free | Most browsers; common on the web (WebM) |
AV1 | Best; smaller than VP9/H.265 | Growing; slower to encode |
References
Questions
What is the difference between a container and a codec?
The container (MP4, WebM, MOV, MKV) is the file wrapper that holds the streams; the codec (H.264, H.265, VP9, AV1) is how the video itself is compressed. A file needs both.
Which video format is most compatible?
MP4 with the H.264 codec. It plays in virtually every browser, phone, and editor, which is why it is the safe default for sharing.
Is AV1 better than H.264?
For file size, yes — AV1 is much more efficient. But it is slower to encode and not supported everywhere yet, so H.264 remains the compatibility choice.