Optimize
Compress Image
Upload a JPG, PNG, or WebP and compress it by quality percentage or target file size. Before/after size comparison shown.
Input formats
Output formats
Common uses
- Reduce image size for email attachments
- Optimize website images for faster loading
- Compress product photos for online stores
- Prepare images for form uploads with size limits
Limitations
- PNG compression uses lossless rewrite; visible quality reduction requires converting to JPG.
- Very low target sizes may produce visually poor results.
- Browser canvas compression may differ from server-side encoding.
Quality slider vs. target-size mode
This tool gives you two ways to shrink a file, and they suit different goals. Quality mode shows a slider from 5 to 95 (it opens at 82): you set a quality level and accept whatever file size results. It is the right choice when visual fidelity matters more than hitting an exact number, since you can nudge the slider and watch the before/after sizes on the result screen.
Target-size mode flips the priority. You pick a preset of 20 KB, 50 KB, 100 KB, 200 KB, 500 KB, or 1 MB, or type a custom value in KB, and the tool searches for the highest quality that still lands under that ceiling. This is built for hard limits, like a portal that rejects anything over 100 KB. If the image content genuinely cannot be squeezed below your target, you will see a clear message rather than a silently broken file.
In both modes you can keep the input format or force the output to JPG, PNG, or WebP. Forcing WebP often beats JPG at the same quality, and forcing JPG is the practical way to make a large PNG actually shrink.
Why PNG behaves differently from JPG
PNG is a lossless format, so when you compress a PNG and keep it as PNG, the tool can only rewrite it more efficiently, not discard detail. For photographs and screenshots with gradients, that rewrite frequently saves very little. If your PNG barely shrinks, that is expected behavior, not a failure of the tool.
The fix is usually to change the output format. Set the output to JPG (or WebP) and a photographic PNG can drop dramatically in size, because those formats are allowed to throw away detail the eye rarely notices. The trade-off is transparency: JPG has no alpha channel, so a PNG with a transparent background will gain a solid background once converted. Keep PNG output for logos, line art, and anything that needs transparency; switch to JPG or WebP for photos.
Local processing, limits, and practical tips
Compression runs entirely in your browser using the Canvas API. Your image is decoded, re-encoded, and the result is handed back to you on the same page; the file is never sent to a server. That means you can compress private screenshots, ID photos, or product shots without them leaving your device, and it also means speed depends on your own machine and the image's pixel dimensions.
The dropzone accepts JPG, PNG, and WebP up to 30 MB, and processes one image at a time. Because this is browser canvas encoding, the exact bytes can differ slightly from a server-side compressor or a desktop app; treat target sizes as close approximations rather than guarantees down to the last kilobyte.
For best results, start in quality mode around the default and only drop lower if the file is still too big. Pushing very low quality or a very small target can introduce visible blockiness and color banding, so check the preview before you rely on the output. If you also need fewer pixels, resize the image first, then compress, the two steps together cut size far more than either alone.
Frequently asked questions
Preset targets include 20 KB, 50 KB, 100 KB, 200 KB, 500 KB, and 1 MB. You can also set a custom target size.
Yes. Image compression runs locally using the browser Canvas API. Files are never uploaded.
This tool compresses one image at a time. Upload an image, adjust the quality or target size, and download the result — then repeat for the next image.