DocumentsImagesMediaPDF Tools

Convert MP4 to MKV Online

Convert MP4 to Matroska MKV with full subtitle and multi-track support — in your browser.

Drag your file here

.mp4 · up to 100 MB

Processed in your browser — file never uploadedFree
Note: The first conversion loads the FFmpeg engine (~25MB). Subsequent conversions will be faster.

MP4 to MKV: container flexibility for your media library

Multi-track and subtitles

MKV supports multi-language audio and multiple SRT/ASS/PGS subtitle tracks selectable at playback.

Plex and Jellyfin optimized

H.264 MKV is Plex's recommended format for direct play without transcoding.

No re-encoding

Video and audio streams are copied bit-for-bit. Mathematically identical quality to the MP4.

100% private

Your video is processed in your browser with FFmpeg.wasm. No external servers.

Three steps, no hassle

1

Upload your MP4 file

Drag or select your .mp4 or .m4v file. Up to 2 GB, no signup.

2

Remux to MKV

All video, audio, and subtitle tracks are transferred to the MKV container with no re-encoding.

3

Download your MKV

File ready for your Plex, Jellyfin, or Kodi library with enriched metadata and multi-track support.

Got questions?

Both MP4 and MKV can contain H.264, H.265/HEVC, AV1, and other modern codecs. The difference is not in supported codecs but in container capabilities. MP4 (MPEG-4 Part 14, ISO 14496-14) is the industry standard for streaming distribution: YouTube, Netflix, Disney+, and most OTT platforms distribute in MP4/fMP4 (fragmented MP4). MKV, by contrast, is optimized for local storage and media libraries: it supports multiple audio tracks in different languages selectable at playback time, multiple subtitle tracks (SRT, ASS, VobSub, PGS) as first-class citizens, chapters with text metadata, font attachments for ASS/SSA subtitles, and per-track tags. For a Plex or Jellyfin library with multi-language content and quality subtitles, MKV is technically superior to MP4 in metadata flexibility.

No, as long as the MP4 contains subtitles in compatible formats. MP4 supports 'tx3g' subtitles (3GPP Timed Text, used by iTunes and QuickTime) and 'wvtt' (WebVTT). FFmpeg converts both formats to UTF-8 text tracks in Matroska (S_TEXT/UTF8) during the remux. PGS subtitles (bitmap images, Blu-ray format) in MP4 are also correctly transferred as S_HDMV/PGS in MKV. The only exception is subtitles encoded as video (hardcoded/burned-in subtitles in the video stream): these are not separate tracks and cannot be extracted by any remux, only by OCR video processing.

MP4 uses ISOBMFF (ISO Base Media File Format, ISO 14496-12), an atom/box architecture where the file is hierarchically organized in boxes such as 'ftyp' (file type), 'moov' (track and timing metadata), and 'mdat' (multimedia data). ISOBMFF was designed for streaming: the 'moov' atom can be placed at the file start (MP4 faststart, processed by FFmpeg with -movflags +faststart) to allow progressive playback before downloading the full file. MKV uses EBML (Extensible Binary Meta Language, RFC 8794), a self-describing binary format that allows extensibility without breaking compatibility. ISOBMFF has better hardware support: hardware decode chips in smartphones, Smart TVs, and Blu-ray players are optimized to parse ISOBMFF boxes. EBML/MKV has better metadata flexibility and is the de facto standard for private media server distribution (Plex, Jellyfin, Kodi).

For personal archival in a local media library, MKV offers concrete advantages over MP4. First, the Matroska specification is fully open and public from its inception (matroska.org, 2002), with no patent or licensing restrictions. Second, MKV supports attachments that allow including poster art, cover art, and typography font files together with the video in a single file. Third, Matroska tags allow per-track individual metadata with the official MATROSKA_TAG_METADATA schema, including fields for creation date, language, edition, and production notes. Fourth, corruption resilience: EBML with distributed SeekHeads allows playback recovery from midpoints even if the file's beginning is damaged. For streaming distribution, MP4 remains superior due to its universal hardware and platform support.

