What codec does MP4 use? MP4 is a container, not a codec

MP4 isn't a codec: it's a container holding video and audio compressed by separate codecs, such as H.264 and AAC. How to tell them apart.

4 min readSume
All posts

MP4 doesn't use one codec, because MP4 isn't a codec. It's a container: a file format that holds separately compressed video and audio streams, plus the index a player needs to find them. The video inside is compressed with a video codec such as H.264, and the audio with an audio codec such as AAC, so the .mp4 extension tells you the container, not what's inside it.

The format and codec facts come from FFmpeg's ffmpeg, formats, codecs, and ffprobe documentation, and Sume's from the Video trim and Video inspect docs and the Sume API reference, read on 2026-09-28. Anything described as current behavior is read from Sume's code.

What's the difference between a codec and a container?

A codec compresses one stream; a container packs the compressed streams into a file. That's why you can change one without the other:

From FFmpeg's ffmpeg and formats documentation and the Sume API reference, read 2026-09-28.
CompareCodecContainer
What it isThe way one video or audio stream is compressed, and the encoder and decoder for itThe file format that holds the streams and the metadata about their packets
ExamplesH.264 and H.265 (HEVC) for video, AAC for audioMP4 (MPEG-4 Part 14) and MOV
Changing itRe-encode: decode the stream and compress it again, as FFmpeg's -c:v libx264 doesStream copy: move the packets into a new file without decoding or encoding them, as FFmpeg's -c copy does
Where Sume's probe reports itvideo_codec and audio_codeccontainer

Is H.264 a codec?

Yes. FFmpeg describes H.264 as ITU-T H.264 / MPEG-4 Part 10 AVC video. The shared "MPEG-4" name is part of the confusion: MP4 is MPEG-4 Part 14, a container, and H.264 is MPEG-4 Part 10, a video codec. H.265 is HEVC, which FFmpeg calls hevc, and AAC is an audio codec. So "MP4, H.264, AAC" names three things: the container, the video codec, and the audio codec.

Is MP4 the same as MOV?

They're related containers, not the same one. FFmpeg's docs say MOV was originally developed for Apple QuickTime and later used as the basis for the MPEG-4 Part 1 (later Part 14) format, and that the family shares a common structure based on the ISO base media file format (ISOBMFF). FFmpeg writes them with separate mov and mp4 muxers.

In both, a normal file keeps the metadata about all its packets in one place, usually written at the end of the file; FFmpeg's +faststart flag moves it to the start. MP4 faststart and the moov atom covers that index.

Can I change MOV to MP4 without re-encoding?

Yes, when the new container can hold the same codecs, because only the wrapper changes: -c copy moves the compressed video and audio into the new file as they are. FFmpeg's docs name changing the container format as one use of stream copy, with no quality loss. The same docs note a copy can fail when the target container needs information the source lacks; re-encode then.

ffmpeg -i input.mov -c copy output.mp4

How do I see which codecs an MP4 uses?

Probe the file: ffprobe reports the container's format and each stream's codec separately, and How to check a video's codec walks through the command and Sume's free probe, whose container, video_codec, and audio_codec fields split the same way.

Which codecs do Sume's MP4 files use?

Sume's editing tools read your workspace's media.sume.com files and, when they re-encode, write H.264 video and AAC audio in an MP4: an exact trim per its docs, and video filter, Timeline compose, and Timeline render in current code. The exception is a keyframe trim, which copies the source's codecs as they are; converting a clip to H.264 covers that case, and Sume API output formats lists what every endpoint returns.

Sources

Related posts

More in Media tools

All Media tools posts

Written by Sume