Compress Image to 20KB

Shrink any JPG, PNG or WebP photo to an exact 20KB target (or 50KB, 100KB, 200KB, or your own size) for strict upload forms. Free, no sign-up, and everything runs in your browser.

Drop your image here or click to browse
JPG, PNG or WebP. The compressed output is a .jpg file
or

Your file never leaves your browser

Compression is done locally with the Canvas API. No upload, no account, no watermark.

Drop an image to compress it to 20KB.
Compressed image preview

How the 20KB image compressor works

Most image compressors give you a quality slider and leave you to guess where the file size lands. This tool works the other way round: you set the target in kilobytes and it finds the answer. Your image is drawn onto an in-browser canvas, re-encoded as JPEG at a trial quality, and the resulting byte count is measured. A binary search then narrows in on the highest quality that still fits under your target, usually within a dozen encodes and a few seconds.

If even the lowest JPEG quality at full resolution is too big for the target, the tool steps the dimensions down (75% at a time) and searches again. That is how a 4MB phone photo becomes a 20KB upload: mostly through smarter quality selection, with downscaling only as a fallback. The result panel shows the exact before and after sizes, the final dimensions, and the encoder quality used, so there are no surprises.

Everything happens on your device with the Canvas API. The image is never uploaded, which also means the tool works offline once the page has loaded, and there is no queue, no daily limit and no watermark.

Tips for best results

SituationWhat to do
Portal rejects files over 20KBUse the default 20KB target. The output is guaranteed at or under the limit, or the tool tells you
Result looks too softTry the 50KB or 100KB preset if the form allows it; even a small size increase buys visible sharpness
Transparent PNGTransparency is flattened onto a white background, since the output is JPEG
Very large photo (10MP+)Nothing needed. Dimensions are reduced automatically only if quality alone cannot reach the target
Need an exact odd size like 35KBType it into the custom KB box and press Enter

Frequently asked questions

Why would I need an image under 20KB?

Many government portals, job application forms, exam registrations, visa systems and HR tools reject photos above a strict limit, and 20KB is one of the most common caps. This tool keeps adjusting quality (and dimensions if needed) until the file fits.

Does compressing to 20KB lose quality?

Yes, honestly it does. Reaching an exact byte target means lossy JPEG re-encoding, and 20KB is small. The tool always uses the highest quality that still fits and only shrinks dimensions when needed. Keep your original file.

Which formats are supported?

Drop in JPG, PNG or WebP. The compressed output is always a .jpg, because JPEG is the format that can reliably hit very small byte targets. Transparent backgrounds are flattened onto white.

Is my image uploaded anywhere?

No. Compression happens 100% in your browser with the Canvas API. You can disconnect from the internet after the page loads and it will still work.

What if my image cannot reach 20KB?

Rare, but possible for extremely detailed images. The tool tells you honestly and gives you the smallest file it could produce instead of silently failing.

Related tools