How to use Image Compressor
- Choose a JPG, PNG or WebP image.
- Choose JPG or WebP and enter an optional target size in KB.
- Select Compress image, check the actual size and download the result.
Useful to know
For a target KB result, choose JPG or WebP. The tool keeps as much quality and resolution as it can while working below the requested limit.
Reduce an image to a target size in KB
Choose a JPG, PNG or WebP image, select JPG or WebP output, and enter the file-size limit you need. The image size reducer tests several quality levels on your device. If quality changes are not enough, it carefully reduces the pixel dimensions and tries again. The result panel reports the actual dimensions and file size before download.
You can enter 100 KB, 200 KB, 500 KB or another limit rather than choosing from a fixed list. Prefill pages exist for 20 KB, 30 KB, 50 KB, 75 KB, 100 KB, 150 KB, 200 KB, 250 KB, 300 KB, 400 KB, 500 KB, 750 KB and 1 MB. For a host rather than a number, see WhatsApp, Gmail or Instagram upload. Browser image encoders do not produce every byte value exactly, so the finished file will normally be a little below the target. Keep the target field empty when you prefer to control quality and maximum width yourself.
Which format makes an image smaller?
WebP is a useful first choice for modern websites because it often produces a compact file while keeping good visual detail. JPG is widely compatible and works well for photographs. PNG preserves transparency and sharp graphic edges, but its browser encoding does not use the quality setting. Choose JPG or WebP when a specific KB limit matters.
Compress a photo for email or an upload limit
Enter the limit shown by the form or service, then review the actual output before submitting it. The highest quality setting acts as a ceiling: Image Cosmos searches below it for the best result that meets the target. If the final dimensions are smaller than you want, try a larger target or set a maximum width before compressing.
Compress an image for a website
Use the smallest pixel dimensions the page actually needs. A large camera photo displayed in a narrow content column wastes download data even after quality compression. WebP usually suits web photos; PNG remains useful for logos, screenshots and graphics that need transparency. Use the image resizer first when exact pixel dimensions matter more than a KB limit.
Does image compression reduce quality?
JPG and WebP quality settings trade some image detail for a smaller file. Very small targets may also require fewer pixels. Review the result preview and avoid repeated re-compression of the same file. Keep the original image as your master copy. Processing happens on your device, so the selected image is not sent to an Image Cosmos server.
How to compress an image to a target file size
- Choose one JPG, PNG or WebP image. The file stays on this device, with a limit of 25 MB and 40 megapixels.
- Choose JPG or WebP when you need a file-size cap. PNG cannot use a target. Quality runs from 10 to 100 and starts at 82.
- Enter the target in KB if you have one, and set a maximum width only when the photo is wider than the page or form needs.
- Select Compress image, read the actual pixel size and file size, then download the result.
How this compressor decides the file size
The workspace does not send the picture anywhere. Your browser decodes the JPG, PNG or WebP you choose, draws those pixels onto a canvas, and then encodes a new file in the format you picked. That is the whole pipeline. There is no second copy on an Image Cosmos server, which is why the result panel is where you read the real width, height and file size before you download.
When the target field is empty, the tool encodes once at the quality you set. Quality runs from 10 to 100 and starts at 82. It applies to JPG and WebP only. PNG is written losslessly, so the quality number does not change a PNG at all.
When you type a target, that quality number becomes a ceiling rather than a single attempt. The browser first tries the quality you chose. If the file is already under the target, it stops and keeps the dimensions, apart from any maximum width you set on purpose. If the file is still too big, it searches lower qualities, down to 10, and keeps the largest result that still fits. Browser encoders do not land on an exact byte count, so the download is normally a little under the number you typed. The target is counted in units of 1,024 bytes, so 100 means 102,400 bytes, not 100,000.
If quality 10 is still over the target, the canvas is scaled down and the search runs again. That is why a strict cap can reduce the width even when you did not ask for a resize. The optional maximum width does a similar resize first, before that search, and it keeps the original proportions. Use it when you already know the photo will be shown at about 1,200 or 1,600 pixels, instead of hoping a tiny KB target will guess the right canvas for you.
JPG quality, WebP and PNG
These three formats are not interchangeable, and shrinking a file is not the same job as changing its container. JPG is lossy and widely accepted by email, upload forms and older software. WebP on this page is also lossy at the quality you set. For many photographs it produces a smaller file than JPG at a similar look, but the saving is not a fixed ratio you can quote in advance. PNG is lossless. It keeps sharp edges and transparency, and a photograph saved as PNG often gets larger rather than smaller.
This page will not pretend a PNG can hit a kilobyte target. If you select PNG and type a target, the tool stops and asks you to choose JPG or WebP. Transparency is the other practical difference. A JPG from this compressor fills transparent pixels with white, and this page does not offer a background-colour control. WebP and PNG can keep transparency. If a logo must stay on a clear background, keep PNG, or make a WebP and check the preview against a contrasting page colour. If a form only accepts JPG, use the PNG to JPG converter first so you can choose the background, then compress that JPG here.
| Aspect | JPG | WebP | PNG |
|---|---|---|---|
| Quality field | Changes the file. Lower numbers discard more fine detail. | Same idea as JPG on this page. The tool does not write a lossless WebP. | Ignored. The browser writes a lossless PNG. |
| Target size in KB | Used. The result is usually a little under the number. | Used, in the same way as JPG. | Refused. Switch to JPG or WebP. |
| Transparency | Becomes white. There is no background picker here. | Can be kept. Check the preview on a coloured background. | Kept. |
| A sensible job | Photographs for email, portals and software that rejects WebP. | Photographs for a site that can serve WebP. | Logos, screenshots, flat graphics, and anything that must stay transparent. |
Need a different container before you compress? JPG to WebP and PNG to WebP make a WebP copy. WebP to JPG makes a JPG that older software can open. JPG to PNG and WebP to PNG make a PNG, which will not restore detail a lossy save already threw away, and the file will usually grow.
Which KB target for which job
The ranges in this table are practical guidance for choosing a number to type. They are not platform rules, and they are not a promise that a host will accept the file. If a form, portal or help page states a maximum, type that number. If it states a pixel size, set that size first with the image resizer, or set a maximum width here, and only then compress. Starting from a 4,000-pixel camera original and asking for 30 KB is how you get a soft, tiny picture.
| Job | Practical range | Check this before you send it |
|---|---|---|
| Email attachment | 100–200 KB for one photo | Several photos in one message sit more comfortably nearer 100 KB each. A provider’s published cap is usually for the whole message, not for this range. |
| Web upload form | The number printed on the form, or about 100 KB if the form is silent | Crop to the part the form will show, so the byte budget is not spent on edges that will be cut off. |
| Passport or visa portal | The portal’s own cap, usually a small JPG | These sites name both a pixel size and a file cap, and the numbers differ by country and by form. Resize to their pixels first. Do not reuse another country’s limit. This row is not an official specification. |
| Website hero | 150–300 KB | Only after the image is no wider than the layout. WebP is the usual choice. Use JPG if the site cannot serve WebP. A hero that is still several thousand pixels wide wastes bytes even at a modest quality. |
| Avatar, icon or thumbnail | 20–50 KB | Expect the width to drop if you start from a large photo. That is acceptable for a tiny avatar and a poor result for a full-page image. |
The Gmail guide and the WhatsApp guide go further on those two hosts, including what their own encoders do after you attach the file. The Instagram upload guide explains why a tiny KB target is usually the wrong move once the photo is already about 1,080 pixels wide. For a familiar cap with the number already filled in, open the 100 KB page, the 50 KB page or the 20 KB page. They run this same compressor.
Use the crop tool when the useful part of the picture is smaller than the frame. Cropping away empty margin, then compressing the original crop, keeps more detail than asking a huge canvas to hit a harsh target. Resize when the destination has asked for exact pixels. Compress when the destination has asked for a file size. Doing both, in that order, from the master file, beats either step alone.
Why the download lands under the target
Two outcomes are easy to mix up. Landing under the target with the same width is normal: the search keeps a file that fits, and the encoder cannot aim at an exact byte. Landing under the target with a much smaller width means quality alone was not enough, so the canvas was reduced. If you need those pixels, raise the target, raise the quality ceiling, or resize to the required width and accept a larger file. The status line says when the target was met and when the browser could only offer a best effort that is still over the cap.
Compressing the download a second time is a weak way to save more bytes. JPG and WebP throw away a little more detail on each save, even when the quality number looks high. If the first result is wrong, change the settings and run them on the original. One image at a time is also a hard limit of this page: there is no batch queue and no zip of several results.
Compressing on a phone
The same limits apply on a phone as on a laptop. One image, 25 MB, 40 megapixels, and the work happens in the tab you have open. A recent camera photo can sit near that ceiling and make the page feel slow, because the browser tries several encodings in memory before it picks one. Set a maximum width close to the size you will actually send, then set the KB target. Judge the preview at a size close to the real use, not only as a small thumbnail in the result card. Mobile data is not used to upload the picture to Image Cosmos. The file stays on the device, and the download link lasts only until you reload or close the tab.
Related image tools
Frequently asked questions
Can I compress an image without losing quality?
JPG and WebP are lossy: a lower quality number throws away fine detail so the file can shrink. If the picture is already under your target at the quality you set, this tool keeps that quality and does not shrink it further. PNG output is lossless, so it does not use the quality slider and cannot chase a KB target. Nothing here restores detail that an earlier save already discarded. Keep the original as the master.
Is image compression private, or does the file upload?
It stays on your device. The browser reads the file, encodes the result in this tab, and offers a download. Image Cosmos does not receive the image, store a copy, or keep a history of the job. The temporary download link disappears when you close or reload the page.
How do I compress an image under 100 KB?
Choose JPG or WebP, type 100 in the target field, and compress. The result is usually a little under 100 KB, not exactly 100. If the preview is too soft or the width has dropped a lot, crop or resize to the size you will actually show, then compress the original again. A camera photo squeezed straight to 100 KB often looks poor because the canvas had to shrink.
Which is smaller, JPG or WebP?
For the same photograph at a similar look, WebP is often smaller, but not by a fixed percentage. Compare the result panel on your own image. WebP suits a modern website. JPG is the safer file when a form, an email client or an older app might reject WebP.
Why is the file under my target, and why did the width change?
The encoder cannot hit an exact byte count. It searches for the highest quality, at or below the quality you set, whose file is under the target. 100 in the field means 102,400 bytes. If even the lowest quality is still too big, the tool reduces the width and height and tries again. The result panel shows the real pixels and the real file size before you download.
Can I set a target file size for a PNG?
No. PNG with a target stops and asks you to switch to JPG or WebP. PNG stays lossless and ignores the quality field, so a photograph often gets larger, not smaller. Use PNG for logos, screenshots and images that need transparency. Use JPG or WebP when the limit is a number of kilobytes.
Can I compress several images at once?
No. The workspace takes one JPG, PNG or WebP at a time, up to 25 MB and 40 megapixels. There is no batch queue and no zip download. Run each file separately and keep every original.
Should I compress the same photo more than once?
A second pass on the same JPG or WebP rarely helps, and it can add extra softness and blockiness. If the first result misses the look you want, change the target, quality or maximum width and run it again from the original, not from the download.