Convert WebM to HEVC — Free Online Tool
Convert WebM video files (VP9-encoded) to raw HEVC/H.265 bitstream files using libx265, achieving significantly smaller file sizes than the source WebM while preserving visual quality. HEVC's superior compression makes this ideal for archiving or distributing high-resolution web video in a format optimized for hardware-decoded playback on modern devices.
to
FFmpeg Command
Copy this command to run the same conversion locally with FFmpeg on your desktop. Download FFmpeg
Drop your WebM 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
WebM files typically contain VP9-encoded video and Opus or Vorbis audio. During this conversion, the VP9 video stream is fully re-encoded — decoded frame by frame and then re-compressed using the libx265 encoder — because VP9 and H.265 are entirely different codecs with no shortcut remux path. The output is a raw HEVC bitstream (.hevc), which is a containerless format containing only the encoded video elementary stream. This means audio tracks, subtitles, chapters, and metadata from the source WebM are not carried over, as the raw HEVC format has no container structure to hold them. The CRF 28 quality setting gives libx265 a quality target that typically produces files noticeably smaller than VP9 at comparable visual fidelity, owing to H.265's more efficient inter-frame prediction and entropy coding.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg multimedia processing tool. All subsequent arguments define the input, encoding parameters, and output for this WebM-to-HEVC conversion. |
-i input.webm
|
Specifies the source WebM file as input. FFmpeg will demux the Matroska-based WebM container and decode the VP9 video stream (and any Opus/Vorbis audio) in preparation for re-encoding. |
-c:v libx265
|
Selects libx265 as the video encoder, which re-encodes the decoded VP9 frames into H.265/HEVC. This is a full transcode — not a remux — because VP9 and HEVC are entirely different codecs. |
-crf 28
|
Sets the Constant Rate Factor for libx265 to 28, which is the encoder's default and a good quality-to-size balance. Lower values (e.g., 18) produce higher quality HEVC output from the VP9 source at the cost of larger file size; higher values compress more aggressively. |
-x265-params log-level=error
|
Passes a configuration parameter directly to the libx265 encoder suppressing its verbose per-frame encoding statistics, keeping console output clean without affecting the encoded HEVC video quality or content. |
output.hevc
|
Defines the output filename with the .hevc extension, telling FFmpeg to write a raw H.265 elementary bitstream with no container. No audio, subtitles, or metadata from the source WebM are included, as this containerless format cannot hold them. |
Common Use Cases
- Archiving web-sourced VP9 WebM videos in a more compression-efficient format for long-term storage, reducing file size without a significant perceptual quality drop
- Preparing video-only HEVC streams for ingest into a professional video editing or transcoding pipeline that accepts raw elementary streams as input
- Converting VP9 WebM screen recordings or tutorials into HEVC for playback on smart TVs, set-top boxes, and mobile devices that have hardware H.265 decoders but no VP9 support
- Stripping away the web-centric WebM container and Opus audio to produce a lean, video-only HEVC stream for re-muxing into MKV or MP4 with a separately processed audio track
- Reducing bandwidth requirements for video-only clips that will be redistributed or re-encoded further downstream, using HEVC's superior compression as an intermediate step
Frequently Asked Questions
Because VP9 and H.265 are incompatible codecs, your video must be fully decoded and re-encoded, making this a lossy transcoding step even at high quality settings. At the default CRF 28, libx265 generally produces visually excellent results, but some generation loss is unavoidable compared to the original source. If the WebM was itself already a re-encode from a higher-quality master, you should consider raising the quality by using a lower CRF value (e.g., 18–23) to minimize accumulated degradation.
They are not included in the output. The raw HEVC (.hevc) format is a containerless elementary bitstream — it has no structure for storing audio tracks, subtitles, chapters, or metadata of any kind. Only the re-encoded video stream is written to the output file. If you need to preserve audio, you should instead target a container format like MKV or MP4 that can hold both HEVC video and an audio track.
The .hevc extension denotes a raw H.265 elementary bitstream — the compressed video data with no surrounding container. This is distinct from a .mp4 or .mkv file, which wraps the same HEVC stream inside a container that adds audio, metadata, and timing information. Raw HEVC streams are useful for pipeline ingestion and low-level processing, but most consumer media players will not play them directly without a container wrapper.
At CRF 28, libx265 typically produces files that are similar in size to or somewhat smaller than a VP9 WebM encoded at a comparable quality level, since both VP9 and H.265 are modern, efficient codecs. The exact ratio depends heavily on content type — HEVC tends to have a larger advantage on high-resolution (4K) content and on footage with complex motion. For 1080p web video, expect roughly comparable sizes, with HEVC sometimes 10–30% smaller at the same perceived quality.
Change the number after -crf to control quality. Lower CRF values produce better quality at larger file sizes — CRF 18 is near-visually-lossless for most content, while CRF 28 is the libx265 default and a good balance. Values above 35 will introduce visible compression artifacts. For example, to get higher quality output from your WebM source, run: ffmpeg -i input.webm -c:v libx265 -crf 18 -x265-params log-level=error output.hevc
Yes, on Linux or macOS you can loop over files in a shell: for f in *.webm; do ffmpeg -i "$f" -c:v libx265 -crf 28 -x265-params log-level=error "${f%.webm}.hevc"; done. On Windows PowerShell, use: Get-ChildItem *.webm | ForEach-Object { ffmpeg -i $_.FullName -c:v libx265 -crf 28 -x265-params log-level=error ($_.BaseName + '.hevc') }. This is especially practical for the desktop FFmpeg command when processing large collections that exceed the browser tool's 1GB per-file limit.
Technical Notes
The libx265 encoder used here is a software implementation of the H.265/HEVC standard and will use all available CPU cores by default, making encoding significantly slower than VP9 decoding — expect conversion times 3–8x longer than the video duration for typical content on a modern machine. The -x265-params log-level=error flag suppresses libx265's verbose per-frame statistics output, which would otherwise flood the console without adding useful information for standard conversions. Because the output is a raw elementary stream, it lacks a presentation timestamp (PTS) container structure, meaning some players and tools may require re-muxing into MKV or MP4 before use. HDR metadata (HDR10, HLG) present in a VP9 WebM source may not be automatically transferred to the HEVC stream in this command; HDR passthrough requires additional -x265-params flags such as hdr-opt=1 and master-display values. Transparency (alpha channel), which VP9 in WebM supports, is not supported by HEVC and will be lost. Multiple audio tracks and Matroska-style chapter markers from the WebM source are also silently discarded, as the output format cannot represent them.