Tool

Codec String Decoder

Turns strings like avc1.640028, found in an HLS playlist's CODECS attribute, in MP4 info or in <source type>, into plain language. Your input is processed only inside this browser and is never sent anywhere.

avc1.640028

H.264 High, Level 4

Profile
High (profile_idc 100 = 0x64)
8-bit, 4:2:0. The usual choice for H.264 video today.
Constraint flags
0x00 (00000000)
Level
4 (level_idc 40 = 0x28)
Up to 245,760 macroblocks/s, 8,192 macroblocks per frame
Bit depth
8bit

Ask this browser

Minimum level needed by resolution and fps (H.264)

VideoMinimum level neededOK at your level?
720p 30fps3.1Yes
1080p 30fps4Yes
1080p 60fps4.2No
1440p 60fps5.1No
4K 30fps5.1No
4K 60fps5.2No
8K 30fps6No
8K 60fps6.1No

This only considers the frame size and samples-per-second limits. Levels also have bitrate limits, so a high-bitrate video may need a level one step higher.

Where do you see these strings?

  • In an HLS master playlist: #EXT-X-STREAM-INF:...CODECS="avc1.64001f,mp4a.40.2"
  • In HTML: <source src=... type='video/mp4; codecs="av01.0.08M.08"'>
  • As arguments to MediaSource.isTypeSupported(), canPlayType() and MediaCapabilities.decodingInfo() in JavaScript

How to read each codec

H.264: avc1.PPCCLL

Split the six hex digits after the dot into pairs. PP is the profile (64=100=High, 4D=77=Main, 42=66=Baseline), CC holds the constraint flags, and LL is the level times 10. avc1.640028 splits into 64, 00 and 28: High profile, level 0x28=40, which is level 4.0.

HEVC: hvc1.profile.compatibility-flags.tier-and-level.constraints

In hvc1.1.6.L123.B0, 1 means Main and 2 means Main 10. The L in L123 means the Main tier (H is the High tier), and the number 123 is the level times 30, so 123÷30=4.1. The difference between hvc1 and hev1 is whether the parameter sets are kept in the file header or may also appear inside the samples.

AV1: av01.profile.level+tier.bit-depth

av01.0.08M.08 means profile 0 (Main), level number 08, tier M, 8-bit. Convert the level number with 2 + (number÷4).number%4: 08 → 2+2=4 with remainder 0, so 4.0; 12 → 5.0; 13 → 5.1. There is also a longer form with monochrome, subsampling, color info and range fields appended.

How to use it

  • Check an HLS ladder: confirm that the CODECS attribute in the master playlist matches how the video was actually encoded. If a 1080p60 rendition is labeled level 4.0, the table above shows it as not OK, which is how you catch a mismatch.
  • Narrow down a playback failure: if the same codec plays on some devices but not others, the cause is often the profile (for example Main 10) or the level. Change the string step by step and see where the canPlayType result changes.
  • Write HTML sources: list the exact string in type in the order AV1 → HEVC → H.264, and the browser picks the first source it can play (see Chapter 18).
  • Get the real values from your file: read your file's codec and resolution with the Video File Info Inspector, and see per-codec support on your device with the Codec Support Check.

How to read the verdicts

  • canPlayType: the browser returns only one of three values: "probably", "maybe" or "" (an empty string). An empty string means it can't play it.
  • Playback, smooth, power efficient: these are the supported, smooth and powerEfficient fields of MediaCapabilities. A “Yes” for power efficient usually signals that a hardware decoder handles it.
  • “Smooth” is judged against the resolution, fps and bitrate you entered above. Change the values and check again.

Limitations

  • The level table only calculates the spec's frame size and samples-per-second limits. Levels also have bitrate and reference frame limits, so the level you actually need may be higher. It also doesn't calculate H.264's separate width and height limits.
  • The browser verdicts are the answer of this device and this browser. Other devices, apps and smart TVs may differ, and “Playback: Yes” is also reported when the video plays through software decoding.
  • The tool checks that the string is written according to the spec, but it can't know whether the string matches the actual file. If it differs from the values inside the file, the browser may judge wrongly.
  • The formats it can decode are avc1 and avc3, hvc1 and hev1, av01, vp09, and common audio (AAC, MP3, Opus, FLAC, AC-3, E-AC-3). Dolby Vision (dvh1) and similar are not decoded.