How to compress an image
- Choose an image by clicking the box or dragging a file onto it. JPG, PNG and WebP files are supported.
- Pick an output format and quality. The compressed version and its file size appear within a second or two. Adjust the quality slider and watch the size change.
- Compare the two previews. Zoom in on detailed areas — faces, text, edges — to check the quality is acceptable.
- Download the compressed image. Your original file is not changed.
What this tool does
The Image Compressor re-encodes your picture at a lower quality setting (and, optionally, a smaller width) to reduce its file size. Smaller images load faster on websites, fit within email attachment limits, upload more quickly, and are accepted by forms that cap file sizes at, say, 1 MB or 200 KB.
Everything happens inside your browser using the built-in canvas feature that every modern browser provides. The image is never uploaded — not to us and not to any third-party service — so it is safe to use for personal photos, ID scans and unpublished work.
How compression works
Image file size depends mainly on two things: the number of pixels, and how efficiently those pixels are encoded. This tool gives you control over both.
- JPEG uses lossy compression designed for photographs. It discards fine detail that the eye is least likely to notice. At quality 70–80, most photos look almost identical to the original at a fraction of the size.
- WebP is a newer format supported by all current major browsers. It usually produces smaller files than JPEG at similar visual quality and also supports transparency.
- PNG is lossless: it keeps every pixel exactly, so the quality slider does not apply. It is ideal for screenshots, logos and graphics with sharp edges, but it is often much larger than JPEG or WebP for photographs.
When you convert an image with a transparent background to JPEG, which does not support transparency, transparent areas are filled with white.
Why is the compressed file sometimes bigger? If the original was already heavily compressed, re-encoding it at high quality can add data rather than remove it. PNG output from a photo is also often larger. When this happens the tool tells you — lower the quality, switch to WebP or JPEG, or simply keep the original.
Photos taken on phones often include hidden metadata such as the camera model and sometimes the GPS location. Re-encoding through the canvas removes this metadata from the compressed copy, which is a useful privacy bonus when sharing photos online.
Examples
| Starting image | Good setting | What to expect |
|---|---|---|
| 12-megapixel phone photo for a blog | WebP or JPEG, quality 75, max width 1600 | Typically a large reduction — often from several MB to a few hundred KB |
| Product photo for an online shop | JPEG or WebP, quality 80–85 | Detail stays crisp for zooming |
| Screenshot with text | PNG, or WebP at quality 90+ | Text stays sharp; avoid low-quality JPEG |
| Photo for a form with a 200 KB limit | JPEG, quality 60–70, max width 1200 | Lower the quality in small steps until it fits |
Results vary with image content: busy, detailed photos compress less than simple scenes with smooth areas.
Tips for the best results
- Resize before you compress. A 4000-pixel-wide photo shown 800 pixels wide on a website wastes most of its data. Set a maximum width here, or use the Image Resizer for exact dimensions.
- Compress from the original. Each round of lossy compression loses a little more detail. Keep your original and always compress from it.
- Choose the format for the content. Photos → WebP or JPEG. Logos, icons and screenshots → PNG or high-quality WebP.
- Name files clearly. Descriptive, lowercase file names help when you publish images online — the Slug Generator can turn a description into a clean file name.
Our in-depth guide, How to Compress Images Without Losing Too Much Quality, explains lossy vs lossless compression, dimension vs file size, and a step-by-step workflow for websites and email.
Frequently asked questions
Are my images uploaded to a server?
No. Compression happens entirely in your browser. The image never leaves your device, and nothing is stored after you close the page.
What quality setting should I use?
For most photos, 70–80 gives a big size reduction with little visible difference. Go lower only if you must meet a strict size limit, and check the preview for blurriness or blocky patches.
Why does the quality slider do nothing for PNG?
PNG is a lossless format, so it has no quality setting — every pixel is preserved. To make a PNG smaller, reduce its dimensions or convert it to WebP.
Is there a file size limit?
There is no fixed limit, but very large images (over roughly 50 megapixels) may be slow or fail on phones with limited memory. Scaling the width down helps.
Does compression remove location data from photos?
Yes. The compressed copy is re-drawn from pixels only, so EXIF metadata such as GPS location and camera details is not included. Your original file is not changed.
Last updated . Spotted a mistake? Let us know and we will correct it.