What 20 KB looks like
Twenty kilobytes is small. A full-size phone photo cannot fit in it by lowering quality alone, and the table shows how the tool copes. The test photo went from 694 KB to 20 KB. The search reached JPEG quality 32, the lowest it will go, and then scaled the picture from 2000 x 1333 down to 1269 x 846 to get under the limit.
Under 20 KB, detail goes first. Faces and large shapes hold up; fine text, hair and foliage turn soft. That is a property of the size, not of the tool.
| Test image | Original | Result | JPEG quality | Pixels | Time |
|---|---|---|---|---|---|
| Photo | 694 KB | 20 KB | 32 | 1269 x 846 (from 2000 x 1333) | 1.8 s |
| 12 MP photo | 1.81 MB | 20 KB | 33 | 1238 x 825 (from 4000 x 2667) | 4.2 s |
| Screenshot | 46 KB | 20 KB | 32 | 1378 x 775 (from 1600 x 900) | 1.1 s |
| Illustration | 94 KB | 20 KB | 60 | 1200 x 1200 | 1.1 s |
Test images are synthetic files made by this project: a 2000 x 1333 landscape photo, a 1600 x 900 interface screenshot and a 1200 x 1200 transparent illustration. The 12 MP photo is the same photo scaled up to 4000 x 2667, the size a phone camera saves. Quality is lowered first and the image is only scaled down when quality alone cannot reach the target. A JPEG that is already under the target is left as it is. Timings: one thread of WebAssembly on Node v22.23.4, Intel(R) Xeon(R) Processor @ 2.10GHz, 2 cores, measured 2026-10-31. Other devices will differ.
Start from a small picture
The best 20 KB photo starts out small. If a form wants a passport-style photo or a signature, trim the picture to that area with the crop tool and set a pixel size with resize before you compress. A 200 x 230 pixel face crop has far more bytes per pixel to work with than a 2000 pixel photo squeezed down to the same file size, so it keeps its quality.
Signatures and scans
A scanned signature is mostly white paper with thin dark lines, and JPEG handles that well when the scan is a few hundred pixels wide. Keep the background colour white. It fills any transparent area before the JPEG is made, so you do not end up with black patches.
If it will not fit
When the target cannot be reached, the tool shows the smallest file it could make and says so. Reduce the pixel size, or crop closer to the subject, and run it again. Lossless formats such as PNG can only reach a size target by shrinking the picture, so JPEG is the better choice at this size.
How the tool reaches 20 KB
- It first encodes at the lowest quality it allows, 32, to see whether the size can be reached at all.
- If it can, it searches between quality 32 and 95 for the highest quality that still fits.
- If it cannot, it scales the picture down by a calculated step and tries again, for up to ten rounds, and never goes below 24 pixels on the short side.
- It then reports the quality, the pixel size and the final size, so you can see what was traded.
The test photo needed 8 encodes and 1.8 s on a single thread. Searching with a few encodes keeps the wait short, even for large pictures.
Questions
Does 20 KB mean 20,000 or 20,480 bytes?
This tool counts 1 KB as 1000 bytes. A result under 20 KB is below 20,000 bytes, so it also fits a limit measured in 1024s.
Why is my picture smaller than the original?
Quality reached its floor and the tool then reduced the pixel size. It never enlarges, so it stops at the first size that fits.
Can I get a PNG under 20 KB?
Only by shrinking the pixels a lot. Use JPEG for photos at this size.
Is my photo uploaded?
No. It stays in this browser tab.