Convert MPG to OGG — Free Online Tool
Convert MPG video files to OGG audio using the Vorbis codec — extracting and re-encoding the MP2 or MPEG audio track from MPEG-1/2 video into an open, patent-free container ideal for web and open-source applications. This tool runs entirely in your browser using WebAssembly; no files leave your device.
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 store video (MPEG-1 or MPEG-2) alongside audio encoded in MP2 or occasionally AAC. During this conversion, the video stream is completely discarded — OGG is a primarily audio-focused container and does not carry MPEG video in standard usage. The MP2 audio track is decoded and re-encoded using the Vorbis codec (libvorbis), which is the default and most widely supported audio codec in the OGG container. Vorbis uses variable-bitrate compression with a quality scale, and the default quality setting of 4 produces audio roughly comparable to 128–160 kbps MP3, with generally better fidelity at equivalent bitrates. The result is a standalone OGG/Vorbis audio file containing only the audio content from the original MPG.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg tool — the same underlying engine that powers this browser-based converter via WebAssembly. Running this on your desktop will produce an identical result for files over 1GB or for batch processing. |
-i input.mpg
|
Specifies the input MPG file, which contains an MPEG-1 or MPEG-2 video stream and typically an MP2 audio stream. FFmpeg reads both streams but only the audio will be used in the output. |
-c:a libvorbis
|
Sets the audio codec to libvorbis, which encodes the decoded MP2 audio from the MPG into the Vorbis format — a patent-free, open-source codec developed by Xiph.Org and the standard audio codec for the OGG container. |
-q:a 4
|
Sets the Vorbis variable bitrate quality to level 4 on a scale of 0–10, producing approximately 128–160 kbps audio quality. This is a sensible default for voice and general audio extracted from MPG broadcast or VCD sources, balancing file size and fidelity. |
output.ogg
|
Defines the output filename with the .ogg extension, telling FFmpeg to wrap the encoded Vorbis audio stream in an OGG container. No video data is written because no video codec was specified, so the MPEG-2 video is automatically discarded. |
Common Use Cases
- Extracting the audio commentary or narration from an MPEG-1 or MPEG-2 broadcast recording for use in an open-source multimedia project
- Stripping audio from old VCD or DVD-ripped MPG files to create OGG tracks for use in open-source games or interactive applications that prefer patent-free formats
- Converting legacy MPG training or lecture videos to OGG audio for distribution in learning management systems that support Xiph formats natively
- Archiving the audio portion of MPEG broadcast captures in OGG/Vorbis format, which offers better compression than the original MP2 audio at equivalent perceived quality
- Preparing audio from MPG footage for use in web applications that serve OGG as a fallback audio format alongside other formats for cross-browser compatibility
- Extracting music or sound design from old MPEG video productions to repurpose as assets in open-source or Creative Commons media libraries
Frequently Asked Questions
The video stream is completely dropped during this conversion. OGG is used here strictly as an audio container, and the tool extracts only the audio track from your MPG file. FFmpeg achieves this by specifying only an audio codec output (-c:a libvorbis) with no video codec, which causes it to discard the MPEG-1 or MPEG-2 video data entirely. Your output file will contain only audio.
Yes, there is some quality loss. The original MP2 audio in the MPG file is already lossy, and decoding it then re-encoding it to Vorbis introduces a second generation of lossy compression artifacts. The default quality setting of 4 on the Vorbis scale produces very listenable results for most content, but if audio fidelity is critical, you should use a higher Vorbis quality value such as 8 or 9. This is sometimes called 'generational loss' and is an inherent limitation when transcoding between two lossy formats.
Adjust the -q:a value in the command. The Vorbis quality scale runs from 0 (lowest, approximately 64 kbps) to 10 (highest, approximately 500 kbps), with 4 as the default (approximately 128–160 kbps). For example, to use higher quality, run: ffmpeg -i input.mpg -c:a libvorbis -q:a 7 output.ogg. Higher values produce larger files but preserve more of the original MP2 audio detail. For archival purposes, a value of 8 or 9 is generally recommended when transcoding from an already-lossy MP2 source.
Yes — the OGG container also supports Opus and FLAC. To use Opus (which is more efficient than Vorbis at lower bitrates), replace -c:a libvorbis with -c:a libopus and switch the quality parameter to -b:a 128k since Opus uses bitrate-based rather than quality-scale control. To use FLAC for lossless output within OGG, use -c:a flac, though this will produce significantly larger files. Opus is particularly well-suited if your output will be streamed or used in modern web environments.
MPG files based on MPEG-1 and MPEG-2 standards carry very limited metadata — typically little more than basic stream properties. OGG supports rich Vorbis Comment metadata tags (title, artist, album, etc.), but since the source MPG likely contains none of this information, the output OGG file will also have minimal embedded tags. You can add metadata manually using FFmpeg's -metadata flag, for example: ffmpeg -i input.mpg -c:a libvorbis -q:a 4 -metadata title="My Recording" output.ogg.
Yes, you can use a shell loop to process multiple files at once on your desktop. On Linux or macOS, use: for f in *.mpg; do ffmpeg -i "$f" -c:a libvorbis -q:a 4 "${f%.mpg}.ogg"; done. On Windows Command Prompt, use: for %f in (*.mpg) do ffmpeg -i "%f" -c:a libvorbis -q:a 4 "%~nf.ogg". The browser-based tool handles one file at a time, so the FFmpeg command is especially useful when you need to process large collections or files over 1GB.
Technical Notes
MPG files using MPEG-2 video typically encode audio as MP2 (MPEG-1 Audio Layer II), a predecessor to MP3 that was standard for broadcast and DVD applications. This MP2 audio is commonly found at 192 kbps or 224 kbps in broadcast captures. When converting to OGG/Vorbis, the MP2 stream must be fully decoded to PCM and then re-encoded — there is no stream copy path between MP2 and Vorbis. The Vorbis codec is patent-free and was developed by Xiph.Org, making OGG/Vorbis a preferred format in open-source ecosystems and Linux-based media players. One practical limitation is that OGG/Vorbis has limited native support on Apple platforms (iOS/macOS) without third-party libraries, so if your target audience uses Apple devices, consider OGG/Opus or a different output format. The OGG container does support chapter markers and multiple audio tracks per the spec, but for single-file MPG conversions these features are not typically relevant. File size after conversion will generally be smaller than the original MPG due to both the removal of the video stream and the efficiency of Vorbis compression relative to MPEG-2's overall bitrate.