Compress Image to a Target KB

–original → compressed
TargetFitsTypical use
30 KBtiny form caps, old forum limitsavatar, signature
100 KBmost "under 100 KB" upload gatesprofile photo, blog inline
200 KBfast-loading page imageshero, product shot
500 KBmarketplace and portal uploadslisting photo, resume headshot
The squeeze loop: the image is redrawn to canvas at full size and encoded to JPEG at high quality; if the blob exceeds your target the quality drops a step, and only after quality bottoms out do the pixel dimensions shrink 20% at a time - sharpness first, size last. Output is JPG, so transparent PNG areas turn white (the canvas has no alpha in JPEG); everything happens in this tab and the file never leaves your device.

Choose a target size, drop in a photo, and this page hands back a JPEG that lands under it - not roughly under, exactly under, because the encoder iterates quality and dimensions until the blob fits with quality as high as the budget allows. A 3 MB phone photo compresses to under 100 KB in about a fifth of a second, right in this browser tab.

The order of operations is the difference between a passable result and an ugly one: quality drops first (in small steps, from 0.85 down), and pixel dimensions shrink last - 20% at a time, only after quality bottoms out. That is why faces stay sharp and text stays legible at sizes that naive resizers turn to mush.

How to use

  1. Pick your target with the size chips - 30 KB for strict form caps, 100 KB for most upload gates, 500 KB for marketplace listings.
  2. Pick your image (JPG, PNG or WebP - it is read locally and never uploaded); the compressed result appears with its before and after sizes.
  3. Download compressed .jpg when the preview looks right - the file name carries the target, like vacation-100kb.jpg.

Frequently asked questions

My PNG has a transparent background - what happens to it?

Transparent areas become white. The output is JPEG, which has no alpha channel; the canvas is filled white before encoding precisely so you get a white background instead of the black a bare encode would produce. If you need to keep transparency, the target-size job has no lossless answer - PNG at a fixed KB is a different trade-off.

Why is the result exactly under my target and not just close?

The encoder re-runs until the blob fits: quality steps down from 0.85 in small decrements, and only when quality bottoms out do the pixel dimensions shrink 20% at a time. The loop stops as soon as the size fits, so you keep the maximum quality - and dimensions - the target allows.

How small can an image actually get before it turns to soup?

It depends on content, not the tool: a busy landscape has no fat to trim, while a product on a white background compresses brutally well. As a rule of thumb a 4000-pixel phone photo reaches 100 KB around 1200 pixels wide with acceptable quality - if you need far smaller, expect the dimensions, not the sharpness, to give.

Is the photo uploaded anywhere?

No. The image is decoded, recompressed and previewed entirely inside this tab using the browser's canvas - nothing is transmitted, which makes it safe for ID scans, contracts and anything else with a size cap.

Related tools