MP4 Metadata Viewer - Extract Video File Info Online
View MP4 metadata online: codec, resolution, duration, bitrate, creation date, GPS, and all ISO BMFF atoms. No upload, 100% client-side.
Drop MP4 file here or click to browse
Supports .mp4, .m4v, .m4a, .mov β up to 4 GB
Parsing binary structureβ¦
About
MP4 files conform to ISO 14496-12 (ISO Base Media File Format). The container organizes data into nested boxes (atoms), each identified by a 4-character code and a 32-bit or 64-bit size field. Critical metadata lives in the moov atom: the mvhd box stores global timescale and duration, while each trak contains per-track timing (mdhd), handler type (hdlr), and codec parameters (stsd). Timestamps in MP4 use an epoch of January 1, 1904 - not Unix 1970 - meaning raw values require an offset of 2082844800 seconds. Getting codec details wrong leads to transcoding failures, streaming incompatibility, or silent audio.
This tool parses the binary structure directly in your browser using DataView on the raw ArrayBuffer. No file leaves your machine. It reads fixed-point fields (16.16 for rates, 2.30 for volume), decodes iTunes-style ilst metadata (artist, title, album art), and maps hdlr component subtypes to human-readable track labels.
Limitation: heavily fragmented files with moof atoms (live streams) may show incomplete track data since the tool targets standard progressive MP4 layout.
Formulas
Duration in seconds from raw MP4 fields:
T = durationtimescale
where duration is the tick count from mvhd or mdhd, and timescale is ticks per second (commonly 600 for video, 44100 or 48000 for audio).
MP4 timestamp to Unix timestamp conversion:
tunix = tmp4 β 2082844800
where 2082844800 is the offset in seconds between 1904-01-01 and 1970-01-01.
Fixed-point 16.16 decoding:
value = raw3265536
Average bitrate estimation:
bitrate = fileSize Γ 8T bps
where fileSize is in bytes and T is duration in seconds.
Reference Data
| Atom / Box | ISO Code | Contains | Typical Location |
|---|---|---|---|
| File Type | ftyp | Brand, version, compatible brands | Root (first box) |
| Movie Header | mvhd | Timescale, duration, creation/modification dates, rate, volume | moov |
| Track Header | tkhd | Track ID, dimensions, transformation matrix, duration | moov β trak |
| Media Header | mdhd | Track timescale, duration, language code | moov β trak β mdia |
| Handler Reference | hdlr | Track type: vide, soun, text, sbtl | moov β trak β mdia |
| Sample Description | stsd | Codec FourCC (avc1, hev1, mp4a, etc.), sample rate, channels | moov β trak β mdia β minf β stbl |
| Sample Table | stbl | Sample sizes, chunk offsets, sync samples | moov β trak β mdia β minf |
| User Data | udta | Custom metadata, copyright, location | moov or moov β trak |
| iTunes Metadata | ilst | Artist, title, album, cover art, genre, year | moov β udta β meta |
| Free Space | free | Padding bytes (ignored by players) | Root or moov |
| Media Data | mdat | Actual audio/video sample data | Root |
| Edit List | elst | Media time offsets, dwell segments | moov β trak β edts |
| Composition Offset | ctts | PTS/DTS offset for B-frames | stbl |
| Sync Sample | stss | Keyframe indices | stbl |
| Color Parameter | colr | Color primaries, transfer characteristics, matrix | stsd entry |
| Pixel Aspect Ratio | pasp | hSpacing, vSpacing | stsd entry |
| AVC Config | avcC | Profile, level, SPS/PPS NAL units | stsd β avc1 |
| HEVC Config | hvcC | Profile, tier, level, VPS/SPS/PPS | stsd β hev1/hvc1 |
| Audio Config | esds | AAC profile, sample rate, channels | stsd β mp4a |
| GPS Location | Β©xyz | Latitude, longitude (ISO 6709) | udta |