Skip to main content
toolsxulo

Image Compressor

Shrink an image's file size with a live quality slider and before/after comparison.

Drop an image, or click Upload file

No image yet

Drop an image file here, or use Upload file. Nothing is uploaded to a server.

How it works

This tool draws your image onto an off-screen canvas and re-encodes it using the browser's built-in canvas.toBlob() API at the quality level and output format (JPEG or WebP) you choose - lower quality values discard more fine detail in exchange for a smaller file. The resulting file size is measured directly from the re-encoded data and shown next to the original for comparison, all without the image ever leaving your device.

Read the full guide

How to use it

  1. Drop an image onto the box, or click Upload file to choose one.
  2. Pick an output format (JPEG or WebP) and drag the quality slider.
  3. Watch the before/after file size update live, then click Download to save it.

Frequently asked

Is my image uploaded anywhere?
No. Compression happens entirely in your browser using the Canvas API - the image file never leaves your device.
What quality setting should I use?
70-85 is a good starting point for photos - it noticeably shrinks the file while staying visually close to the original. Drop lower if file size matters more than fidelity, and compare the live preview as you go.
Why can't I compress a PNG directly?
PNG compression is lossless and doesn't have a quality slider - to meaningfully shrink a PNG's file size, this tool re-encodes it as JPEG or WebP instead, both of which support adjustable lossy compression.