Extract Audio from M2TS to FLAC — Free Online Tool
Extract lossless audio from M2TS Blu-ray and AVCHD files and save it as FLAC — preserving every bit of the original audio quality with no lossy compression. Ideal for archiving high-definition soundtracks, DTS-encoded audio, or multichannel audio from Blu-ray rips into a universally playable lossless format.
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 are MPEG-2 Transport Stream containers commonly found on Blu-ray discs and AVCHD camcorders, and they typically carry high-quality audio streams alongside HD video — often AAC, AC-3, DTS, or PCM. This tool strips the video stream entirely and re-encodes the primary audio stream using the FLAC codec, which applies lossless compression. Because FLAC is lossless, no audio data is discarded — the output is mathematically identical in quality to the decoded source audio. The compression level setting controls only the trade-off between encoding speed and output file size, not audio fidelity. Note that if the source M2TS contains a multichannel audio stream (e.g., 5.1 surround), FLAC will preserve all channels in the output file.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg program, the open-source multimedia processing engine that powers this conversion both in the browser (via FFmpeg.wasm) and on the desktop command line. |
-i input.m2ts
|
Specifies the input file — an M2TS Blu-ray or AVCHD container that may contain HD video, one or more audio tracks, and subtitle streams. FFmpeg will parse the transport stream to identify all available streams before processing. |
-vn
|
Disables video output entirely, instructing FFmpeg to ignore all video streams in the M2TS file. This is essential for an audio-only extraction — without this flag, FFmpeg would attempt to include video in the output, which FLAC cannot contain. |
-c:a flac
|
Sets the audio codec to FLAC (Free Lossless Audio Codec), which encodes the decoded audio from the M2TS source with lossless compression. The audio quality is identical to the decoded source — no data is thrown away. |
-compression_level 5
|
Sets the FLAC compression effort to level 5 on a 0–8 scale. This controls only how aggressively the encoder compresses the file size, not audio quality — level 5 is the standard default, balancing encoding speed and output file size for typical Blu-ray audio extractions. |
output.flac
|
The name of the output file. The .flac extension tells FFmpeg to write a standalone FLAC audio file containing the losslessly compressed audio extracted from the M2TS source. |
Common Use Cases
- Archive the lossless soundtrack from a Blu-ray rip stored as an M2TS file for long-term preservation without any quality degradation
- Extract high-quality audio from AVCHD camcorder footage (e.g., a live concert or wedding recording) to use in a music or audio production project
- Pull the audio from a Blu-ray movie M2TS file to create a lossless reference track for audio synchronization in video editing software
- Convert M2TS audio to FLAC for playback on audiophile hardware and software players that support FLAC but not M2TS containers
- Extract dialogue or ambient audio from an HD broadcast recording saved as M2TS for use in sound design or post-production
- Produce a lossless FLAC backup of the audio track from a home Blu-ray disc rip before transcoding to other formats, ensuring you always have the original quality source
Frequently Asked Questions
No — FLAC is a lossless codec, meaning the audio is compressed without discarding any data. The decoded FLAC file is bit-for-bit identical to the uncompressed source audio. The only caveat is that if the original M2TS carries a lossy audio stream (such as AAC or AC-3), that lossy encoding already introduced quality loss before your conversion; FLAC will faithfully preserve whatever is in that stream, but cannot recover what was lost at the source.
FLAC fully supports multichannel audio, so if your M2TS file contains a 5.1 or 7.1 surround audio stream, the FLAC output will preserve all channels. FFmpeg will map the primary audio stream by default, retaining its channel layout. Be aware that M2TS files sometimes contain multiple audio tracks (e.g., different languages or commentary); this tool extracts only the first audio stream by default.
M2TS files from Blu-ray discs often contain several audio tracks for different languages or formats. To select a specific track, modify the FFmpeg command by adding a stream specifier before the output, such as '-map 0:a:1' to select the second audio stream (zero-indexed). You can first inspect the file's streams by running 'ffmpeg -i input.m2ts' in a terminal to see all available audio tracks and their indices.
The '-compression_level 5' flag tells the FLAC encoder how hard to work at compressing the audio data, on a scale from 0 (fastest, largest file) to 8 (slowest, smallest file). Crucially, all levels produce identical audio quality — only file size and encoding speed differ. Level 5 is the standard default and offers a good balance. For large Blu-ray audio extractions where disk space matters, you could try level 8, but the size savings beyond level 5 are typically modest.
On Linux or macOS, you can loop over files in a terminal: 'for f in *.m2ts; do ffmpeg -i "$f" -vn -c:a flac -compression_level 5 "${f%.m2ts}.flac"; done'. On Windows Command Prompt, use: 'for %f in (*.m2ts) do ffmpeg -i "%f" -vn -c:a flac -compression_level 5 "%~nf.flac"'. The browser-based tool processes one file at a time, so the FFmpeg command is especially useful for batch jobs or files over 1GB.
This is unlikely unless your M2TS source carried a heavily compressed lossy audio codec like AC-3 or AAC. When you decode a lossy stream and re-encode it to lossless FLAC, the FLAC output represents the full uncompressed PCM data losslessly, which will be significantly larger than the original compressed audio. If the M2TS contained PCM audio, the FLAC file should be smaller due to FLAC's lossless compression. The video stream, which was typically the bulk of the M2TS file size, is discarded entirely by the '-vn' flag.
Technical Notes
M2TS files use the BDAV MPEG-2 Transport Stream wrapper, which can carry a wide variety of audio codecs including AAC, AC-3, E-AC-3, DTS, DTS-HD Master Audio, and LPCM — the specific codec depends on the source (Blu-ray disc, AVCHD camcorder, or broadcast recording). FFmpeg will decode whatever audio stream is present and re-encode it to FLAC. If the source audio is DTS-HD or TrueHD (common on full Blu-ray rips), the resulting FLAC will be an accurate lossless representation of that decoded audio. FLAC supports up to 8 channels and sample rates up to 655,350 Hz, so most Blu-ray audio configurations are handled correctly. Metadata such as track title or artist tags embedded in the M2TS stream may not be automatically transferred, as M2TS carries metadata differently than FLAC's native Vorbis comment tags — you may need to add tags manually after conversion. FLAC does not support multiple audio tracks in a single file; if your M2TS has several audio streams and you need all of them, you must run separate extractions with explicit stream mapping for each track.