MCAP (pronounced "em-cap") is a modular container file format for heterogeneous timestamped data. It is ideal for robotics applications, as it can record multiple streams of structured and unstructured data (e.g. ROS, Protobuf, JSON Schema, MessagePack, etc.) in a single file.

MCAP works well under various workloads, resource constraints, and durability requirements.

Heterogeneous data

  • Store messages encoded in multiple serialization formats in a single file
  • Include metadata and attachments

Performant writing

  • Append-only structure
  • Recover partially-written files when data recording is interrupted

Efficient seeking

  • Extract data without scanning the entire file
  • Fast access to indexed summary data

Self-contained files

  • Embed all message schemas in the file
  • No extra dependencies needed for decoding

Quick start

Install the mcap CLI tool to accomplish any of the following tasks and more:

You can also use the MCAP libraries below to read and write your own MCAP files:

Additional resources

MCAP organizes its data via the following concepts:

The unit of communication between nodes in the pub/sub system.
A stream of messages which have the same type, or schema. Often corresponds to a connection between a publisher and a subscriber.
A description of the structure and contents of messages on a channel, e.g. a Protobuf FileDescriptorSet or JSON Schema.

Check out the resources below to learn more about MCAP:

Join the Foxglove Slack community to ask questions and give feedback.