Image compression & quality
James Lambie 2017-04-26T07:30:04Z
93 words
1 min read

Applies compression to the image, reducing file size. Accepts any number from 1-100. If not specified, the default is 75.

The quality parameter can be added to the querystring as either q or quality

The best results for quality and file size can be found around 40-60%, where we’ve found generated images to be visually indistinguishable from the source image.

The original image and all quality variations below are 2048 × 1024 pixels.

Original image, 4.7MB

Original JPG

Quality = 100%, 1.3MB

Quality 100

Quality = 75%, 180kB

Quality 75

Quality = 50%, 119kB

Quality 50

Quality = 25%, 82kB

Quality 25

See something to improve? Edit in Github.