Stop Twitter From Turning Your PNGs Into JPGs

When you embed any static image onto Twitter, it tries to compress it down as a JPEG to save bandwidth. For photos, that's usually fine; JPEG was designed for photos. But digital art, infographics and screenshots usually look their best in the PNG image format. If you upload those as PNGs, Twitter will still compress them into JPEGs and they might come out crappy. Here's how to fix that.

It's not this bad, but it feels like it.

Game developer Andi McClure noticed Twitter's compression when she uploaded a crisp PNG screenshot full of pastel colour blocks and Twitter spit out a JPEG cluttered with compression artefacts. (If you click to zoom in, you'll see it all around that one-pixel blue line that cuts through the purple.)

McClure wrote a clever tweet about it and game writer Christine Love replied with a fix: Add some transparency, even a pixel, to your PNG and Twitter won't turn it into a JPEG. You can even make the pixel just a tiny bit transparent.

If you run into any trouble, there are more technical details in the thread. For instance, you need to save as a true-colour PNG, not an optimised PNG. (While you're there, all the game makers in that thread are worth a follow.) A little tweaking should clear up those artefacts and keep your image literally pixel-perfect.


Comments

Be the first to comment on this story!