compresso
Open the app

JavaScript image compressor for the browser

compresso.js is a 3.6 KB, zero-dependency library that compresses, resizes, and converts images using the Canvas API — with optional HEIC input and parallel Web Worker batching.

How it works

  1. npm install compresso.js
  2. import { compress } from "compresso.js"
  3. await compress(file, options)

Common questions

TypeScript?
First-class types ship with the package.

For developers

Embed compression in your upload flow:

npm install compresso.js
npm · Docs

Related