Home » Guides & How-Tos » Compress an Image to an Exact Size in KB

How to Compress an Image to an Exact Size in KB

By Aurang Zeb Loona — Loona Automation

Most compression advice stops at "make the file smaller". Real life is more specific than that: a job portal wants your photograph at 200KB or less, a signature scan at 20KB, a document upload somewhere under 300KB, a marketplace image below 1MB. The target changes from form to form, and guessing with a quality slider until the number happens to fit is slow and unreliable. This guide explains the three levers that control an image's file size, shows a worked example of hitting an exact target, and lists the mistakes that make people miss.

The Three Levers That Control File Size

An image file's size is decided by three things, and understanding them turns compression from luck into arithmetic:

Used in the right order — shrink dimensions first, pick the right format, then fine-tune quality — almost any reasonable target is reachable without wrecking the picture.

A Worked Example: 5.2 MB Down to a 200KB Target

Suppose a job portal asks for a scanned certificate "no larger than 200KB", and your scan is a 6000 × 4000 pixel JPG of 5.2 MB. Watch the levers work in sequence. First, the scan is resized to 1600 × 1067 pixels — still more than enough to read every word on screen or in print at A4 width — which by itself brings the file down to roughly 700KB–900KB. Second, it is saved as JPG (it already is; a PNG version of the same scan would be several megabytes larger). Third, the quality is fine-tuned: at quality 85 the file might read about 260KB, still too big; at quality 78 it lands around 195KB — under the target, with a small safety margin, and the text still crisp. A compress-to-target tool does this last step automatically, testing quality settings until the file fits just under the number you gave it. That is the whole method: big cuts from dimensions, then small, precise cuts from quality.

Step-by-Step with a Free Tool

  1. Work from the original file — the camera photo or first scan, never a copy that has already been through a messaging app.
  2. Crop to the subject. Cut away empty borders and background the form does not need.
  3. Open the Loona Image Compressor and add your image. It runs in your browser, so the file never leaves your device.
  4. Enter your exact target in KB (for example 200) rather than dragging a quality slider and hoping.
  5. Compress and inspect the result at full size — zoom into a face or a line of text. If it is not readable, resize less aggressively and compress again from the original.
  6. Verify the final size in the file's properties before uploading, aiming a few KB under the stated limit.

Common Mistakes

Frequently Asked Questions

Can any image be compressed to any size?

Almost — but with a trade-off that steepens at extremes. A detailed group photograph forced to 20KB will look poor at any settings, because there is a floor below which the data simply is not there. For very small targets, resize more (the form only displays a small picture anyway) rather than crushing quality further.

Some forms also set a minimum size. How do I make a file bigger?

A few systems reject files that are too small, suspecting a fake or a thumbnail. Re-saving rarely helps honestly — the right fix is to go back to the source: scan at a higher resolution, or use the original uncropped photo, so the larger file contains real detail rather than padding.

Why do two tools give different sizes for the same image and quality?

"Quality 80" is not a universal unit — each encoder interprets the scale differently and makes different choices about colour detail. This is exactly why aiming at a target size, and then verifying the result, beats trusting a slider.

Does compressing an image change its dimensions?

No. Compression changes the file size; resizing changes the dimensions. They are separate operations, and confusing them is why some people end up with a small file whose dimensions a form still rejects — check both requirements every time.

Put the method to work with the free Loona Image Compressor — set any target from 20KB upward, process up to 100 images at once, and keep every file on your own device. For the specific case of application-form photographs, see also our guide to compressing an image to 50KB.