How to Compress an Image to 2MB
2MB is a common upload cap and a loose target. Most photos hit it with quality alone, and files already under it are handed back untouched. Here's how, and when it gets harder.
To compress an image to 2MB, open Compress Image, drop in your JPG, PNG, or WebP file, and type 2 into the "Target max size in MB" field. The tool then aims for that size instead of using the quality slider, and for an ordinary photo it usually reaches 2MB by lowering quality alone, so you keep the full pixel dimensions. 2MB is a loose ceiling, which makes it one of the easier targets to hit cleanly.
First, check whether your image is even over 2MB
This is worth doing before anything else, because a lot of images people try to shrink to 2MB are already smaller than that. A single photo off a phone often lands somewhere between 1MB and 5MB depending on the camera and scene, so plenty of files already sit under the line. Right-click the file and check its size, or just drop it in and read the result. If your image is already 2MB or less, Compress Image hands it straight back unchanged rather than re-compressing it and throwing away quality for no reason. There's nothing to fix, and forcing a compression pass would only make it look worse.
How to compress an image to 2MB
- Open Compress Image and drop in your file. It accepts JPG, PNG, and WebP — a HEIC photo from an iPhone has to be converted to JPG first.
- In the Target max size in MB (optional) field above the dropzone, type 2. Setting a target switches the tool off the quality slider and tells it to work toward that number.
- Download the result and check its size. If the file was already under 2MB, you'll get it back as-is; if it was larger, it comes back at or just under the target.
You can drop several files at once — each is compressed toward its own 2MB target independently.
What the tool actually does to hit 2MB
Setting a target doesn't make the tool pick one quality and hope. For a JPG or WebP it searches for the highest quality that still fits under 2MB, trying values between roughly 0.92 at the top and 0.40 at the bottom. Only if the lowest quality it will try still comes out over 2MB at full size does it start reducing the image's pixel dimensions and try again. For a typical multi-megabyte photo, 2MB is reached long before that floor, so the search settles on a high quality and your image keeps its original resolution. That's why 2MB looks so much better than a tight target like 50KB: the tool almost never has to shrink the photo itself to get there.
Picking the right format when 2MB is tight
For a photograph, JPG or WebP reaches 2MB most efficiently, because both throw away detail your eye barely registers. A PNG is the awkward case. The tool shrinks a PNG by cutting its colour depth before it touches dimensions, which can show as faint banding in skies and gradients, and a photographic PNG is a large, stubborn file to begin with. If a PNG photo won't reach 2MB without visible banding, converting it to JPG first is almost always the cleaner route. Keep PNG only when you actually need its lossless edges or transparency — a logo, a screenshot of text, a chart. For those, a dedicated PNG compressor is the better fit.
When you need to go below 2MB
2MB is a common upload cap — contact forms, job-application portals, document-upload fields, and content management systems that ship with a modest default limit all tend to sit around 1MB or 2MB. When the limit is tighter, the job changes. Our guide on compressing to 1MB covers the next step down, and for the genuinely small limits — 50KB, 100KB, and 200KB — resizing the image first matters far more than the quality setting does. If your photo is enormous to start with, a 40-megapixel shot or a wide panorama, resizing it yourself with Resize Image gives you control over the final dimensions instead of leaving that to the compressor.
Everything happens on your device
Compression runs in your browser through the Canvas API. Your image is re-encoded locally and is never uploaded to a server to be shrunk — it only leaves your device when you upload it yourself, wherever that 2MB limit actually is. That holds whether you compress one file or a whole batch.
FAQ
My file is already 1.8MB — will the tool still change it?
No. When you set a 2MB target and the file is already under it, the tool returns your original untouched rather than re-compressing it. Re-compressing an already-small file only degrades it, so there's nothing to gain.
Will compressing to 2MB make my photo look worse?
Rarely in any way you'd notice. Because 2MB is a loose target, the tool usually reaches it by nudging quality down while keeping the full resolution, so the result stays sharp. Visible quality loss only shows up when a target is small enough to force heavy compression, which 2MB almost never is.
Does it work on a PNG screenshot?
Yes — the target field works for JPG, PNG, and WebP. For a screenshot of text or UI, PNG is the right format to keep; the tool reduces its colour depth to shrink it. For a photographic PNG, converting to JPG first usually reaches 2MB more cleanly.
What if 2MB can't be reached?
The tool returns the smallest file it managed rather than inventing a result, so check the size before you rely on it. For a normal photo 2MB is easily reachable; the only files that struggle are extremely large ones, and resizing those first with Resize Image solves it. Keep your original and compress a copy either way.