Free tool by DCAST
Codec & Container Cheat Sheet
Quick reference: when to use which codec or container for streaming and video.
Video codecs
Scroll horizontally on small screens
| Codec | Compatibility | Best for | Relative size | License |
|---|---|---|---|---|
| H.264 / AVC | Universal | Compatibility, HD, live streaming, all devices | Baseline | Proprietary |
| HEVC / H.265 | Modern devices, Apple | 4K, HDR, smaller files at same quality | ~50% of H.264 | Proprietary |
| VP9 | Chrome, YouTube, many browsers | Web, royalty-free, good compression | ~35% smaller than H.264 | Royalty-free |
| AV1 | Newer browsers and devices | Future-proof, best compression, no royalties | ~45–55% smaller than H.264 | Royalty-free |
Audio codecs
- AAC — Standard for web and streaming. Use for HLS and most players.
- MP3 — Legacy. Prefer AAC for new content.
Containers & playlists
- m3u8 — HLS playlist (text). Points to segments. Segments can be TS or fMP4. Used for live and VOD HLS.
- fMP4 — Fragmented MP4. HLS segments are often fMP4. Good for seeking and modern players.
- TS — MPEG-TS. Classic HLS segment format. Still common.
About this codec and container reference
This cheat sheet summarizes when to use which video codec (H.264, HEVC, VP9, AV1), audio codec (AAC, MP3), and container or playlist format (m3u8, fMP4, TS) for streaming and video. For file size and encoding time estimates, use the bitrate calculator and duration calculator.
- Q:What is H.264?
- A:H.264 (AVC) is the most widely supported video codec. Use it for compatibility, HD, and live streaming. HEVC (H.265), VP9, and AV1 offer better compression but need newer devices or browsers.
- Q:What is m3u8?
- A:m3u8 is the file extension for HLS playlists. The playlist is a text file that lists segment URLs. Segments can be in TS or fMP4 format. Used for both live and VOD HLS streaming.