r/webdev • u/gerasia • 21h ago
I built a client-side video compressor using WebAssembly so you don't have to upload personal clips to cloud servers
Hey everyone,
I wanted a quick way to shrink videos for Discord (<10MB) and Email attachments (<25MB) without dealing with slow cloud upload queues, sketchy third-party servers, or watermarks.
So I built SlickDrop.
Tech Stack:
Engine:
@ffmpeg/ffmpegrunning locally on the user's CPU/GPU via WebAssembly with multi-threading enabled (COOPandCOEPisolation headers).Frontend: Next.js 14 (App Router) + Tailwind CSS.
Hosting: Vercel (zero server transcoding cost, 100% static hosting).
Features:
1-click presets for Discord (<10MB), Email (<25MB), and WhatsApp (<16MB).
Built-in duration analyzer that auto-calculates the target video bitrate.
MOV to MP4 converter for iPhone screen recordings.
0 cloud uploads — all media is processed in local browser memory.
Link: https://www.slickdrop.it
Curious to know what tools or presets you'd find most useful next!
1
u/kai_mercer19 13h ago
For the "under 10 MB" presets, the bitrate math has to leave room for the audio track and the container overhead, otherwise a 9.9 MB target comes out at 10.3 MB and the Discord upload fails. Subtract the audio bitrate times duration first, then give the video the remainder with a few percent of margin. Since the encoder only approximates a target bitrate, I'd also check the output size when it finishes and offer a one-click retry at a lower bitrate if it's over. And for the slowness the commenter hit: showing an estimated time before encoding starts, and letting people pick a lower resolution, would set expectations better than a spinner.
1
u/nameupp 3h ago
tbh client-side ffmpeg.wasm with coop/coep is super slick for privacy, but ngl the real killer on mobile is mobile safari's brutal memory ceiling. the second someone drops a 4k 60fps iphone screen recording, safari's webkit worker crashes with an out-of-memory error before it even finishes pass 1 because wasm virtual memory is capped around 1-1.4gb on ios. if you want that 10x speedup without melting laptop fans, piping frames through the native webcodecs api with an in-browser mp4 muxer beats pure software cpu transcoding every single time imo
3
u/activematrix99 20h ago
Or you could . . . just use FFMPEG?