Blog / Guide

H.264 vs H.265 (HEVC): Compatibility and File-Size Tradeoffs

H.264 vs H.265 (HEVC): Compatibility and File-Size Tradeoffs

H.265, also called HEVC, can store the same picture in less space than H.264 (also called AVC). H.264 is the safer choice when you don’t know what will play the file. So: choose HEVC when the player is known to support it and storage or bandwidth matters, and choose H.264 when compatibility matters more than size. How much smaller HEVC gets depends on the video and on how it was encoded, so treat any fixed figure such as “50% smaller” as a rough, commonly quoted benchmark and not a promise: published comparisons report different savings under different quality metrics and test conditions.

The rest of this guide explains how to check which codec a file uses, why it may fail on a particular device, and which fix to try first.

They are codecs, not file types

H.264 and H.265 are video codecs: two different ways to compress video, standardised by ITU-T as Recommendation H.264 and Recommendation H.265. MP4 and MKV are containers that package compressed video and audio into a single file.

The two are independent, and the mix-up causes most confusion:

  • An .mp4 file can contain H.264 or H.265 (and other codecs).
  • An .mkv file can also contain either.
  • Renaming a file changes its label, not its contents.

So “does this file work?” is really two questions: does the player understand the container, and does it understand the codec inside, at this resolution and frame rate? The MP4 vs MKV vs WebM guide covers the container half in detail.

The tradeoff

H.264 (AVC) H.265 (HEVC)
Compression efficiency Baseline Generally more efficient for comparable visual quality
Compatibility The common default across devices, browsers and editors Depends on the device, OS, software and sometimes resolution and frame rate
Decoding effort Lower Higher, which matters most on older hardware
Best when The player is unknown or old, or you need the file to just open The player is known to support it and size or bandwidth matters

The efficiency advantage is real. Apple’s support page on HEIF and HEVC says HEVC offers better compression than H.264, so it uses less storage while preserving the same visual quality. But “how much less” is not fixed. It varies with the source material, the encoder and its settings, and the quality target, which is why published savings figures differ and why you shouldn’t plan storage around one of them. Content that is hard to compress, with noise, grain or constant motion, tends to save less than a clean screen recording.

Why a file doesn’t play

If an HEVC file fails on a device, the cause is usually one of these:

  1. The device or software has no HEVC decoder. Older hardware, older operating systems or a player without the codec can open the container and still fail on the video.
  2. A limit on resolution or frame rate. Apple’s page notes that on some older devices HEVC support depends on resolution and frame rate, and that 1080p or lower at 60 fps or lower is more broadly compatible. That is Apple-specific, so look up your own device’s documentation rather than applying the numbers elsewhere.
  3. The container is the problem, not the codec. A player might handle the codec but not the container, or not a particular audio or subtitle track.

Symptoms vary: a black screen with sound, stuttering, an error about an unsupported format, or a file that opens only in some apps. Sound without picture often points to a missing video decoder, but that is a clue, not proof; confirm the codec first.

Find out what is inside the file

Check the codec before you change anything. A media-inspection tool such as MediaInfo or ffprobe lists the codecs, resolution and frame rate. With FFmpeg’s ffprobe:

ffprobe -v error -select_streams v:0 -show_entries stream=codec_name,profile,width,height,avg_frame_rate -of default=noprint_wrappers=1 input.mp4

codec_name=h264 means H.264/AVC, and codec_name=hevc means H.265/HEVC. The output also gives the resolution and frame rate to compare against your device’s limits. MAX shows the codecs of the media it detects before you download, so you can see whether a version uses H.264 or HEVC and avoid downloading something your player can’t use.

Then compare against the target device’s own list of supported formats.

Pick the least destructive fix

Match the remedy to the cause:

  • The codec is supported but the container isn’t: remux. This moves the same encoded streams into a different container without re-encoding, so there is no quality change. FFmpeg describes this as streamcopy: packets are copied without decoding or encoding.
  • The device can’t decode the codec at all: remuxing cannot help, because the video is still HEVC. You need to transcode it to a codec the device supports, or obtain an H.264 version. FFmpeg’s documentation notes that transcoding is computationally expensive and in most cases degrades quality, and recommends it only when needed, for example to feed the stream to something that cannot decode the original codec.
  • You have a choice of versions before downloading: pick the one the device can play. This is the cheapest fix and involves no conversion.

Apple’s page gives a real-world example of the last two. Its devices can capture in the more compatible H.264 instead of HEVC, QuickTime Player on a Mac can export an HEVC video with the “Greater Compatibility (H.264)” option, and media shared to a device that doesn’t support HEVC may be converted automatically. The point to take from it is that converting is a deliberate re-encode with a quality cost, not a rename.

Decide in practice

These are illustrative situations, not test results:

  • A video for an old television or an unknown recipient: prefer H.264, even if the file is bigger.
  • A library on a recent computer or phone where you’ve confirmed HEVC playback, and disk space is tight: HEVC is a reasonable choice.
  • Editing in a program you haven’t checked: assume H.264 is safest until you’ve confirmed HEVC support.
  • A file already in HEVC that your player rejects: identify whether it is the container or the codec before converting.

What this means when downloading with MAX

MAX downloads the version the source serves and copies its streams without re-encoding. When a page offers both H.264 and HEVC versions, the codec details help you choose the one your device handles. MAX does not convert HEVC to H.264 or otherwise change codecs, and it can’t guarantee that a downloaded file plays on a specific device. If you end up with an HEVC file your player can’t decode, you need a separate transcoder or a different version. MAX Video Downloader is free, and it works with media a page exposes, not YouTube or DRM-protected content. For choosing among versions, see how to choose video download quality.