How to compress an image to 20 KB or 50 KB for online forms
By DuoTools · Published · Updated
A portal asks for a photo smaller than 20 KB. Your phone saved a file several times that size, and the form also specifies JPG and a minimum width. You have three checks to make: file size, file format, and pixel dimensions. Meeting one does not tell you whether the other two pass. This walkthrough shows how to satisfy those requirements and how to decide when an image has become too small to use.
Read the complete upload requirement
Record the limits before changing the image
Write down the largest permitted file size, the accepted extensions, and any pixel or aspect ratio requirement. A form might ask for a square image, a particular width and height, or a photo with a plain background. These are instructions for that form. An image can satisfy every compression setting and still be unsuitable if the subject is cropped incorrectly or the background fails the portal’s rules.
Check whether the site says “under 50 KB” or gives a range such as “10 KB to 20 KB.” DuoTools checks for an output strictly below the selected maximum. At 20 KB, its limit is 20,000 bytes. A result of 9,800 bytes is within that maximum but below the minimum in the second example. Verify both ends of a range yourself. The compressor does not add bytes to reach an exact size.
If the instructions say JPEG, choose JPG output. The two extensions usually refer to the same image format, but a portal can apply an extension rule of its own. Choose the correct format in the tool and keep the exported extension. Renaming a PNG file to JPG does not convert its contents.
Choose settings for the type of image
Open the DuoTools Image Compressor and select your original. Choose the 20 KB or 50 KB preset, or enter the portal’s maximum in the custom field. If the destination accepts only JPEG, set the output to JPG. If it permits multiple formats, the choice depends on what the image contains and what the recipient can open.
For a photograph, try JPG first when the portal requires or recommends it. For a logo or signature with a transparent background, PNG or WebP can retain transparent pixels if the destination supports the format. When you export a transparent image to JPG, the chosen background color replaces transparency. Look for faint strokes that disappear against that color and for unwanted solid areas around the subject.
Start with one image so you can review the result before repeating the settings on a batch. A setting that works for a simple portrait may fail on a page with detailed graphics. Fine edges and textured backgrounds can take more data to represent. Two pictures with identical dimensions can therefore produce different output sizes at the same quality setting.
Work through a form with two limits
Example with a 20 KB maximum and a minimum width of 300 pixels
Suppose a form asks for a JPG portrait under 20 KB and at least 300 pixels wide. You start with a portrait measuring 900 × 1,200 pixels. In the compressor’s target-size controls, choose 20 KB and JPG. Generate a result, then read the output dimensions and exact byte count. For this example, imagine that the result is 19,200 bytes and 360 × 480 pixels. That meets both stated limits.
Now imagine the output is 17,900 bytes and 270 × 360 pixels. The file fits the byte limit, but the width is 30 pixels below the minimum. Return to the original and try a maximum-edge setting that keeps the initial image wide enough. If further dimension reduction takes it below the required width, turn that option off for the next attempt. This can leave the compressor unable to reach the byte limit. The form's size and dimension requirements still apply even when a setting prevents further reduction.
You could crop away excess background first if the form allows it, while preserving the required framing and aspect ratio. A cleaner original can also make the result easier to recognize at the same size. If the portal accepts 50 KB instead, select the 50 KB preset and repeat the checks. The figures above illustrate the decision process. Actual output depends on the source image and settings.
Review the output before you submit
Compare the preview with the original. Look at eyes and facial edges for a portrait, the smallest strokes for a signature, and small characters for a document image. Open the downloaded file separately as well. A preview displayed at a small size can hide defects that become obvious in the portal’s own viewer or when the recipient zooms in.
If you need another attempt, start from the original. Repeatedly saving the same JPG can add visible artifacts, especially near sharp edges. Keep the portal-ready copy under a filename that identifies the destination or limit so it is easy to distinguish from the original.
DuoTools processes the selected image in your browser. The destination portal receives whichever file you upload there. Check that you have selected the compressed copy and review the portal’s own instructions for handling personal documents before sending it.
A few things you might wonder
Why does my file manager show a rounded size?
File managers may round or use a different definition of KB. Use the exact byte count when the upload limit is strict, and check the destination’s requirements.
What if no setting gives me a clear image under the limit?
Try a cleaner original, a permitted crop, or another accepted output format. If the form requires both a very small file and dimensions your result cannot meet, check its instructions or ask the receiving organization for a suitable option.
Can I make an image exactly 50 KB?
The preset checks a maximum. It may produce a file substantially smaller than 50 KB, so it is best suited to a size cap.