Extract Audio from MPG to AC3 — Free Online Tool
Extract and convert the audio track from an MPG video file into AC3 (Dolby Digital) format, producing a standalone .ac3 file encoded with the ac3 codec at 192k bitrate by default. This is especially useful for repurposing MPEG-1/2 broadcast or DVD-source audio into a format natively compatible with Dolby Digital decoders, home theater receivers, and authoring pipelines.
to
FFmpeg Command
Copy this command to run the same conversion locally with FFmpeg on your desktop. Download FFmpeg
Drop your MPG 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
MPG files typically carry audio encoded as MP2 (MPEG Audio Layer II), which was the standard for broadcast television, VCDs, and early DVDs. This tool discards the video stream entirely using the -vn flag, then re-encodes only the audio from MP2 into AC3 — Dolby Digital's lossy format — using FFmpeg's built-in ac3 encoder. Because MP2 and AC3 are distinct codecs with different compression architectures, a full audio transcode is required; the audio is decoded from MP2 and re-encoded into AC3 bitstream. The result is a raw .ac3 file with no container wrapper, suitable for direct use in DVD/Blu-ray authoring tools, AV receivers, or broadcast systems that expect Dolby Digital audio.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg command-line tool. In the browser, this runs via FFmpeg.wasm (WebAssembly), so no installation is needed and no files leave your device. |
-i input.mpg
|
Specifies the input MPG file. FFmpeg reads the MPEG-1/2 container and identifies all streams, including the video track and the MP2 (or other) audio track embedded within it. |
-vn
|
Disables video output entirely, telling FFmpeg to ignore the MPEG-1/2 video stream. Since the goal is audio extraction, this prevents any video data from being processed or included in the output .ac3 file. |
-c:a ac3
|
Selects FFmpeg's native AC3 encoder to re-encode the audio into Dolby Digital format. The source MP2 audio from the MPG is fully decoded and then compressed into an AC3 bitstream compatible with DVD authoring, AV receivers, and broadcast systems. |
-b:a 192k
|
Sets the AC3 output bitrate to 192 kilobits per second, which is a standard Dolby Digital bitrate for stereo content. You can raise this to 384k or 640k for higher fidelity, especially if the source MPG audio was encoded at a high MP2 bitrate. |
output.ac3
|
Specifies the output filename with the .ac3 extension, indicating a raw Dolby Digital bitstream file with no container wrapper. This format is directly compatible with DVD authoring tools, MKV muxers, and hardware decoders that accept bare AC3 streams. |
Common Use Cases
- Extracting the audio from a broadcast-recorded MPG file and converting it to AC3 for inclusion in a DVD authoring project using tools like DVD Architect or Encore
- Repurposing the audio from an MPEG-2 video captured from a set-top box or DVR into Dolby Digital format for playback on a home theater AV receiver
- Converting MP2-encoded audio embedded in MPG files into AC3 so it can be muxed into an MKV or MP4 container alongside a video stream that requires Dolby Digital audio
- Archiving the audio commentary or soundtrack from a VCD or DVD-source MPG file as a standalone AC3 file for long-term storage or re-authoring
- Preparing audio from legacy MPEG broadcast recordings for use in modern video production workflows that require Dolby Digital-compatible deliverables
- Extracting and converting dialog or music tracks from MPG training or presentation videos into AC3 for integration into professional AV systems
Frequently Asked Questions
Yes, some quality loss is expected because this is a transcode between two lossy codecs — the audio is decoded from MP2 and re-encoded into AC3. The degree of degradation depends on the source bitrate and the target AC3 bitrate. At 192k, AC3 generally sounds clean for stereo content, but if the source MP2 was already at a low bitrate (e.g., 128k), artifacts from the original encoding will carry through. For critical audio, use the highest AC3 bitrate available (640k) to minimize additional compression loss.
The .ac3 extension denotes a raw Dolby Digital bitstream with no container wrapper. This is intentional for workflows where the AC3 audio will be muxed into another container (like MKV or VOB) separately, or fed directly into a DVD/Blu-ray authoring tool that expects bare AC3 streams. If you need the audio inside a container, you can mux the .ac3 file into MKV or MP4 using a separate FFmpeg command without re-encoding.
No — the tool will work regardless of the audio codec in the MPG file, including AAC or MP3 variants. However, MP2 is by far the most common audio codec in MPG files (especially MPEG-2 broadcast and DVD sources), so it's the typical case. FFmpeg will automatically detect and decode whatever audio codec is present in the MPG before re-encoding to AC3.
Yes — replace the 192k value in the -b:a 192k flag with any supported AC3 bitrate: 96k, 128k, 192k, 256k, 320k, 384k, 448k, or 640k. For example, use -b:a 384k for higher-quality Dolby Digital output, which is the standard bitrate for 5.1 surround sound on DVDs. Note that AC3 is a Dolby Digital format and higher bitrates only help if your source audio has enough quality and channel count to benefit.
The output channel layout depends entirely on the source audio in the MPG file. Standard broadcast MPG files typically carry stereo (2-channel) MP2 audio, so the AC3 output will also be stereo. If the source MPG contains multi-channel audio, FFmpeg will preserve the channel layout in the AC3 output. Most MPG files from VCD or broadcast sources are stereo, so 5.1 AC3 output is uncommon in this specific conversion path.
On Linux or macOS, you can use a shell loop: for f in *.mpg; do ffmpeg -i "$f" -vn -c:a ac3 -b:a 192k "${f%.mpg}.ac3"; done. On Windows Command Prompt, use: for %f in (*.mpg) do ffmpeg -i "%f" -vn -c:a ac3 -b:a 192k "%~nf.ac3". This processes each MPG file individually and outputs a matching .ac3 file for each one. The browser-based tool processes one file at a time, so the FFmpeg command is the recommended approach for bulk conversions.
Technical Notes
MPG files conforming to the MPEG-2 standard (as used in DVD and broadcast) carry audio as MP2 (MPEG-1 Audio Layer II) at bitrates typically ranging from 192k to 384k. AC3 (Dolby Digital) uses a completely different psychoacoustic model and bitstream format — there is no stream-copy path between MP2 and AC3, meaning a full decode-and-reencode is always performed. The ac3 encoder in FFmpeg is a well-tested native implementation of the Dolby Digital standard and supports bitrates from 96k up to 640k. Raw .ac3 files carry no metadata such as track titles or language tags; any such metadata present in the MPG's audio stream will be lost during extraction. The raw AC3 bitstream is directly compatible with DVD VOB muxing, MKV containers (as A_AC3), and broadcast transport streams. Note that AC3 is inherently a lossy format and the output will always be a generation loss from the source, regardless of the bitrate chosen.