N

Runs in your browser · nothing is uploaded

Image Compressor to Target Size

Shrink JPG, PNG and WebP images under a size limit — like 100 KB for a form upload — with the exact byte size shown and an honest warning if a target can't be met.

How it reaches the target

  1. The image is fitted inside your max width and height (never enlarged).
  2. JPEG/WebP: it tries high quality first, then binary-searches for the highest quality that fits.
  3. If the lowest acceptable quality is still too big and resizing is allowed, the dimensions shrink by the square root of the overshoot and the search repeats.
  4. PNG: lossless optimisation with oxipng, then resizing if allowed.

Worked example

A 3.2 MB phone photo with a 200 KB target and 1 KB = 1,000 bytes must end up at no more than 200,000 bytes. At full resolution even low quality is too big, so it's scaled down, then the highest quality that fits is kept — and the list shows the actual size, dimensions and quality used.

Frequently asked questions

How do I compress an image to 100 KB?+

Enter 100 KB as the target, add your images and press Compress. For JPEG and WebP the quality is lowered step by step until the file fits; if even low quality is too big, the dimensions are reduced too (you can turn that off). The result shows the exact byte size.

Is 1 KB 1,000 or 1,024 bytes?+

Both are used. Choose which with the switch — by default 1 KB = 1,000 bytes, which is the stricter limit: a file under 100,000 bytes is under 100 KB either way.

Can PNG files be compressed to a target size?+

Only partly. PNG is lossless, so there's no quality setting. The tool re-compresses it with oxipng, which shrinks the file without changing a pixel. If that still isn't small enough, it can reduce the dimensions — or you can save as JPEG or WebP instead.

What if my target can't be reached?+

You'll see a clear warning and the smallest version it managed, so you can decide what to do — allow resizing, choose a smaller format, or pick a bigger target. It never claims a target was met when it wasn't.

What happens to transparency?+

PNG and WebP keep it. JPEG can't store transparency, so transparent areas are filled with the background colour you pick.

Are my images uploaded?+

No. They're decoded and re-encoded in a background worker in your browser. Photo orientation is applied, and EXIF details such as camera and location aren't copied into the new file.