Image Compression

Image Formats

Currently we supports JPEG and PNG compression formats. You can specify the format and the compression level.

Using different compression you can deliver the best quality considering the client’s bandwidth.

Here is an image with compression levels of 5, 20 and 80.

Original Image

Original Image

Original Image Size: 248 KB

JPEG Compression (Quality Level: 80)

Compression with ratio: 80

Compressed Image Size: 63.1 KB
Compression Ratio: ~4

JPEG Compression (Quality Level: 20)

Compression with ratio: 20

Compressed Image Size: 18.2 KB
Compression Ratio: ~13.5

JPEG Compression (Quality Level: 5)

Compression with ratio: 5

Compressed Image Size: 6.7 KB
Compression Ratio: ~37

you can also refer to API reference section for complete list of args.