DEV Community

Jonathan Devis
Jonathan Devis

Posted on

I Built a Free Online Video Compressor in 1 Week

Hi everyone!
In the last two weeks, I've worked on a tiny side project Video Compress

  • A fast, free, and simple online video compressor with no watermarks or limits on use.

The Problem

You've got a ton of free online video compressors to choose from, though most of those services will throw a lot of frustrating restrictions on you watermarks, file size limits, and hidden paywalls.
I was looking for something simple: upload, compress, download -no unnecessary things, no tricks.

The Tech Stack

The project is developed with:

Frontend: Next JS, static site generation and an ultra-fast UI.
Backend: Node JS, for handling API requests.
FFmpeg, on server to make compression more efficient.
The Next app is all static - served out on a CDN for near-instant access all over the world – while all the real work happens on the server with the backend API.

Reasons for Moving Compression to the Backend

First, I added compression to the frontend through Web Assembly builds of FFmpeg.
It worked, but performance was not good - CPU load was low and compressing large files took forever.

This allowed me to shift the compression to the server side so that I could take advantage of full CPU and I/O performance of the machine.
And that resulted in faster compression-especially if you were working with a longer video or a higher resolution file (like 1080p or 4K).

It also gave me more flexibility to:

Optimize compression presets dynamically

Manage bigger uploads

Compatibility to various video formats, like MP4, MOV, AVI, etc.

Lessons Learned

Sure, frontend compression sounds neat and all, but when you got some serious grind to do, ain't worth the effort.
No comparison to the quality/size ratio of FFmpeg.
Keep the UI as simple as it can get - users are only interested in getting results, not navigating through loads of settings.
Static building with Next JS + Node JS backend is a power combo for projects like this - quick to build, deploy easily and scalable.

Test It

Get it now or try it here:

https://shrinkvideos.com/

It's totally free, no watermarks, no hidden limits.
Would appreciate your comments or suggestions of improvement!

Top comments (0)