Try it now —no sign-up needed
100% free, browser-based, your files never leave your device.
Start with the receiving website's requirements
A smaller file is useful only if its format, dimensions, and detail still meet your needs. Before using ToolKnit's image compressor, check the upload website's maximum size, minimum pixel dimensions, and accepted formats. Keep the original image.
Choose Compress to a target size for a maximum such as 100 KB, 200 KB, or 500 KB per image. Choose Smart compression and a Low, Medium, or High preset when you want a smaller file without a fixed size requirement.
How to compress an image to a target size
- Add your images. JPG, PNG, WebP, GIF, and BMP inputs are supported, subject to the file and pixel limits below.
- Select Compress to a target size. Pick a preset or enter a maximum from 20 KB to 20 MB. The same maximum applies to each image separately.
- Choose whether to allow WebP. Leave Smart smaller format off if the destination requires the original JPG or PNG format. Turn it on only if WebP is accepted.
- Run compression. For JPG and WebP, the tool searches encoding quality first. If that is insufficient, it reduces pixel dimensions proportionally. PNG may also need smaller dimensions to meet a tight limit.
- Review and download. Check the actual size, dimensions, format, and appearance. Only successful target-size results enter the download or ZIP.
KB is not always counted the same way. ToolKnit uses 1 KB = 1,024 bytes and 1 MB = 1,048,576 bytes. If an upload form enforces 100,000 bytes, select a slightly smaller target such as 97 KB. A target is a maximum, not an exact final size.
What happens to JPG, PNG, WebP, and GIF?
- JPG: target mode keeps JPG unless you enable WebP. Lower quality or fewer pixels can remove fine detail.
- PNG: target mode keeps PNG by default and retains transparency. It may reduce dimensions. PNG's lossless file encoding does not make resizing a lossless operation.
- WebP: target mode uses WebP when the browser supports encoding it. Check that the receiving site accepts the format.
- Animated GIF: frames are preserved by keeping the original file. If it exceeds the selected maximum, it is reported as unsuccessful and excluded from target downloads.
- Static GIF and BMP: target mode uses PNG, or WebP when you opt in and the browser supports it.
Smart compression has different format rules: an opaque PNG can become JPG. Transparent PNGs keep transparency, but Medium and High can reduce image detail through resampling. Neither mode guarantees an unchanged appearance.
Batch, file size, and pixel limits
Add up to 30 images, with a maximum of 20 MB per file and 100 MB of input files per batch. Decoded pixels also consume memory, even when a file is small on disk.
Mobile, touch, and other constrained devices allow up to 10 megapixels per image and 40 megapixels per batch. Other supported devices allow up to 24 megapixels per image and 100 megapixels per batch. The tool reports files that exceed the active limits. If needed, resize the source image before returning here.
A 100 KB target applies to each successful image. A ZIP containing ten images is not limited to 100 KB in total; it contains their combined data plus archive overhead.
Why an image may not get smaller
A file already below the target is returned unchanged, even if a different format or resize option is selected. Smart compression also retains the original when a re-encoded version would be as large or larger. An already optimized file may therefore show 0% savings.
A target that cannot be met within the available quality and dimension settings is reported as a failure. Increase the allowed maximum or reconsider the destination's dimension requirements instead of assuming that a tiny file is still suitable.
Check an example before processing a batch
Try a non-confidential photo at a 100 KB target. Compare its dimensions and fine detail with the original. Next, try a transparent PNG and inspect its edges on a contrasting background. Finally, include an animated GIF larger than the target: it should be excluded rather than silently reduced to one frame. Results vary with image content and browser encoding.
A measured example
In a local Chrome 152 check on September 16, 2026, a generated 1600 × 1200 JPG test pattern went from 1,326,555 bytes to 100,453 bytes at a 100 KB target (102,400 bytes). Its output measured 844 × 633 pixels: the size limit required fewer pixels.
A transparent PNG test pattern kept its transparency and PNG format, but shrank from 800 × 600 to 184 × 138 pixels to meet the same limit. A 377-byte PNG was returned byte-for-byte unchanged. A two-frame GIF above a 20 KB target was reported as unsuccessful and offered no compressed download.
These synthetic checks show the trade-offs, not typical savings. Inspect your image at its intended display or print size before using the result.
Frequently asked questions
Can every image become 20 KB without losing quality?
No. Very small limits can require fewer pixels or lower quality, and some files cannot meet the selected limit. Successful target downloads are checked for size, not for whether the image remains suitable for your task.
Does the tool offer a quality percentage slider?
Smart mode offers three quality presets. Target mode offers a size slider and custom KB or MB input; it chooses encoding settings automatically.
Are my images uploaded?
The selected image files are processed in your browser. Website analytics are separate from image processing; read the privacy policy for details.
Related image workflows
- Crop an image to remove unnecessary borders before compression.
- Convert PNG to WebP when changing format is your main task.
- Combine images into a PDF for a document upload.
- Compress the resulting PDF if the destination limits the document size.