Image Compressor
Compress a JPEG, PNG or WebP and compare it side by side. Smart picks the quality, Quality takes a slider, Target searches for a size in KB. One file or a folder.
Picture
Your picture goes here, at a size worth judging, before anything is compressed.
Pictures
Drop pictures here
JPEG, PNG, WebP or AVIF — one picture, or a whole folder of them
—
—
Zoom
1:1 is where a re-encode is judged; at Fit the browser is resampling both sides anyway.
The queue
Of the original
You save
How much comes off depends on the picture: a screenshot can lose two thirds of its size, a photograph that was already compressed very little.
Getting a smaller file
- Drop pictures into the Pictures box, or a folder of them. On a phone, Take photo shoots one straight in, and Choose files opens the picker.
- Pick Smart, Quality or Target under Compression, and a Format if WebP is not what you want. Lower Max width if the picture is bigger than it needs to be.
- Press Compress. The picture turns into a before-and-after compare with the saving beside it. Drag the divider, or switch to 1:1 to judge it at its own pixels, then Download.
About this tool
A photo off a current phone lands somewhere around 4 to 6 MB, and a good number of upload boxes will refuse it flat. The image compressor re-encodes that file and gives you back something much lighter, and it shows you the two side by side before you take it. Compression has three settings. Smart is the default and asks nothing of you. Quality hands you a slider from 1 to 100. Target takes a budget in KB and works backwards from there.
Smart walks a fixed ladder of quality settings, 80 then 72, 65, 58, 50 and finally 42, and it stops at the first rung that produces a file smaller than what you gave it. That is the honest rule and it has an honest cost: a photo that was already squeezed can stop at 80 with a saving of 5%. When the saving comes in under 10%, the page says so and encodes one rung further down to tell you what quality 72 would weigh, and you decide with a number in front of you. Target is a binary search over quality 1 to 100 that keeps the highest setting still under your budget, and when no quality gets there it says the smallest size it reached.
The encoding runs in a worker on WebAssembly builds of MozJPEG and the WebP, AVIF and PNG encoders, so the page stays responsive and Cancel stops an encode at once. Once there is a result, moving the slider, typing a new width or picking another format re-encodes on its own, and the compare, the percentage and the removed-against-kept meter follow it. Max width and Max height start at the picture's own size, and shrinking them is resampled in the same worker. Drop several pictures, or a whole folder of them, and they become a queue: each row says what the file became, has its own Download, and Download all takes them together.
Good to know
- PNG is in the Format list, and it is lossless, so on a photograph it is not a compressor. Every quality comes back larger than the JPEG that went in, the original is kept, and the page tells you how much larger it would have been.
- AVIF is often the smallest and always the slowest to encode. On a large photo the run row appears with the quality being tried, and Cancel is beside it.
- Some images are already at their floor. When every rung of the ladder comes back bigger than the original, you keep the original and Download stays off, because there is no smaller file to hand over.
- A very small KB target on a full-resolution photo can be unreachable at any quality. You are told the smallest size it managed, and the fix is dimensional: lower Max width here, or shrink it properly in the Image Resizer first.
- A batch is zipped in the browser, so the finished files together have to stay under 300 MB for Download all. Past that, each row still has its own Download.
Frequently asked questions
Can I compress an image without losing quality?
Not literally, if the output is JPEG, WebP or AVIF. Those formats work by throwing away detail your eye is bad at noticing. What you can get is visually identical, which is what Smart aims for: it takes the highest quality on the ladder that still shrinks the file. Switch the compare to 1:1 and look at an edge or some text, which is where a re-encode shows first.
Why does Smart only save 5% on my photo?
Because the photo was already compressed when your phone saved it, and Smart stops at the first quality that makes the file smaller at all. That is 80 for most camera JPEGs. The caution under the figure names the next rung and what it would weigh, usually a third smaller. A lower Max width does far more than any quality setting on a photo, since fewer pixels beats a lower quality almost every time.
How do I get a photo under 100 KB for an application form?
Choose Target, type 100 in Target size, and press Compress. The search lands on the best quality under that ceiling and the line under the percentage says which quality it used. If a big photo cannot reach 100 KB at full resolution, lower Max width to around 1200 and it re-encodes straight away, which usually does more for the size than any amount of quality tuning.
Does compressing strip the EXIF and location data?
It does, because the picture is decoded to raw pixels and written out fresh, and none of the original metadata rides along. Camera model, timestamp and GPS position all disappear from the compressed file. The one exception is DPI, which is deliberately read from the source and put back. If you want to inspect what a photo was carrying before you compress it, the EXIF viewer shows you.
I dropped in fifteen photos. Where did the before-and-after compare go?
A batch shows the picture being worked on instead, and the queue does the comparing: each row has the file's type and size, what it came out at, and the saving as a tag. Every finished row has its own Download, and Download all zips the lot, or hands you the one file if only one finished. A file that cannot be read is marked on its row and the rest carry on. Press Cancel and the ones that finished stay yours.
Why did my JPEG come back with a .webp extension?
Format starts on WebP and stays there until you change it, so beach.jpg comes back as beach-compressed.webp. Choose Keep original when the file has to stay a JPEG, or pick JPEG outright. Keep original also writes a PNG back as a PNG, which on a photograph is worth avoiding for the reason in the PNG note above.
If I lower Max width and leave Max height alone, what happens to the height?
It follows the width, at whatever keeps the picture in proportion, because the tighter of the two limits wins. For one picture both boxes start filled with its own size, so nothing changes until you lower one. For a batch they start empty, since each picture has its own size, and an empty box constrains nothing. Neither box will enlarge a picture.
I typed 500 into Target size and it said there was nothing to do.
Your file was already under 500 KB. That comparison runs on the incoming size before any encoding starts, and it stops there, since re-encoding something that fits the limit costs detail and buys you nothing. Type a smaller number if you want the file below where it currently sits.
Will it still be on Target when I come back tomorrow?
The Compression setting, the Quality slider and the Format are all kept for your next visit. The KB figure is not, and neither are Max width and Max height, because those usually belong to one particular job. You land back on Target with an empty Target size waiting for a number.
Missing something in Image Compressor? Suggest a feature →
Tell someone who needs this.