Convert M2TS to AVI — Free Online Tool
Convert M2TS Blu-ray and AVCHD video files to AVI format using H.264 video and MP3 audio — transcoding high-definition transport stream content into a widely compatible legacy container. Ideal for getting Blu-ray rips and camcorder footage into older editing software or media players that don't support MPEG-2 Transport Streams.
to
FFmpeg Command
Copy this command to run the same conversion locally with FFmpeg on your desktop. Download FFmpeg
Drop your M2TS file here
or click to browse
Free — no uploads, no signups. Your files never leave your browser.
Settings
Note: Browser-based encoding uses approximate quality targets. For precise CRF compression, copy the FFmpeg command above and run it on your desktop.
Estimated output:
Conversion Complete!
DownloadHow It Works
M2TS files encapsulate video (typically H.264 or MPEG-2) and audio (often AC-3, DTS, or TrueHD) inside an MPEG-2 Transport Stream container. During this conversion, the video stream is re-encoded to H.264 using libx264 (even if the source is already H.264, because the AVI container requires different stream framing and the M2TS transport stream packetization is incompatible with AVI's interleaved chunk structure). The audio is transcoded from whatever format it uses in the M2TS — commonly AC-3 surround or lossless TrueHD — down to stereo MP3 using the LAME encoder, as AVI has limited multi-channel audio support. The result is a self-contained AVI file with interleaved audio and video chunks, though M2TS features like embedded subtitles and secondary audio tracks are dropped because AVI does not support them.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg binary — the open-source multimedia processing engine that powers this conversion entirely within your browser via WebAssembly (FFmpeg.wasm), with no server upload required. |
-i input.m2ts
|
Specifies the M2TS input file — FFmpeg reads the MPEG-2 Transport Stream container, demultiplexes the packetized video, audio, and subtitle streams, and passes them to the appropriate decoders. |
-c:v libx264
|
Re-encodes the video stream using the libx264 H.264 encoder. This is necessary because M2TS transport stream packetization is fundamentally incompatible with AVI's interleaved chunk structure, so the video cannot be copied directly regardless of the source codec. |
-c:a libmp3lame
|
Transcodes the audio to MP3 using the LAME encoder. This replaces whatever audio format the M2TS carried — commonly AC-3, DTS, or lossless TrueHD — with a widely compatible MP3 stream that AVI players universally support, though the surround mix will be downmixed to stereo. |
-crf 23
|
Sets the H.264 Constant Rate Factor to 23, which is libx264's default and a good quality-to-size balance for HD content. Lower values (e.g. 18) produce higher quality closer to the Blu-ray source at the cost of larger AVI file size. |
-b:a 128k
|
Sets the MP3 audio bitrate to 128 kilobits per second. This is adequate for stereo dialogue and music but represents a significant reduction from the lossless or high-bitrate surround audio typically found in M2TS source files; increase to 192k or 320k to preserve more audio fidelity. |
output.avi
|
Defines the output filename and tells FFmpeg to use the AVI (RIFF Audio Video Interleave) container format. FFmpeg infers the container from the .avi extension and muxes the encoded H.264 video and MP3 audio into interleaved chunks accordingly. |
Common Use Cases
- Loading Blu-ray rips or AVCHD camcorder footage into legacy video editing software like older versions of Adobe Premiere or Windows Movie Maker that cannot parse MPEG-2 Transport Streams
- Playing high-definition M2TS recordings on older media players or smart TVs that support AVI/H.264 but lack M2TS demuxer support
- Archiving AVCHD footage from Sony or Panasonic camcorders into a simpler container for long-term storage on systems where M2TS playback support is unreliable
- Preparing Blu-ray disc rips for use in DVD authoring or video production pipelines that require AVI as an interchange format
- Sharing HD camcorder clips with collaborators or clients whose editing workstations only accept AVI input
- Stripping the transport stream overhead and complex audio tracks from broadcast-captured M2TS files to produce leaner AVI files for offline review
Frequently Asked Questions
Yes, some quality loss is unavoidable because this conversion requires re-encoding both the video and audio streams. The video is re-encoded from the M2TS source (often H.264 or MPEG-2) to H.264 at CRF 23, which is visually near-lossless for most content but not a mathematically lossless copy. More significant is the audio: M2TS commonly carries lossless or high-quality surround formats like Dolby TrueHD or DTS-HD MA, and these are transcoded down to stereo MP3 at 128k — a noticeable downgrade from the original audio fidelity.
Blu-ray M2TS files typically carry multi-channel surround audio in formats like Dolby TrueHD, DTS-HD Master Audio, or AC-3 5.1. AVI's support for multi-channel audio is inconsistent across players, so this tool transcodes the audio to stereo MP3. This means your 5.1 or 7.1 surround mix will be downmixed to two channels during conversion. If preserving surround audio is critical, a container like MKV would be a better conversion target.
No. M2TS supports embedded subtitle tracks (including PGS/Blu-ray bitmap subtitles), but the AVI container has no subtitle support at all. Subtitle tracks are silently dropped during this conversion. If you need subtitles preserved, you would need to either burn them into the video stream as hardcoded subtitles (using an FFmpeg filter like -vf subtitles) or convert to a container like MKV that supports subtitle passthrough.
Converting M2TS to AVI requires full re-encoding of both the video and audio streams — the CPU must decompress and recompress every single frame rather than just rewrapping the data. By contrast, remuxing M2TS to MKV can copy streams directly without re-encoding, which is nearly instant. High-definition M2TS files are particularly demanding to re-encode because they often contain 1080p or 4K content with high bitrates, so processing a single Blu-ray chapter can take several minutes even on modern hardware.
Adjust the -crf value to control video quality. CRF (Constant Rate Factor) works on a scale where lower numbers mean higher quality and larger file sizes: -crf 18 is considered visually lossless for most content, while -crf 28 produces smaller files with more compression artifacts. The default CRF 23 is a balanced midpoint for H.264. For Blu-ray source material where preserving fine detail matters, try -crf 18 or -crf 20. To also increase audio quality, raise the -b:a value to 192k or 320k, especially if the M2TS source had high-quality lossless audio.
Yes. On Linux or macOS, you can run: for f in *.m2ts; do ffmpeg -i "$f" -c:v libx264 -c:a libmp3lame -crf 23 -b:a 128k "${f%.m2ts}.avi"; done — this loops through every M2TS file in the current directory and converts each one to a matching AVI file. On Windows Command Prompt, use: for %f in (*.m2ts) do ffmpeg -i "%f" -c:v libx264 -c:a libmp3lame -crf 23 -b:a 128k "%~nf.avi". This is especially useful for processing large Blu-ray or AVCHD libraries that exceed the browser tool's 1GB file limit.
Technical Notes
M2TS uses MPEG-2 Transport Stream packetization, which adds overhead and timestamps designed for broadcast and disc delivery — none of this structure is compatible with AVI's simple interleaved chunk format (RIFF). As a result, a full transcode is mandatory; there is no remux path. The libx264 encoder handles the video side well, as H.264 is natively supported in AVI (though technically outside the original AVI specification, it works in practice with all modern players). The AVI container does not support B-frame reference structures beyond a limited depth, but libx264 at default settings handles this correctly. One significant limitation is that AVI files larger than 2GB require the OpenDML AVI extension, which FFmpeg writes automatically but some older software cannot read. For long Blu-ray content at high bitrates, output files may exceed this threshold. Additionally, AVI has no support for variable frame rate content — if the M2TS source is VFR (common in AVCHD), FFmpeg will normalize it to CFR during encoding, which may cause minor timing discrepancies. Metadata such as creation timestamps and camera model information embedded in the M2TS are not carried over to the AVI output.