Free MKV test files and sample generator

Flexible open container that can hold many video, audio and subtitle tracks.

Generate a .mkv file →

What is a .mkv file?

MKV: Matroska Video. Matroska is a flexible container that can hold almost any codec plus multiple audio and subtitle tracks. It is the enthusiast and archival standard, and a superset of WebM's structure.

Why generate a test MKV file?

What you can put inside a .mkv file

You get 3 content options for MKV, so the file holds something meaningful rather than random padding: Color bars, Timer / counter, Logo motion. For MKV these are alternatives, so choose the one that matches what you need to test.

How a .mkv file is identified

Every .mkv file begins with 1A 45 DF A3, an EBML header, WebM and Matroska share it, and differ only in the DocType inside. That is what a validator inspecting content rather than the file name looks for.

How the size lands on the exact byte

Matroska defines a Void element that readers skip, so the padding goes there after the browser has finished recording.

Negative testing with broken MKV files

Which failure to reach for, and what to assert for each, is covered in how to make a corrupted file for testing. For upload limits and type checks see testing file upload validation.

Sample MKV content

[Binary video], 1080p, H.264, multi-track.

This shows the shape of the file. Your download is generated fresh at the size you choose, so the values will differ.

How to open and verify the file

Play in VLC or MPC-HC; inspect with `mkvinfo` or `ffprobe`.

Media type video/x-matroska · extension .mkv · category Video

Generate a .mkv file → · questions about sizes, privacy or cost are answered on the site FAQ.

Frequently asked questions about MKV files

What identifies a .mkv file?

A .mkv file begins with the bytes 1A 45 DF A3, an EBML header, WebM and Matroska share it, and differ only in the DocType inside. Those bytes are what a content-sniffing validator looks for, and what the Corrupted condition destroys.

How can a .mkv file be an exact number of bytes?

Matroska defines a Void element that readers skip, so the padding goes there after the browser has finished recording.

What can go inside the MKV file?

There are 3 content options for .mkv: Color bars, Timer / counter, Logo motion. For MKV these are alternatives, so pick the one matching what you need to test.

Can I download several broken MKV files at once?

Yes, select more than one File Condition and you get one ZIP containing a .mkv per condition, each named after its condition.

Can the MKV file use UTF-16 or a byte-order mark?

No, and deliberately. A .mkv file is a container rather than plain text, so rewriting its bytes as UTF-16 would not produce a UTF-16 document. It would produce a broken file. Use a text format such as CSV, JSON or XML for encoding tests.

How do I open or verify the MKV file?

Play in VLC or MPC-HC; inspect with mkvinfo or ffprobe.

Related Video formats

MP4 · AVI · WEBM · SRT · VTT · MOV · FLV · 3GP

Browse all file formats →