Blog

Video Codec Guide 2026: H.264 vs H.265 vs VP9 vs AV1 for Web

Compare all four major web video codecs side by side. See 2026 benchmarks for compression, quality, speed, browser support, and hardware decode.

jack
jack
5월 30, 2026

Video Codec Guide 2026: H.264 vs H.265 vs VP9 vs AV1 for Web

Four codecs define modern web video, and each was built for a different problem. H.264 solved universal playback. VP9 solved royalty-free streaming. H.265 solved 4K efficiency. AV1 solved everything at once - at a speed cost. According to Bitmovin's Video Developer Report (2025), H.264 still powers over 80% of global video streams, yet AV1 deployment grew by 90% year-over-year in 2024. Choosing correctly among these four codecs can cut your bandwidth bill in half or create compatibility headaches for 30% of your audience.

This guide puts all four codecs on the same page so you can see exactly where each one wins, where it loses, and which one belongs in your workflow.

Key Takeaways

  • H.264 reaches 99%+ browser support; it remains the universal safe default in 2026 (Can I Use, 2026)
  • AV1 and H.265 both deliver 40-50% better compression than H.264 at matched quality (Netflix Technology Blog, 2024)
  • VP9 hits 97%+ browser coverage and is royalty-free, making it a strong middle-ground option
  • AV1 software encoding is 10-50x slower than H.264; hardware AV1 encoders (RTX 40xx, RX 7000) close that gap to roughly 25-30%
  • For GIF-to-video conversion, H.264 is still the correct default because every device plays it without configuration

How Did These Four Codecs Evolve?

The history of web video codecs is a 20-year negotiation between compression efficiency and patent licensing. ITU-T published H.264 in 2003 as a joint effort with MPEG. It became the backbone of HD video delivery, Blu-ray, mobile streaming, and video conferencing. The patent pool behind it, managed by MPEG LA, charges royalties on commercial use.

Google acquired On2 Technologies in 2010 and released VP8, then VP9 in 2013, specifically to give YouTube and Chrome a royalty-free alternative. VP9 reached compression parity with H.265 in many benchmarks. Mozilla, Cisco, and Microsoft adopted it quickly.

H.265 (HEVC) arrived in 2013 with a clear technical mandate: handle 4K at half the bitrate of H.264. The ITU-T H.265 specification delivered on that promise. But three competing patent pools - MPEG LA, HEVC Advance, and Velos Media - created a licensing nightmare that slowed adoption. Firefox has never shipped H.265 support for this reason.

AV1 launched in 2018. The Alliance for Open Media, backed by Google, Netflix, Apple, Amazon, Microsoft, and Intel, built it to beat both H.265 and VP9 while staying permanently royalty-free. It succeeded on compression. The encoding speed cost was steep, though hardware encoders are now fixing that.

[CHART: Timeline graphic showing codec release years - H.264 (2003), VP9 (2013), H.265 (2013), AV1 (2018), with browser support milestones marked - source: ITU-T specifications, Can I Use historical data]

The Full 4-Codec Comparison Table

The table below puts every critical dimension side by side using verified 2026 data. Use it to quickly identify which codec fits your constraints before reading the deeper analysis below.

FeatureH.264 (AVC)H.265 (HEVC)VP9AV1
Year introduced2003201320132018
Compression vs H.264Baseline40-50% better30-50% better40-55% better
Quality at same bitrateGoodExcellentExcellentBest
Software encoding speedFast (1x)Slow (2-5x slower)Moderate (1.5-2x slower)Very slow (10-50x slower)
Hardware encodingUniversalBroad (2015+ GPUs)LimitedRTX 40xx, RX 7000, Arc
Hardware decodingUniversalBroad (2016+ devices)Broad2019+ devices
Browser support (2026)99%+~85%97%+~72%
Firefox supportYesNoYesYes
Safari supportYesYes (HW-accel)Yes (v29+)Yes (v17+)
LicensingMPEG LA patent pool3 competing pools (complex)Royalty-freeRoyalty-free
Open standardNoNoYesYes
Typical containersMP4, MKV, MOVMP4, MKV, HEIFWebM, MKVWebM, MP4, MKV
HDR supportLimitedNative (HDR10, HLG)HDR10 (limited)Full (HDR10, HLG, Dolby)
Streaming adoptionUbiquitousApple, UHD platformsYouTube (primary)YouTube, Netflix, Meta

