Why live video is the hardest problem in streaming

Consumer expectations and consumer bandwidth are on a collision course. VR headsets render 22.1 million pixels per frame, 4K TVs and phones are now standard, and commuters expect uninterrupted streaming even in subway tunnels. Yet network infrastructure hasn't kept pace: mobile carriers cap streaming resolution, data plans are metered, and a significant portion of users still struggle with basic home connectivity.

Live video suffers most from this gap. A buffering pre-recorded stream merely delays playback; a buffering live stream desynchronizes the viewer from the event. For a sports fan, that means missing the game-winning play while the player stalls.

Cloudflare Stream is now addressing this with AV1 support for live streams and their recordings, available in open beta to all customers today. AV1 is an open, royalty-free codec that delivers approximately 46% less bandwidth consumption than H.264, the web's current standard.

What AV1 changes

Raw video is staggeringly large. A single 4K frame requires 24 megabytes of pixel data, and at 30 frames per second that becomes roughly 15 gigabytes per minute. Codecs compress that data to roughly one percent of its original size before transmission, with minimal perceptual loss. Each codec generation achieves better compression at the cost of greater computational complexity, which is why devices include specialized media decoding hardware rather than relying on the main CPU.

AV1 represents a significant leap in compression efficiency, even compared to recent codecs like VP9 and HEVC. The tradeoff is computational intensity: AV1 shifts work from the network to the decoding device. When the codec launched in 2018, skeptics dismissed it as impractical because hardware couldn't decode it efficiently. Four years of rapid silicon progress have changed that calculus.

Decode: the hardware race has already been won

Smartphone chip development has accelerated dramatically, driven largely by the competitive push for better on-device camera processing. That surplus of compute is now enabling AV1 adoption:

  • Google's Pixel Tensor chip includes hardware AV1 decoding.
  • Samsung's Exynos 2200 and MediaTek's Dimensity 1000 SoCs both support hardware-accelerated AV1 decoding.
  • Android 14 looks set to require AV1 decode support across all compatible devices.
  • Apple's AVPlayer framework now exposes AV1 as a video codec option, signaling iOS and tvOS readiness.

Hardware decoding is essential for battery life. A Pixel 6 decoding AV1 in hardware uses minimal CPU and power resources, a critical factor for both current smartphones and future VR headsets that will demand even more efficiency.

Encode: the computational bottleneck

Encoding AV1 is significantly harder than decoding it, and Cloudflare's testing demonstrates why. Using an AMD EPYC 7642 48-core processor with 256 GB RAM to encode two seconds of 4K video at 30 fps with libaom-av1 took over 30 minutes on a single core. Even parallelizing across all 48 cores would require more than 43 seconds per two seconds of footage — over 20 servers running at full capacity for real-time encoding.

Dedicated CPU-based encoders like rav1e and SVT-AV1 improve on that but still demand multiple servers for real-time output.

Cloudflare's advantage is end-to-end hardware and software control. The company has deployed dedicated AV1 hardware encoders designed specifically for fast encoding, enabling real-time AV1 compression for live streams. This is a capability that most public cloud customers cannot replicate, since they lack equivalent control over their infrastructure.

Real-time encoding matters because live streaming cannot rely on large client buffers. Pre-recorded content players can fetch segments well ahead of playback; live streams are constrained by latency and have far less room for error. Every byte saved shortens recovery time when a viewer's connection falters.

Breaking the adoption deadlock

AV1 has faced a chicken-and-egg problem: content providers hold back until devices support AV1, while device manufacturers wait for AV1 content. Re-encoding entire video libraries has been cost-prohibitive, forcing providers to guess which titles deserve the investment — a poor fit for user-generated content platforms where virality is unpredictable.

Cloudflare Stream eliminates the need for manual re-encoding or batch processing by integrating encoding and delivery into a single product. Uploaded videos are served with AV1 when appropriate, without developers triggering jobs or managing encoding pipelines. This on-demand approach is impossible with the traditional workflow of encoding first and pointing a CDN at pre-encoded files.

For a platform with millions of minutes of user-generated content where most videos are never watched again, that means no upfront encoding costs and no guesswork about which content will need AV1.

Why AV1: open, royalty-free, and future-proof

Competing codecs impose royalty fees on device manufacturers and have a history of litigation against rivals. The VP8 and VP9 codec group has opposed that model for over a decade, and AV1 is the successor to that lineage with backing from major software and hardware companies alike. Beyond its technical merits, AV1 represents an industry commitment to video encoding that is open, royalty-free, and shielded from patent disputes.

Try AV1 on your live stream today

AV1 support is in open beta. To test it, append the ?betaCodecSuggestion=av1 query parameter to the HLS or DASH manifest URL of any live stream or live recording created after October 1st in Cloudflare Stream. A sample AV1-encoded live recording is available for testing in browsers, though Safari does not yet support the codec.

Cloudflare is seeking developer feedback during the beta period and invites testers to share their experiences and use cases through its Discord channel.