Extract Audio from MKV to MP3 — Free Online Tool
Extract the audio track from an MKV video file and save it as an MP3, re-encoding the audio using the LAME encoder regardless of the original audio codec inside the MKV. This is ideal for pulling music, commentary, or dialogue out of Matroska containers that may hold AAC, Opus, Vorbis, or FLAC audio — all of which must be transcoded to MP3's lossy MPEG Audio Layer III format.
to
FFmpeg Command
Copy this command to run the same conversion locally with FFmpeg on your desktop. Download FFmpeg
Drop your MKV 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
MKV is a container format, meaning the audio track inside it could be encoded in any number of codecs — AAC, FLAC, Opus, Vorbis, or MP3 itself. Because MP3 is a standalone audio format (not a container), the conversion always involves discarding the video stream entirely and transcoding the audio to MP3 using the libmp3lame encoder at the target bitrate. If the original audio was lossless (e.g., FLAC), this conversion introduces lossy compression for the first time. If the original was already lossy (e.g., AAC or Opus), the audio undergoes generation loss — being decoded from one lossy format and re-encoded into another — so choosing a higher bitrate like 192k or 320k helps minimize the quality degradation. The output is a standalone .mp3 file with no video, no subtitles, and no chapter markers, since MP3 does not support those features.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg tool. In this browser-based tool, FFmpeg runs locally via WebAssembly (FFmpeg.wasm), so your MKV file never leaves your device. |
-i input.mkv
|
Specifies the input Matroska file. FFmpeg reads the MKV container and identifies all streams inside it — video, audio, subtitles, and any attachments — before processing begins. |
-vn
|
Disables video output entirely. This is essential for audio extraction — it tells FFmpeg to ignore all video streams in the MKV so that only audio data is processed and written to the MP3 output. |
-c:a libmp3lame
|
Selects the LAME MP3 encoder to re-encode the audio stream. Regardless of whether the MKV's audio is AAC, Opus, FLAC, or Vorbis, it will be decoded and then encoded into MPEG Audio Layer III format using the libmp3lame library. |
-b:a 128k
|
Sets the MP3 audio bitrate to 128 kilobits per second using constant bitrate (CBR) encoding. This is a widely accepted default that balances file size and perceptual audio quality; increase to 256k or 320k for music or high-fidelity content. |
output.mp3
|
Defines the output filename and signals to FFmpeg that the result should be a standalone MP3 file. The .mp3 extension causes FFmpeg to use the MP3 muxer, producing a file compatible with virtually any audio player, device, or platform. |
Common Use Cases
- Ripping the audio from an MKV movie or TV episode to listen to a film score or soundtrack on a portable MP3 player or older car stereo that doesn't support video playback
- Extracting a recorded lecture or conference talk from an MKV screen recording to share as a podcast episode or audio-only download
- Pulling dialogue or narration from an MKV video project to send to a transcription service that only accepts common audio formats
- Converting an MKV music video download into an MP3 for use in a DJ set, slideshow, or audio project where only the music track is needed
- Extracting audio commentary from an MKV Blu-ray rip to create a standalone audio file for accessibility or archival purposes
- Stripping audio from a large MKV gameplay recording so you can review or edit the voiceover track without loading the full video file
Frequently Asked Questions
It depends on what codec the audio inside your MKV is using. If the MKV contains FLAC audio, this conversion introduces lossy compression for the first time, and some quality will be lost. If it contains AAC or Opus audio, you are performing a lossy-to-lossy transcode — the audio is decoded and then re-encoded into MP3, which compounds compression artifacts. To minimize this, use the highest bitrate available (320k). If the MKV already contains an MP3 audio track, re-encoding it to MP3 again still causes some generation loss, though at 320k it is often imperceptible.
No. MP3 is a bare audio format and does not support chapters, subtitles, or multiple audio tracks — all of which are features of the MKV container. The output MP3 will contain only the first audio stream from the MKV. ID3 tags (artist, title, album) can technically be embedded in an MP3, but the FFmpeg command as shown does not copy MKV metadata into ID3 format automatically, so tag information from the MKV may be lost or incomplete.
By default, FFmpeg selects the first audio stream it finds in the MKV, which is typically the main audio track. If you want a specific track — for example, the second audio stream — you would modify the command to add '-map 0:a:1' before the output filename to explicitly select the second audio track (zero-indexed). Without this flag, the director's commentary or alternate language track would be ignored.
Replace the '128k' value in the '-b:a 128k' flag with your desired bitrate. For example, use '-b:a 320k' for the highest MP3 quality suitable for music, or '-b:a 64k' for voice recordings where file size matters more than fidelity. The full command at 320k would be: ffmpeg -i input.mkv -vn -c:a libmp3lame -b:a 320k output.mp3. Note that bitrates above 320k are not valid for MP3 — that is the format's ceiling.
Yes. On Linux or macOS, you can loop over all MKV files in a directory with a shell one-liner: 'for f in *.mkv; do ffmpeg -i "$f" -vn -c:a libmp3lame -b:a 128k "${f%.mkv}.mp3"; done'. On Windows Command Prompt, use: 'for %f in (*.mkv) do ffmpeg -i "%f" -vn -c:a libmp3lame -b:a 128k "%~nf.mp3"'. Each MKV will produce a corresponding MP3 file with the same base filename.
MKV files typically contain a full video stream alongside audio, and video data dominates file size — often by a factor of 10 to 50 or more. By stripping the video with '-vn' and encoding only the audio at 128k MP3, you are discarding the vast majority of the file's data. A 1GB MKV with 90 minutes of video might yield an MP3 of only 80–110MB, depending on the duration. The audio bitrate of 128k accounts for roughly 1MB per minute of audio.
Technical Notes
The libmp3lame encoder used here is the gold-standard open-source LAME MP3 encoder, and '-b:a 128k' sets constant bitrate (CBR) encoding at 128 kilobits per second — the historical default that most streaming services once used for MP3 delivery. MP3 supports stereo and mono audio but does not support multi-channel surround sound (beyond basic joint stereo), so if your MKV contains 5.1 surround audio, libmp3lame will automatically downmix it to stereo. The format caps at 320k bitrate and does not support lossless encoding. Unlike AAC or Opus, MP3 has no native container for metadata beyond ID3 tags; MKV-specific metadata such as chapter titles, subtitle tracks, and attachment files are completely dropped. MP3 has excellent compatibility with virtually every device and software player ever made, making it the right choice when portability matters more than audio fidelity or file efficiency. If audio quality or file size efficiency is the priority, formats like AAC or Opus would outperform MP3 at equivalent bitrates, but MP3 remains the safest choice for legacy hardware compatibility.