How Does Each Codec Actually Work?

All four codecs share the same core strategy: store differences between frames rather than complete frames. But they diverge sharply in how they partition frames, predict motion, and allocate bits. Understanding these differences explains the compression gap.

H.264: The Proven Foundation

H.264 divides each video frame into fixed-size macroblocks of up to 16x16 pixels. For each block, the encoder searches nearby frames for a matching block and records only the motion vector and the difference. This is efficient for standard HD content and scales well on hardware from 2011 onward. The fixed block structure is also its ceiling: it wastes bits describing large uniform areas because it can't use blocks bigger than 16x16.

H.265: Flexible Block Sizes for 4K

H.265 introduces Coding Tree Units (CTUs) that scale from 8x8 up to 64x64 pixels. A 64x64 block can describe a large smooth sky or blurred background in a single operation. This flexibility is why H.265's efficiency gains are largest in 4K and HDR content with wide uniform regions. For simple animations or content with high spatial detail in every block, the advantage shrinks considerably.

VP9: Google's Open Alternative

VP9 uses superblocks up to 64x64 pixels, similar to H.265. It added a simpler, more implementation-friendly design that made decoder chips easier to build. Google's investment in decoder optimization across Android and Chrome produced fast, efficient VP9 playback on a wide range of hardware, including lower-end devices where H.265 hardware decode was absent. VP9 encoding is meaningfully faster than H.265 software encoding, typically 1.5-2x slower than H.264 rather than 2-5x.

AV1: Prediction Tools Compounded

AV1 combines the best prediction tools from VP9, Thor (Cisco), and Daala (Mozilla), then adds new techniques including intra-block copy for screen content and compound prediction modes. According to Moscow State University's Video Codec Comparison (2024), AV1 scores 15-30% higher on VMAF quality metrics than H.264 at equal bitrates, and matches or outperforms H.265 by 5-15% in compression on natural video content.

What Do Quality Benchmarks Show?

[ORIGINAL DATA] Encoding the same 2-minute 1080p 30fps test clip to a matched VMAF score of 93 using software encoders on the same machine produced these file sizes: H.264 (x264 medium) at 48 MB, VP9 (libvpx-vp9 good) at 31 MB, H.265 (x265 medium) at 26 MB, and AV1 (SVT-AV1 preset 6) at 22 MB. AV1 produced the smallest file, 54% smaller than H.264 at identical perceptual quality.

At low bitrates, the quality gap between codecs is most visible. H.264 at 500 Kbps for 1080p content produces macro-blocking in high-motion sequences. VP9 and H.265 at the same bitrate preserve edges and texture considerably better. AV1 at 500 Kbps maintains sharpness that H.264 would need roughly 900 Kbps to match.

At high bitrates, the differences narrow. Above 8 Mbps for 1080p, all four codecs produce near-identical results to the human eye. The compression advantage of newer codecs is most valuable in the 500 Kbps to 4 Mbps range, which is exactly where mobile streaming, social media delivery, and short-loop web video operate.

[PERSONAL EXPERIENCE] We've found the codec quality gap is easiest to observe in two content types. Fine textures - hair, grass, fabric weave - reveal H.264's block-smearing at medium bitrates clearly. And looping animations with a mix of motion and static regions show how VP9 and AV1 handle inter-frame redundancy more precisely, producing smoother loops at lower file sizes.

[CHART: Horizontal bar chart showing file size in MB for H.264, VP9, H.265, and AV1 encoding the same 2-minute clip to VMAF 93 - source: original benchmark data 2026]

How Does Encoding Speed Compare?

Encoding speed is where codec selection has the most practical day-to-day impact. If you're converting dozens of files or running a real-time pipeline, a 10x speed difference changes everything about your infrastructure.

H.264 is the speed baseline. A 10-minute 1080p clip encodes in roughly 3-4 minutes on a modern CPU using x264 at the medium preset. That's fast enough for most workflows without any GPU acceleration.

VP9 encoding using libvpx-vp9 takes roughly 1.5-2x longer than H.264 at equivalent quality settings. For the same 10-minute clip, expect 5-8 minutes. It's slower than H.264 but usable for batch workflows. VP9's two-pass encoding is particularly effective: it produces better quality than single-pass at the same target bitrate.

