DocumentsImagesMediaPDF Tools

Convert AVI to MKV Online

Modernize your legacy AVI files to Matroska MKV — no re-encoding, in your browser.

Drag your file here

.avi · 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.

AVI to MKV: modernize your legacy collection without quality loss

No 2 GB limit

MKV uses 64-bit offsets. No truncation issues that affect old AVI files.

Embedded subtitles

Add SRT, SSA, or VobSub tracks to the MKV with MKVToolNix — one self-contained file.

No re-encoding

The DivX/Xvid stream is copied intact. Identical quality to the original AVI, no artifacts.

Plex and Jellyfin ready

MKV is automatically recognized by Plex, Jellyfin, and Kodi with full metadata.

Three steps, no hassle

1

Upload your AVI file

Drag or select your .avi file. Compatible with DivX, Xvid, DivX 3/5/6, and uncompressed AVI.

2

Remux to MKV

Video and audio tracks are transferred directly to the Matroska container. No re-encoding.

3

Download your MKV

MKV file ready for your Plex, Jellyfin, or Kodi library, with full subtitle support.

Got questions?

AVI (Audio Video Interleave, specified by Microsoft in 1992 as part of Video for Windows) was designed for 486/Pentium-era hardware with hard drives under 2 GB. The format has structural limitations that make it problematic for modern use: 2 GB file size limit (without OpenDML, standardized in 1996 as AVI 2.0), no native support for embedded subtitles, inability to hold more than one audio track in standard form, and limited metadata. DivX and Xvid files from 2001–2008 — the peak era of P2P video sharing on eDonkey2000 and BitTorrent — almost universally use the AVI container. Converting them to MKV allows integration into modern Plex, Jellyfin, or Kodi libraries with automatic metadata recognition (NFO, posters), adding SRT subtitles in multiple languages, and direct play without transcoding on any Matroska-compatible device.

Original AVI (RIFF-based, 1992) uses 32-bit offsets to index video and audio samples, limiting the maximum index size to approximately 2 GB total file size. OpenDML (AVI 2.0, 1996) extended the format with 64-bit indexes in additional 'ix' chunks, allowing multi-gigabyte files. However, many P2P-era DivX/Xvid files were encoded with the 2 GB limit in mind: movies at 700 MB (one CD-ROM) or 1.4 GB (two CD-ROMs). Files exceeding 2 GB in real AVI format (non-OpenDML) are silently truncated or have the last minutes corrupted. If you have an AVI of a 2-hour film at high resolution exceeding 2 GB, the final scenes may not play. Converting to MKV, which uses 64-bit offsets natively, preserves content intact regardless of size.

AVI has no official support for embedded subtitles in its original RIFF specification. There is an informal hack where subtitle tracks are stored as additional video streams of type 'GAB2' or similar, but player compatibility is inconsistent and non-standardized. In practice, P2P-era DivX/Xvid files came with separate .srt or .sub/.idx (VobSub) files that needed to be in the same folder with the same base name. MKV formally supports multiple subtitle tracks (SRT/SubRip as S_TEXT/UTF8, SSA/ASS as S_TEXT/ASS, VobSub as S_VOBSUB, PGS as S_HDMV/PGS) as first-class container tracks, selectable by the user in any compatible player. Converting AVI to MKV with this tool and then using MKVToolNix to add the corresponding .srt gives you a single self-contained file.

Yes. DivX (based on MPEG-4 Part 2 ASP, FourCC codec ID 'DIVX', 'DX50', or 'DIV3') and Xvid (the equivalent open-source implementation, FourCC 'XVID') are variants of MPEG-4 Part 2 (ISO 14496-2). Matroska supports them natively with codec ID V_MPEG4/ISO/ASP. All modern players — VLC, MPV, MPC-HC, and Plex and Kodi clients — decode MPEG-4 Part 2 without issues. When remuxing AVI to MKV, the MPEG-4 Part 2 stream is copied bit-for-bit without modification; decodability is identical to the original AVI, but in a more modern container with better metadata.

