Extract Audio from HEVC to OGG — Free Online Tool

Extract audio from HEVC/H.265 video files and save it as an OGG file encoded with the Vorbis codec — ideal for archiving high-quality audio from H.265 content in an open, royalty-free format. Since HEVC video is discarded entirely, only the audio stream is processed and re-encoded.

FFmpeg Command

Copy this command to run the same conversion locally with FFmpeg on your desktop. Download FFmpeg

Free — no uploads, no signups. Your files never leave your browser.

Estimated output:

Conversion Complete!

Download

How It Works

HEVC (.hevc) files contain a raw H.265 video bitstream and typically carry an accompanying audio stream. During this conversion, FFmpeg discards the video stream entirely using the -vn flag — no video decoding or encoding occurs. The audio stream is then decoded from its original format and re-encoded using the Vorbis codec (libvorbis) at a variable bitrate quality level of 4 (roughly 128–160 kbps), then wrapped in an OGG container. Because Vorbis is a lossy codec, this is a transcoding operation, not a lossless copy, so some generation loss is introduced relative to the original audio. The OGG container is a Xiph.Org open standard and supports Vorbis natively without any licensing restrictions.

What Each Flag Does

Flag What it does
ffmpeg Invokes the FFmpeg binary — the open-source multimedia processing engine that handles all decoding, encoding, and stream manipulation in this conversion. In the browser version, this runs via FFmpeg.wasm compiled to WebAssembly.
-i input.hevc Specifies the input file, which is a raw HEVC/H.265 bitstream. FFmpeg reads this file and identifies the available streams — in this case, a video stream and potentially an audio stream — before applying the subsequent flags.
-vn Disables video output entirely, telling FFmpeg to skip the H.265 video stream from the HEVC file without decoding it. This is the key flag that makes this an audio extraction rather than a full video conversion, and it significantly speeds up processing.
-c:a libvorbis Sets the audio encoder to libvorbis, which encodes the extracted audio as Vorbis — the native and most widely supported lossy audio codec for the OGG container. Vorbis is open, patent-free, and well-supported in browsers, Linux environments, and game engines like Godot.
-q:a 4 Sets the Vorbis variable bitrate quality level to 4 on a scale of 0–10, targeting approximately 128–160 kbps. This default strikes a balance between file size and audio transparency; increase toward 9–10 for higher fidelity or decrease toward 1–2 for smaller files when quality is less critical.
output.ogg Defines the output file as an OGG container, which tells FFmpeg to wrap the encoded Vorbis audio stream in the Xiph.Org OGG format. The .ogg extension is the standard for Vorbis audio and ensures broad compatibility with media players and web browsers.

Common Use Cases

  • Extracting a music or ambient audio track from an H.265 encoded video to use in a royalty-free media project that requires open-format audio
  • Pulling dialogue or commentary audio from an HEVC screen recording for use in a podcast or transcription workflow that accepts OGG/Vorbis files
  • Stripping the audio from a high-efficiency 4K HEVC clip to create a lightweight OGG file for embedding in a web application or HTML5 audio player
  • Archiving audio from HEVC surveillance or dashcam footage into an open, patent-unencumbered format for long-term storage
  • Preparing OGG audio assets from HEVC game cutscenes or cinematic files for use in open-source game engines like Godot, which natively prefer OGG/Vorbis
  • Reducing file size by discarding the large H.265 video payload and retaining only the audio track when video content is no longer needed

Frequently Asked Questions

Yes, some quality loss is expected because the audio is re-encoded to Vorbis, which is a lossy codec. Unless the original HEVC file's audio was already stored as Vorbis (uncommon in raw .hevc files), the audio must be decoded and re-encoded, introducing a transcoding step. At the default quality setting of -q:a 4, Vorbis targets roughly 128–160 kbps, which is transparent for most listeners but not bit-for-bit identical to the source. If lossless output is important, consider using the FLAC codec inside OGG instead.
OGG with Vorbis is a fully open and patent-free audio format developed by Xiph.Org, making it a preferred choice for projects that require royalty-free formats. Unlike MP3 (historically patent-encumbered) or AAC (requires licensing), Vorbis and the OGG container carry no licensing fees. OGG/Vorbis is natively supported in browsers, Linux systems, and open-source game engines, making it well-suited for web and open-source software contexts.
No. The -vn flag instructs FFmpeg to completely ignore the video stream — it is neither decoded nor encoded. This makes the process faster and more efficient than a full video conversion, since the computationally expensive H.265 decoding is skipped entirely. Only the audio stream is touched.
Adjust the -q:a value in the command. The scale runs from 0 (lowest quality, smallest file) to 10 (highest quality, largest file), with 4 as the default. For example, replacing -q:a 4 with -q:a 6 targets approximately 192–256 kbps and noticeably improves audio fidelity. For maximum quality from a Vorbis encode, use -q:a 9 or -q:a 10, which approach 320–500 kbps. Unlike CBR encoding, Vorbis -q:a uses variable bitrate, so the exact bitrate will fluctuate with audio complexity.
Yes. The OGG container supports multiple audio codecs, including Opus and FLAC. To use Opus (a more modern, efficient lossy codec), replace -c:a libvorbis with -c:a libopus and switch the quality flag to -b:a 128k for bitrate-based control, since Opus uses -b:a rather than -q:a. For lossless output, replace -c:a libvorbis with -c:a flac and drop the -q:a flag entirely. The output filename remains output.ogg in both cases.
FFmpeg itself processes one input at a time, but you can batch convert using a shell loop. On Linux or macOS, run: for f in *.hevc; do ffmpeg -i "$f" -vn -c:a libvorbis -q:a 4 "${f%.hevc}.ogg"; done. On Windows PowerShell, use: Get-ChildItem *.hevc | ForEach-Object { ffmpeg -i $_.FullName -vn -c:a libvorbis -q:a 4 ($_.BaseName + '.ogg') }. This is especially useful for files over 1GB, where the desktop FFmpeg command is recommended over the browser-based tool.

Technical Notes

Raw .hevc files contain a bare H.265 bitstream and may or may not include audio depending on how they were muxed. If the source file has no audio track, FFmpeg will error out with a 'no audio stream found' message and produce no output — this is expected behavior, not a tool bug. The OGG container supports multiple simultaneous audio tracks and chapter markers, though this extraction tool produces a single-track output. Vorbis metadata tags (title, artist, album, etc.) can be preserved from the source if present, or added manually by appending -metadata title="MyTrack" to the FFmpeg command. One notable limitation is that Vorbis does not support multichannel audio beyond 8 channels, but this is rarely a constraint in practice for HEVC-sourced content. If the source HEVC file contains Dolby Atmos or other object-based audio, FFmpeg will decode the core track but spatial metadata will be lost in the Vorbis encode. For HDR HEVC files, the audio extraction is unaffected by HDR metadata since video is discarded entirely.

Related Tools