Compress an Image for Email
An attachment has to fit a number, and the number is not negotiable. This page takes one 4000x3000 JPEG of 1,360,339 bytes through four targets on the same compressor and records the quality each one required, the size it reaches after Base64 encoding, and the single conversion that undoes the whole exercise.
Try the free tool now
100% in your browser — no upload, no account, no watermark.
Open Compress an Image for Email - Four Targets, Four QualitiesFour targets, measured
| Target | Output | Quality used | Margin |
|---|---|---|---|
| 1,000 KB | 965,959 B | 48% | 34,041 B under |
| 500 KB | 492,520 B | 15% | 7,480 B under |
| 400 KB | 399,707 B | 10% | 293 B under |
| 300 KB | 284,706 B | 6% | 15,294 B under |
The margin column assumes a target of exactly 1,000,000 bytes for 1,000 KB, so it will shift slightly if a provider counts in binary. What matters is the shape of the table: the quality needed falls steeply as the target tightens, from 48% down to 6% while the target shrinks 3.3 times.
The 400 KB row is the tightest fit of the set. The compressor stopped 293 bytes under the target, which is normal for a quality search that works in whole percentage steps.
A quality of 6 is a visible trade
Six percent is not a rounding error in the encoder; it is the setting that finally fits 300 KB. On a photograph it produces flat patches in gradients, ringing around high-contrast edges and a general loss of texture. Whether that is acceptable depends on the recipient: a snapshot for a colleague, yes; a property photo sent to a client, probably not.
When the image must stay presentable at a small target, change the dimensions before touching quality. A 2000-pixel-wide copy gives the encoder far less to describe than a 4000-pixel one, and the recipient's screen cannot show the difference.
The PNG copy that breaks the plan
Converting the same photograph to PNG produces 14,472,025 bytes, 10.6 times the JPEG it came from. PNG is lossless: it stores every pixel and cannot discard the noise a camera sensor records, so a 12-megapixel photograph becomes a 13.8 MiB file.
That is the failure case this page exists to prevent. Someone compresses a photo to 400 KB, converts it to PNG for quality, and attaches a file 36 times the size of the compressed version. After encoding it is worse still: 14,472,025 bytes become about 19,296,036 bytes of Base64, roughly 18.4 MiB inside the message.
Base64 inflates every attachment
Mail transports text, so binary files are encoded in Base64 before transmission, and that encoding uses four characters for every three bytes. The overhead is a fixed 33.3%, not a rounding artefact:
| File on disk | In the message (approx.) | Added |
|---|---|---|
| 1,000 KB | 1,333 KB | 333 KB |
| 965,959 B | 1,287,948 B | 321,989 B |
A file that looks safely inside a limit can cross it once encoded. The arithmetic is simple enough to do before sending: multiply the byte count by four and divide by three.
The only external limit quoted here
One platform figure is verified for this page: a personal Gmail account can send up to 25 MB of attachments, and above that total Gmail replaces the attachment with a Google Drive link (support.google.com/mail/answer/6584, retrieved on 7 November 2026).
A corporate gateway may enforce a ceiling the sender cannot see, and that ceiling is usually lower than the consumer one. The reliable test is a message to yourself: if it arrives intact, the path between those two accounts accepts that file.
When the attachment still will not fit
- Resize the longest side to the size the recipient will actually view.
- Compress to the target with Compress to Size and note the quality it reports.
- Convert to WebP only if the recipient can open it; otherwise stay on JPEG.
- For several photos, send them in separate messages rather than shrinking each one to unreadable.
- Send a test copy to yourself before the real recipient sees it.
The order matters. Resizing changes how much detail the encoder has to spend bytes on; converting formats does not reduce the pixel count at all, and in the PNG case above it makes the file far heavier.
A scan saved as lossless PNG
Scanned pages and screenshots are a different problem from photographs. A 1920x1942 capture is only 197,518 bytes as PNG because large areas are flat colour and the lossless encoder compresses runs of identical pixels extremely well. A photograph has no such runs.
The rule that follows is about content rather than format preference: lossless for interface, line art and text; lossy for continuous tone. Applying the screenshot habit to a photograph is what turns a 1.3 MB attachment into a 13.8 MiB one.
About this guide
- Written by
- The ImageTools Pro team
- Last reviewed
- October 2026
- How we test
- Steps run in a real browser on real PNG, JPEG and WebP files
We revise this page whenever browser APIs, format support or recommended settings change. Corrections are welcome — tell us from the contact page.
Tools we recommend
Frequently Asked Questions
What size should an email attachment be?
Choose the target from the recipient and the context. On the 12-megapixel fixture, 1,000 KB needed quality 48 and 400 KB needed quality 10, producing 965,959 and 399,707 bytes.
Why is my attachment bigger than the file on disk?
Base64 encoding adds 33.3%. A 1,000 KB file travels as about 1,333 KB, and the 965,959-byte output grows to 1,287,948 bytes.
Does converting to PNG improve quality?
No. The JPEG has already discarded detail, and PNG preserves only what is left - at 14,472,025 bytes for this photo, 10.6 times the original JPEG.
Is Gmail's limit the one to design for?
It is the only one verified here: a personal Gmail account can send up to 25 MB of attachments, and larger files are replaced by a Drive link (Google help page, retrieved 7 November 2026). Other providers were not checked for this page.
Can I compress several photos at once?
Compress Image handles one file per run, and each run counts against the 20 free daily operations.