A Go library and toolset for working with MP4 files, focused on fragmented MP4 files (MPEG-DASH, HLS fMP4), providing parsing, encryption, decryption, and information viewing.

v0.63.0
Published at
6h ago
667
Stars
410
Download
Synced at
11m ago

Latest release

v0.63.0Nov 13, 2026, 12:05 PM
Downloads slow? Switch the source anytime above

README

Project Overview

mp4ff is a Go module that implements MP4 media file parsing and writing for AVC and HEVC video, AAC and AC-3 audio, stpp and wvtt subtitles, and timed metadata tracks. It is focused on fragmented files as used for streaming in MPEG-DASH, MSS and HLS fMP4, but can also decode and encode all boxes needed for progressive MP4 files.

Key Features

  • mp4ff-info: Prints a tree of the box hierarchy with information about the boxes
  • mp4ff-pslister: Extracts and displays SPS and PPS for AVC or HEVC
  • mp4ff-nallister: Lists NALUs and picture types
  • mp4ff-subslister: Lists details of wvtt or stpp subtitle samples
  • mp4ff-crop: Crops a progressive mp4 file to a specified duration
  • mp4ff-encrypt: Encrypts a fragmented file using cenc or cbcs Common Encryption
  • mp4ff-decrypt: Decrypts a fragmented file encrypted using cenc or cbcs
  • mp4ff-mvhevc: Inspects MV-HEVC files and muxes HEVC into an MV-HEVC mp4

Target Audience

  • Video streaming developers
  • Engineers working with fragmented MP4 files
  • Go developers

Quick Start

  1. macOS/Linux via Homebrew: brew install mp4ff
  2. Or via Go: go install github.com/Eyevinn/mp4ff/cmd/mp4ff-info@latest
  3. Use mp4ff-info to view MP4 file information

Core Advantages

  • Focused on fragmented MP4 file processing
  • Rich set of command-line tools
  • Cross-platform (macOS, Linux, Windows, amd64 and arm64)
  • Open-source and free (MIT)

System Requirements

  • OS: macOS, Linux, Windows
  • Architectures: amd64, arm64

Release history

Sort