Compress JPG to 20KB

Restricted to JPG/JPEG input, pre-set to a strict 20KB target — the exact combination most exam and government portals ask for.

Your files are processed locally in your browser and are never uploaded to our servers.

When a form specifically says "JPG or JPEG only, under 20KB," this is the direct tool for it — file type restricted to JPG/JPEG on the way in, target locked to 20KB by default, so there's no ambiguity about format or size.

How it works

  1. Add your JPG

    Only JPG/JPEG files are accepted here, matching what strict upload portals specify — the input restriction prevents an accidental PNG or WebP upload that a form would reject anyway.

  2. 20KB target is pre-selected

    The tool starts locked to the 20KB preset, matching the most common strict exam and government-form requirement, though you can still change it.

  3. Automatic quality search runs

    Quality is searched via binary search until the highest setting that still fits at or under 20KB is found.

  4. Download and submit

    The output is a JPG under 20KB, ready for the portal that requested it.

General compression tools ask you to choose a format and a size separately, which is unnecessary friction when a portal’s requirement is exactly “JPG, under 20KB” — a combination that shows up constantly across exam registrations, income-certificate portals, and other strict government-style upload forms. This tool skips the format decision entirely: input is restricted to JPG/JPEG, and the target starts at 20KB, matching the requirement directly.

How the 20KB search works

The underlying process is the same binary-search quality search used across this site’s compression tools: encode at a mid-range JPEG quality, check the actual byte output, adjust up or down, and repeat until the highest quality that still fits at or under 20KB is found. At 20KB specifically, the search usually converges on a noticeably lower quality percentage than looser targets like 50KB or 100KB, simply because there’s less byte budget to work with — that’s an inherent tradeoff of a tight size cap, not a limitation of the search itself.

Getting a clean result at a tight 20KB limit

The biggest lever at 20KB isn’t quality — it’s pixel dimensions. A 4000×3000px photo compressed down to 20KB has to spread that tiny budget across twelve million pixels, which looks noticeably worse than the same content resized to a smaller, purpose-appropriate resolution first. Most 20KB requirements implicitly expect a small photo (a passport-style headshot or signature, not a full scene), so resizing to roughly 200-400px on the long side before running this tool typically produces a visibly sharper result at the same byte ceiling.

When your form specifies both pixels and size

Some strict portals specify both an exact pixel size (like 200×230px) and a byte limit (like 20KB). Handle these in two passes: resize to the exact pixel dimensions first, then compress the resized file down to the byte limit. Doing it in this order — dimensions first, then size — respects both requirements precisely, rather than trying to satisfy them simultaneously in a way that risks missing one or the other.

Frequently asked questions

Why does this tool restrict input to JPG/JPEG only?

Many strict portals (exam board registrations, government ID uploads) specify JPG/JPEG explicitly and reject PNG or other formats outright, regardless of size. Restricting the input here matches that requirement directly, so you know upfront the source file type is already compliant, and only the size needs fixing.

Is 20KB enough for a recognizable photo?

For a small, simple image like a passport-style headshot or signature, yes — 20KB is a tight but workable budget for content with a limited amount of fine detail. For anything with more visual complexity, expect visible compression artifacts, since 20KB gives the encoder very little room to work with.

What's the single best thing I can do to improve a 20KB result?

Resize down first. A photo's byte budget at a fixed size target has to cover every pixel, so fewer pixels means more bytes available per pixel and a visibly cleaner result. A typical passport-photo requirement is roughly 200-400px on the long side — resizing to that range before compressing to 20KB produces a noticeably sharper result than compressing a full-size photo down hard.

My form says "20KB" but also gives pixel dimensions — do I need both tools?

Yes, run the Resize tool first to hit the exact pixel dimensions specified, then run this tool on the resized output to bring it under the byte limit — doing both in sequence, rather than trying to solve size and dimensions in one pass, gives the most predictable, spec-compliant result.

Can I loosen the 20KB target if my form allows more?

Yes — the target size field is editable even though it starts at 20KB, so you can raise it to 50KB or 100KB, or any custom value, without needing a different tool.