Skip to main content

MCAP

logo

MCAP (pronounced "em-cap") is an open source container file format for multimodal log data. It supports multiple channels of timestamped pre-serialized data, and is ideal for use in pub/sub or robotics applications.

Get StartedAPI Reference
drawer-envelope

Pub/Sub logging

MCAP is ideal for storing multiple channels of timestamped log data, such as pub/sub messages or multimodal sensor data.

drawer-envelope

Serialization agnostic

MCAP is a container format, allowing you to record and replay binary messages in any format, such as Protobuf, DDS (CDR), ROS, JSON, etc.

High-performance writing

MCAP utilizes a row-oriented, append-only design. This minimizes disk I/O, and reduces the risk of data corruption during an unclean shutdown.

drawer-envelope

Self-contained

MCAP files are fully self-contained, including schemas required to deserialize each channel. Older files always remain readable, even as your codebase evolves.

Efficient seeking

MCAP files contain an optional index, allowing for fast, efficient reading, even over a low-bandwidth internet connection.

Optional compression

Data can be compressed using lz4 or zstd, while still supporting efficient indexed reads and chunk-based decompression.

Multilingual

MCAP reader and writer libraries are available in many languages, including C++, Go, Python, Rust, Swift, and Typescript.

Flexible

Features such as chunking, indexing, CRC checksums, and compression are optional. You choose the right tradeoffs for your application.

Production grade

MCAP is used in production by a wide range of companies, from autonomous vehicles to drones, and is the default log format in ROS 2.