Compress JPG, PNG and WebP images privately
Large images slow down websites, blow past email attachment limits, and fill up storage. This tool reduces image file size while keeping photos looking sharp — useful for web pages, email, CMS uploads with size caps, and freeing up space. It’s for anyone who needs a smaller file without an upload-and-wait round trip.
How it works
The tool loads the browser-image-compression library and runs it in a
background Web Worker, so the page stays responsive. For each file it calls
imageCompression(file, { maxSizeMB, maxWidthOrHeight, useWebWorker: true }).
The library first downscales the image so its longest side fits your pixel cap,
then iteratively re-encodes at decreasing quality until the result is at or below
your target size. The original format is preserved, and each result shows the
before/after size and percentage saved.
Example
A 4.2 MB, 4032×3024 phone photo for a blog post: set Target max size to 1 MB and Max width/height to 1920. The tool downscales to 1920×1440 and re-encodes, producing roughly a 0.8 MB JPG — about a −81% saving — with no visible loss at blog display size.
| Use case | Target size | Max dimension |
|---|---|---|
| Email attachment | 1–2 MB | 2048 px |
| Website hero / blog | 0.2–0.5 MB | 1920 px |
| Thumbnail / avatar | 0.05–0.1 MB | 512 px |
Compression happens locally, so it’s fast and your images are never sent to a server.