Compressing videos and GIFs the right way

Chris Gallello
3 min readDec 13, 2017

--

This is a PSA on how to compress videos and GIFs really well for launch emails, onboarding tooltips, homepage videos, etc. This is how we do things over at Purple for all of our promotional material and onboarding videos/GIFs in the app. Disclaimer: I/we have no connection to or stake in any of the software that I talk about below. Just wanted to share what I’ve learned.

Use Handbrake for video compression

The UI is a little intimidating, but it’s super powerful

Handbrake is one of the most impressive pieces of software I’ve come across. I’m constantly blown away by how much it can compress with minimal effect on the final result. https://handbrake.fr/

For example, I recently compressed a 2.4mb video (exported from iMovie) down to 57kb. WHAT. Prior to Handbrake I would have laughed at compression ratios like that. At the compression that I used, there is a noticeable loss in quality, but only when you flip back and forth between the two. Here are the files:

Now — I suspect that some of this has to do with the fact that the examples I’m showing use very few colors — but even when I compress actual videos, I see really great compression as well (60–90% from Handbrake). You can generally get the best balance of quality vs size when you set the Quality slider to anywhere between 25-35. You can also crop the video in the Picture tab, which is super helpful sometimes.

Use GIF Brewery + Compressor.io for GIF compression

I’ve used GIF Brewery in the past but didn’t think much of it until I discovered something super strange with it. Ugh this is sounding like “one weird trick!”, but seriously. It turns out the file size can get super small if you use Quicktime for screen capture, GIF Brewery to convert the MOV to a GIF, then run that through Compressor.io for the final compression. I am blown away with how well it works. Oddly enough, Giphy Capture, which is my normal go-to GIF recording software, does not exhibit the same compression ratio. Here’s an example:

  • Quicktime + GIF Brewery — 9.3MB (download)
  • Quicktime + GIF Brewery + compressor.io — 290kb (download)
  • Giphy Capture — 4.8MB (download)
  • Giphy Capture + Compressor.io — 3.6MB (download)

The way compression works boggles my mind.

Don’t compress GIFs that you’re uploading to Twitter

This might sound counterintuitive, but Twitter converts all of your uploaded GIFs into compressed video files — which means that your 10MB high quality GIF will end up being much smaller anyways. This doesn’t mean you should simply upload a video though! Even though uploaded GIFs just end up as video files, the way Twitter treats them is a little different. With a video, you have a timeline scrubber and a play button. But when you upload a GIF, there won’t be a timeline scrubber, and it will loop automatically. This is good in many cases. So just think through what experience you want to provide your audience.

Alright, that’s all. Media on the internet is weird, long live the GIF, and best of luck with whatever you use this guide for!

--

--