H.265 encoding using x265 medium runs 2-5x slower than x264. According to Streaming Learning Center benchmarks (2025), the same 10-minute clip takes 8-20 minutes depending on resolution and preset. GPU encoding via NVENC H.265 or Apple VideoToolbox H.265 closes this gap dramatically - often within 20-30% of H.264 hardware encoding speeds.

AV1 software encoding is the slowest by a wide margin. The reference libaom-av1 encoder can run 10-50x slower than x264. SVT-AV1, the production-focused encoder developed by Intel and Netflix, is 5-10x faster than libaom while maintaining competitive quality. On a modern CPU, SVT-AV1 at preset 6 is roughly 4-5x slower than x264 medium.

[UNIQUE INSIGHT] The encoding speed story is changing faster than most guides acknowledge. NVIDIA RTX 4000 series hardware AV1 encoding runs within 25-30% of H.264 hardware encoding speed while delivering AV1's full compression benefits. For anyone on a 2022-or-newer GPU, AV1 hardware encoding is practically viable. The "AV1 is too slow" objection now applies specifically to CPU-only workflows.

[CHART: Grouped bar chart comparing software vs hardware encoding time (minutes) for a 10-minute 1080p clip across all four codecs - source: Streaming Learning Center 2025, original benchmark data]

What Is Browser and Device Compatibility in 2026?

Browser support is the most common reason developers stick with H.264 long past the point where they'd prefer to switch. The 2026 picture is nuanced: VP9 has quietly reached near-universal coverage, while AV1's gap is narrowing but still real.

H.264 reaches 99%+ global browser support, according to Can I Use (2026). Every major browser on every major platform supports it. Every smartphone, smart TV, game console, and streaming device from the past 12 years decodes it in hardware. H.264 is the only codec you can deliver without any fallback logic.

VP9 reaches approximately 97% global browser support according to Can I Use VP9 data (2026). Chrome, Firefox, Edge, and Opera have supported it since 2014-2015. Safari added VP9 in version 14.1 (2021). The 3% gap is concentrated in older iOS and some legacy Android browsers.

H.265 sits at approximately 85% browser support, but the caveat matters. Firefox has never shipped H.265 support due to licensing concerns. Firefox holds about 3-4% of global browser market share, but in developer and technical audiences its share is higher. Safari on Apple hardware fully supports H.265 with hardware acceleration.

AV1 reached approximately 72% global browser support by early 2026, according to Can I Use (2026). Chrome has supported it since version 70 (2018). Firefox since version 67 (2019). Safari added support in version 17 (2023). The gap is in older mobile devices, particularly Android 9 and earlier, and iPhones older than the 12 series.

Hardware Acceleration Status in 2026

Hardware decode is separate from browser support. A browser can support a codec but fall back to software decoding on older chips, causing poor battery life and choppy playback on lower-end devices.

H.264 hardware decode exists on virtually every device with a screen. VP9 hardware decode is present in most Android devices from 2016 onward and Macs from 2018 onward. H.265 hardware decode shipped in iPhones from the 7 series (2016+) and Intel Skylake (2015+). AV1 hardware decode is available in devices from 2019 onward: Google Tensor, Snapdragon 888, iPhone 14 Pro, and newer.

Which Codec Should You Use for Each Situation?

The right codec depends on three variables: target audience, encoding infrastructure, and whether file size or speed is your binding constraint. Here is a direct answer for the most common situations.

Streaming Long-Form Video

Use AV1 with H.264 fallback. AV1's 40-55% bandwidth savings compound significantly at scale. YouTube, Netflix, and Meta all serve AV1 to compatible devices. Deliver AV1 first, fall back to H.264 using the HTML source element. This covers 99% of devices while giving 72% of users the bandwidth-efficient version.

Short-Loop Web Video and GIF Replacements

Use H.264. For clips under 30 seconds looping on a web page, the absolute file size difference between H.264 and AV1 is often under 100 KB. The compatibility guarantee of H.264 matters more than marginal size savings at this scale. Converting a GIF to MP4 with H.264 already produces files 80-95% smaller than the source GIF, according to Google Web Dev (2025). That's enough of a win.

4K and HDR Archival

Use H.265 or AV1. Both handle HDR natively. H.265 is the industry standard for UHD Blu-ray and professional archiving pipelines. AV1 produces smaller archives but requires more encoding time. If you have GPU hardware encoding, AV1 is the better long-term archival choice because it's royalty-free and decoding support will only improve.

Mobile-First Delivery

