Every application portal, exam system and government site seems to have a different KB limit. Finding the right combination of quality and dimensions to hit that exact number by hand takes many attempts. This tool automates the search: you set the target, it finds the setting that works, and you download the result.
The whole process runs locally. Your browser reads the image from disk, compresses it using the Canvas API, and hands the output back as a file download. No upload, no account, no limit on how many images you process. The tool is equally useful on a desktop browser or a mobile browser when you need to resize an image before uploading to a portal.
KB resize: what the number on a form really means
When a portal says 'maximum 150 KB', it means the finished file must occupy no more than 153,600 bytes on disk. That number has nothing to do with how wide or tall the picture looks on screen — a tiny thumbnail and a large display image can both be 150 KB depending on how aggressively the data has been compressed.
Most phones produce images between 2 MB and 8 MB. Dividing 2 MB by 150 KB gives roughly a 13× reduction. You cannot reach that by renaming the file or changing its extension. You have to discard pixel data, either by lowering the quality setting, by reducing the pixel dimensions, or by doing both together.
This tool works through both levers automatically. You type the target KB, load the image, and it finds a combination of quality and dimensions that lands at or just below your number. The preview shows you the output size and the pixel dimensions before you commit to the download.
Step-by-step: how to do a KB resize in this tool
First, set the KB target. The field accepts any number from 5 to 5,000. For most portals the number is between 50 and 500. Type the exact number the form states, then subtract ten to give yourself a small margin against rounding differences between browsers.
Second, load the image. Use the file picker or drag the file onto the page. The tool reads the image directly from your disk into the browser — no upload happens at this point. You will see the original dimensions and original file size straight away.
Third, check the preview and download. The compressed result appears side by side with the original. If the quality looks acceptable, click download. If you want to experiment, change the target and the page reprocesses immediately. Each run is independent; no data is retained.
Choosing the right KB target for your situation
Government identity portals and exam systems often set limits between 20 KB and 100 KB. These tight limits come from legacy upload pipelines that were designed when storage was expensive. To hit 30 KB from a modern phone image, the tool will reduce both dimensions and quality significantly — inspect the preview carefully to make sure the face or document is still readable.
Job application sites and HR portals usually allow 100 KB to 300 KB. This range is comfortable: the tool can reach it with a quality reduction alone on most images, keeping dimensions largely intact. The result tends to look very close to the original at the sizes portals display photos.
Email and messaging uploads often have a 500 KB to 1 MB ceiling. For these, a light quality pass is all that is needed. Set 400 KB and the result will be well within range while retaining sharp detail.
Why two images at the same KB can look very different
Subject matter matters enormously. A portrait against a white wall has little colour variety, so JPEG can describe it with very few bytes at high quality. A busy street scene with thousands of fine textures needs many more bytes to look sharp at the same dimensions. Both files might be 100 KB, but the portrait looks crisp while the street scene looks soft.
The starting resolution also matters. A 4,000 × 3,000 pixel image needs more reduction to reach 100 KB than a 1,500 × 1,000 pixel image. If you have the option to capture the photo at a lower resolution in the first place, that gives the compressor more room to preserve quality.
Format plays a role too. PNG with a transparency layer is fundamentally different from JPEG. When you give the tool a PNG, it converts to JPEG for the compressed output, which is the format that the vast majority of portals accept and the format that reaches small file sizes most efficiently.
The algorithm behind KB-targeted compression
The tool uses a binary-search loop over the JPEG quality parameter, which ranges from 1 to 100. It starts at quality 80, encodes the image, checks the byte count, and adjusts upward or downward. This converges on the largest quality value that keeps the output below the target in about seven to ten iterations.
If the quality floor (roughly quality 35 for most images) still produces a file over the target, the tool scales down the pixel dimensions by a factor and restarts the search. It continues halving the scale until the image fits. The minimum output size is constrained so that the result still makes sense as a form photo.
This approach is different from simple percentage sliders. Sliders cannot guarantee a specific byte count because the relationship between quality and file size depends on the image content. The binary-search approach is guaranteed to land at or below the target for any input.
Reading the numbers in the preview panel
The preview shows four numbers: original KB, compressed KB, original pixel dimensions and compressed pixel dimensions. If the compressed KB is well below the target, you may be able to raise the target a little and get a better-looking result. If dimensions have dropped by more than half, consider whether the portal requires a minimum pixel size.
The percentage saved figure tells you how much data was removed. A saving of 70% or more on a phone image is common and expected. A saving of only 10 to 20% on an image that was already compressed before you loaded it is also normal — a previously compressed JPEG has little redundancy left to remove.
The aspect ratio is preserved. The tool never crops. If a portal wants a 3:4 crop for a passport photo, do the crop in a separate editor first, then run the result through this tool for the KB resize.
Common KB resize errors and how to fix them
Portal says 'file too large' after upload: the portal may measure in a different unit — some label in KB but mean KiB, or say 'KB' when they count the base-64 encoded size for an old API. Try subtracting another 10 KB from your target and re-run.
Portal says 'dimensions too small': the aggressive resize needed to hit a very low target has brought the image below the portal's minimum, such as 300 × 400 pixels. Raise the KB target until the preview shows dimensions above the minimum. If the portal limit is very tight, you may need to start from a higher-resolution source.
Downloaded file is named with a number suffix: that is normal browser behaviour when a file with the same name already exists in your downloads folder. The file itself is correct. Rename it before uploading if the portal checks the filename.
Output looks posterised or blocky: the target is very low and the source image has a lot of fine detail. Try raising the target by 20 KB. If the portal strictly forbids it, start from a simpler source image with less background texture.
KB resize for different image types
Portrait photographs compress well because large uniform areas like skin, sky and walls store very cheaply. A 300 KB portrait can usually reach 80 KB without visible quality loss at form sizes. Use a plain, evenly lit background for the best result.
Document scans and screenshots are trickier. Text and fine lines require high frequency data, which JPEG discards at low quality settings. If the scan must remain legible, do not push below 50 KB for a standard A4 scan at 200 DPI. For receipts and ID cards, check the text is readable in the preview before downloading.
Product images for marketplaces often have white backgrounds. These compress very efficiently. A 1,000 × 1,000 pixel product shot can often reach 80 KB at quality 85. If the background is not pure white, use an editor to set it to pure white first — it removes colour noise that inflates the file.
Batch KB resizing: how to handle multiple files
This tool processes one file at a time, which suits identity documents and application photos. For each file, set the target, preview the result and download before moving to the next. Give each output a clear name such as 'cv-photo-200kb.jpg' so you can locate the right file quickly.
If you have many product images or gallery photos to resize, a desktop batch tool will be faster. However, for one-off tasks — a job application, an exam registration — the browser approach is quicker than installing and learning a new application.
If you process the same type of image regularly, note your working target KB and the typical output quality. The next time you need to resize, you can go straight to that target and skip the trial-and-error step.
Privacy and security when resizing identity images
Photos for portals are often passport pictures, ID cards, signatures and salary slips — data you should not hand to an unknown server. This tool runs entirely in your browser. When you load an image, the browser reads the file from your disk using the File API. The compressed output is generated by the Canvas API inside the browser tab. No network request is made.
You can verify this. Open the browser DevTools (F12 on most browsers), switch to the Network tab, and run a compression. The tab will show no outbound HTTP requests beyond the page assets already loaded. The file never leaves your machine.
After you close the browser tab, nothing persists. No cache, no session storage, no service worker caches your image. The next person who opens the same computer and visits the site sees a blank tool with no trace of your file.