Plex supports both, but the experience differs by content. For video with a single audio track and no subtitles, MP4 H.264 has better direct play support on more devices (including older network players that only support ISOBMFF containers). For content with multiple audio tracks or subtitles, MKV allows Plex to use direct stream (no transcoding) for track switching on the client, while MP4 may require transcoding. The official Plex Media Server guide recommends H.264 MKV as the reference format for maximum server compatibility. Jellyfin, fully open source, has equally good support for both formats in its web and Android clients.

The remux is near-instant compared to video playback time. For a 1 GB file (2-hour movie in H.264), the remux in FFmpeg.wasm typically takes 5–30 seconds depending on CPU speed and available browser memory. There is no video or audio decoding — only reading the compressed stream from the MP4 and writing it in MKV's EBML format. Most of the time is spent parsing the MP4 'moov' atom to extract timestamps and building the Matroska SeekHead and equivalent TrackEntry elements.

Convert MP4 to MKV: ISOBMFF to EBML for Plex, Jellyfin, and archival libraries

MP4 (MPEG-4 Part 14, specified in ISO 14496-14 in 2003) is the world's most widely deployed container format for digital video distribution. Its architecture is based on ISOBMFF (ISO Base Media File Format, ISO 14496-12), which in turn derives directly from Apple's QuickTime format — the MPEG committee took QuickTime as its base and standardized it internationally. The atom/box structure of ISOBMFF has proven extremely adaptable: fragmented MP4 (fMP4, defined in ISO 14496-12 Amendment 2, 2004) is the technical foundation of DASH (Dynamic Adaptive Streaming over HTTP, ISO/IEC 23009-1) and HLS (HTTP Live Streaming, RFC 8216), the two dominant adaptive streaming protocols used by virtually all modern video-on-demand infrastructure — YouTube since 2015, Netflix, Disney+, Amazon Prime Video, and HBO Max. MP4's dominance in streaming stems from its faststart capability: by placing the 'moov' atom at the file's beginning, players can begin playback before downloading the full file, essential for progressive streaming. However, this same streaming architecture makes MP4 less flexible for local media libraries where the priority is metadata richness and runtime track selection.

Matroska (MKV) was designed from the start for local storage and private network distribution, not for public internet streaming. The philosophical difference is reflected in its EBML architecture: while ISOBMFF/MP4 optimizes for sequential access and HTTP streaming, EBML/MKV optimizes for efficient random access (multiple distributed SeekHeads throughout the file), extensibility (new elements without breaking existing players), and metadata richness (Matroska's tag system allows describing each track individually with fields like LANGUAGE, COUNTRY, PART_NUMBER, TOTAL_PARTS, DATE_ENCODED, ENCODER, and custom tags). In the home media server ecosystem, MKV has become the de facto standard: Plex Media Server, Jellyfin, and Kodi treat MKV as their reference format, leveraging multiple audio tracks for multilingual libraries (track 1: English, track 2: Spanish, track 3: Japanese with subtitles) and embedded subtitle tracks to avoid external .srt files. For anime collections or foreign content with alternative translations, MKV's ability to hold multiple selectable subtitles is especially valuable.

Convertir.ai executes the MP4 to MKV remux directly in the browser using FFmpeg.wasm. The technical process begins by analyzing the MP4's ISOBMFF structure: FFmpeg locates the 'moov' atom (which may be at the file start in faststart MP4 or at the end in files generated by direct camera recording), reads nested 'trak' atoms with their 'tkhd' (Track Header, track type), 'mdia' with 'mdhd' (Media Header, timebase), and 'minf' with 'stbl' (Sample Table, containing 'stts' for timestamps, 'stsc' for sample-to-chunk mapping, 'stco'/'co64' for chunk offsets in the file, and 'stsd' for codec extradata). MP4 timescales (typically 90000 Hz for video, 44100 or 48000 Hz for audio) are converted to Matroska's nanosecond time base. Codec extradatas (SPS/PPS for H.264 in 'avcC', VPS/SPS/PPS for HEVC in 'hvcC', descriptor for AAC in 'esds') are extracted from the 'stsd' atom and inserted as Private Data in Matroska TrackEntry elements. Data samples are read from offsets specified by 'stco' and written into Matroska BlockGroups with calculated timestamps and keyframe flags (from the 'ctts' composition time offsets stream). The result is an MKV file functionally identical to the source MP4, fully compatible with Plex, Jellyfin, VLC, and any Matroska player.