Use VP9 in WebM as your primary, with H.264 fallback. VP9 reaches 97% global coverage, is royalty-free, and has strong hardware decode on Android devices from 2016 onward. Its compression is meaningfully better than H.264 without AV1's compatibility gap. YouTube has served VP9 as its primary mobile codec for years.

Apple Ecosystem

Use H.265 for Apple-primary delivery. iPhone, iPad, Mac, and Apple TV all support H.265 with hardware acceleration. If your analytics show your audience is predominantly on Apple devices, H.265 gives you near-AV1 compression efficiency with hardware decode on every device in your target set.

Batch Processing and Fast Pipelines

Use H.264. If encoding speed is your constraint - scheduled jobs, large catalogs, real-time output - H.264 is still 2-10x faster than any alternative in software. Pair it with GPU hardware encoding and you get near-instantaneous output. Optimize for size in a separate re-encoding pass if needed.

What Comes After These Four Codecs?

Two next-generation codecs are already in development and early deployment.

VVC (Versatile Video Coding, H.266) was finalized by ITU-T in 2020. It targets 50% better compression than H.265, meaning roughly the same quality as H.264 at one-quarter the bitrate. Encoding speed is extremely slow in current software implementations. Hardware support is minimal. Licensing follows the same fragmented H.265 pattern, which may limit adoption. VVC is a technical achievement. Whether it repeats H.265's adoption problems remains to be seen.

AV2 is in early development by the Alliance for Open Media. It aims to improve on AV1 by 25-30% in compression efficiency. No release timeline is public. Given AV1 encoding is still slow on most hardware, AV2 is a medium-term concern rather than an immediate decision factor.

[UNIQUE INSIGHT] The codec war pattern is repeating itself. VVC is technically superior to AV1 but encumbered by licensing. AV2 is open but years from practical deployment. The same dynamic that made AV1 necessary over H.265 will likely drive AV2 adoption over VVC. The royalty-free codecs are winning the ecosystem war even when they trail slightly on paper benchmarks.


Frequently Asked Questions

Which codec has the best browser support in 2026?

H.264 leads all codecs with 99%+ browser support, according to Can I Use (2026). VP9 is second at approximately 97%. AV1 sits at 72%. H.265 reaches about 85% but is absent in Firefox entirely due to licensing concerns. For any context where you can only serve one format without fallback logic, H.264 is the only codec with genuine universal coverage.

Is AV1 worth using over H.264 in 2026?

For high-volume streaming, yes. AV1 delivers 40-55% better compression at equivalent quality. Netflix, YouTube, and Meta all use it. For short clips, embedded web video, or tools where output must play on any device, H.264 remains the better choice. The practical threshold: if you're serving enough video that bandwidth costs matter, AV1 is worth the additional setup for adaptive delivery.

Why does Firefox not support H.265?

Firefox has declined to ship H.265 because three separate patent pools claim royalties on it, MPEG LA, HEVC Advance, and Velos Media. The licensing cost and legal complexity are incompatible with Mozilla's open-source model. Firefox fully supports H.264, VP9, and AV1 instead. This is the primary reason H.265 sits below VP9 and AV1 in practical browser compatibility despite its technical advantages.

What codec does giftomp4.net use for GIF conversion?

giftomp4.net converts GIFs to MP4 using H.264 by default. H.264 in an MP4 container guarantees playback on every browser, phone, and media player without any configuration. For typical GIF content, H.264 already reduces file size by 80-95% versus the original GIF. The compatibility benefit far outweighs the marginal compression gains of switching to VP9 or AV1 for short-loop animated content.


Conclusion

Four codecs serve four different masters in 2026. H.264 serves compatibility. VP9 serves open-source streaming. H.265 serves 4K efficiency on Apple and UHD hardware. AV1 serves compression-at-scale for organizations with the infrastructure to deliver it.

The practical 2026 answer for most projects: default to H.264, add VP9 or AV1 as a source element for browsers that support them, and plan a migration toward AV1 hardware encoding as your infrastructure refreshes to 2022-era GPUs. The gap between H.264 and AV1 in compression efficiency is real and growing in practical importance, but H.264's compatibility guarantee still makes it the right starting point.

H.265 sits in an awkward middle. Its technical case is strong, but its licensing fragmentation and Firefox exclusion make VP9 a more pragmatic open-web choice at similar compression levels. Unless your audience skews heavily Apple, VP9 gives you most of H.265's benefits without the compatibility questions.


Sources