Yes, and it's the most important feature of this conversion. Re-encoding (transcoding) means decoding video to uncompressed frames and re-compressing with a codec, which inevitably introduces generational quality loss and takes a long time. Remux means copying the existing compressed stream from one container to another untouched. This tool uses FFmpeg with -c:v copy -c:a copy, copying all streams without modification. The process is near-instant (much faster than the video's duration) and the resulting quality is mathematically identical to the original AVI — no additional artifacts, no detail loss, no bitrate change.

AVI supports multiple audio formats: MP3 (codec ID 0x0055 in the AVI WAVEFORMATEX header), AC3/Dolby Digital (codec ID 0x2000), PCM (0x0001), and AAC (0x00FF or via extensions). Matroska supports all of these with their corresponding codec IDs: A_MPEG/L3 for MP3, A_AC3 for AC3 Dolby Digital, A_PCM/INT/LIT for PCM, A_AAC for AAC. During the AVI-to-MKV remux, all audio tracks are transferred with their correct codec IDs. The AC3 5.1 audio from DVD-era DivX rips is preserved intact and can play on home theater systems via SPDIF or HDMI with direct passthrough.

Convert AVI to MKV: modernize your DivX/Xvid collection for Plex and Jellyfin

AVI (Audio Video Interleave) was created by Microsoft and introduced in November 1992 as part of the Video for Windows package, coinciding with the Windows 3.1 multimedia release. The format is based on RIFF (Resource Interchange File Format), Microsoft's multimedia file architecture that organizes content into chunks identified by 4-character FourCC codes with 32-bit sizes. This 1992 design decision — 32-bit offsets — is the root of AVI's famous 2 GB limit: the size field in the RIFF header is an unsigned 32-bit integer, allowing a maximum of 2^32−1 bytes ≈ 4 GB for the container, but the 'idx1' index that lists frame offsets also uses 32-bit values, limiting direct access to the first 2 GB. The OpenDML extension (created by the OpenDML AVI M-JPEG File Format Subcommittee, published as AVI 2.0 in 1996) partially addresses this by adding 'ix' chunks with 64-bit offsets, but implementation is inconsistent across applications. AVI was the de facto standard format for digital video on PC during the late 1990s and early 2000s, especially for MPEG-4 Part 2 codecs (DivX and Xvid) that dominated P2P video sharing from 2001 to 2008.

The DivX/Xvid era represents the largest archive of digital video in AVI format: millions of DVD rips encoded between 2001 and 2010 using DivX (the company founded in 2001 that commercialized Jerome Rota's illicit DivX ;-) codec as a legitimate product) or Xvid (the parallel open-source project started in 2001 by developers who formed XviD.org following the original license controversy). These files present a digital preservation challenge: modern players such as Plex clients on Android TV, Apple TV, and Chromecast with Google TV decode MPEG-4 Part 2 (the underlying DivX/Xvid codec), but the AVI container with its limited metadata prevents automatic metadata recognition by Plex Media Scanner or identification by The Movie Database (TMDB). Converting to MKV lets files be named per Plex convention (Movie (Year).mkv) and recognized automatically with posters, synopses, and ratings. Jellyfin, the completely free open-source alternative to Plex (a fork of Emby, released in December 2018), has the same behavior with its NFO and TMDB scraper system.

Convertir.ai processes AVI to MKV conversion entirely in the browser using FFmpeg.wasm. The technical process begins with RIFF file analysis: FFmpeg reads the RIFF header ('RIFF' + size + 'AVI '), the 'hdrl' chunk (AVI Main Header with frame rate, dimensions, stream count), and individual 'strl' chunks for each stream (Stream Header with codec FourCC type, Stream Format with BITMAPINFOHEADER for video or WAVEFORMATEX for audio). If the AVI has an 'idx1' index at the end of the file, it is used for efficient seeking; if corrupted or absent, FFmpeg scans the file for RIFF frame chunks ('00dc' for compressed type-0 video frames, '00wb' for audio). Identified streams are packaged into Matroska: MPEG-4 Part 2 video as V_MPEG4/ISO/ASP with codec extradata (VOS, MPEG-4 sequence header encoding), MP3 audio as A_MPEG/L3, AC3 audio as A_AC3. Timestamps are recalculated from AVI frame rate to Matroska's nanosecond time base. All compressed stream data is copied without decoding, resulting in a fast process that preserves quality perfectly.