← Tools Video Compressor Mark Harfouche

Shrink a video to a target file size or bitrate — H.264 or H.265 — using your computer's hardware video encoder through the browser's WebCodecs API. The file never leaves your machine.

Add your video

No data is transmitted; all encoding happens on your device. Open source on GitHub.

Drop a video here or click to choose

MP4, MOV, or M4V — H.264 or H.265 video.

Compressed on your device with your hardware encoder. Never uploaded.

How this works & privacy

This tool demuxes your file with MP4Box.js, decodes and re-encodes the video with the browser's WebCodecs API — which routes to your machine's hardware video encoder — and repackages the result with mp4-muxer. Every step runs locally in your browser; your video is never uploaded.

AAC audio is copied through unchanged (remuxed, not re-encoded), so keeping audio costs no extra quality and almost no time. Video with an audio codec other than AAC will have its audio dropped — you'll be told when that happens.

Turning on a volume boost decodes and re-encodes just the audio (the video still passes through the hardware encoder untouched). Auto-boost measures loudness in the human-voice band (~300–3400 Hz) so a quiet voice track is judged on the voice itself, not on a single loud non-voice sound, then rides the gain up to rescue it — up to +36 dB — and automatically backs that off the instant anything gets loud (a music jingle, a shout), so a boost sized for a whisper can't blast a louder passage through the roof. It only ever turns audio up, never down. Manual boost is a flat dB you choose yourself, with no automatic backing-off, through a limiter so it can't clip. The Trim/Settings/Export preview plays the same boost live so you can listen before exporting.

Captions are made on your device by OpenAI's open-weights Whisper speech model (MIT), run with transformers.js (Apache-2.0) on your GPU through WebGPU, or on the CPU without it. The model's weights (and the ONNX Runtime engine) are downloaded from Hugging Face and jsDelivr the first time you generate captions and cached by your browser after that — only the model comes in; your audio is transcribed locally and never sent anywhere. The captions are drawn onto the video frames (“burned in”), so they show in every player and on every site.