LivreImage
PT

Compress an image to 5 MB

The 5 MB ceiling is preset: the page walks the JPG encoder from full quality down until the file lands under 5,242,880 bytes, keeps the highest setting that does, and prints the real byte count before you attach anything.

Choose your images Tap or click to choose — or drag them here. On desktop you can also paste with Ctrl+V.
  • Nothing uploaded
  • Free, no sign-up
  • Strips EXIF
  • Batch files

The bank's secure-mail form took your invoice PDF and bounced the product shot: attachments under 5 MB per file. That exact figure guards a surprising band of systems — insurance claim portals, hospital patient logins, municipal service desks — each of them a decade-old stack that nobody has migrated since. A 48 MP phone photo weighs anywhere from five to twelve megabytes, so the file you just took is often double the ceiling, and the error line just repeats the limit without explaining the gap.

Drop the file here and leave the rest alone. JPG is preselected because that is what nearly every gateway of this kind accepts, and the quality and width fields are grayed out: the target search does the adjusting, starting at full quality and stepping down until the byte count sits under five megabytes. Only if even the softest encoding still overshoots does it start trimming width, and that is rare at this ceiling.

Each result card shows the original weight, the new one, the percentage recovered, the final pixel size and a target-met tag, so you attach with confidence. Run an entire shoot in one batch and take the finished set as a single .zip — every pass happened on your own hardware.

How it works

One number does all the work here, and it is already set: drag, generate, download.

  1. Add the photos

    Choose them, drop them on the page or paste with Ctrl+V. Camera originals in JPG, PNG, WebP or HEIC all open right on your device, and a whole folder goes in at once if you are prepping more than one attachment.

  2. Keep JPG, ignore the rest

    The settings panel opens with the five-megabyte target locked and JPG on the format bar, so switch formats only if the receiving system names another one. The quality and width inputs do nothing on this page — the size search owns them — and changing the target is what you do by visiting the page for your actual ceiling.

  3. Generate and skim the cards

    Press Generate images and read each card: old weight, new weight, percentage recovered, final width × height, and the target-met tag. If your gateway is the decimal kind that counts a megabyte as one million bytes, stop the search a little earlier on the 4 MB-ish range — see the FAQ about MB versus MiB — or regenerate with the general compressor at a lower setting.

Where a five-megabyte per-file rule actually lives

Fewer platforms print this ceiling than you would guess, and the ones that do are rarely the famous ones. The rule usually shows up behind a login, in a portal where the error message is the only documentation.

  • Banking, credit-union and insurance portals: 5 MB per attachment, JPG or PDF named in the fine print
  • Hospital, clinic and pharmacy patient forms: 5 MB, sometimes one file per field
  • Municipal and state service desks: 5 MB, with forms that date back years
  • E-mail with attachments: several providers cap a single attachment near the 20 MB line, and corporate mailboxes often sit at 5 MB per item
  • Print-on-demand uploads: some printers cap artwork at 5 MB when the order travels over e-mail

What the 5 MB target does to typical shots

The engine walks the encoder from the top: try the current quality, measure the result, step down and measure again, stopping at the first quality whose output sits under 5,242,880 bytes. A 12 MP phone photo usually arrives somewhere in the 60s of quality with every pixel intact; a 24 MP fine-mode frame from a mirrorless needs more give; a 48 MP flagship frame may lose a little sharpness in texture areas.

  • HEIC files decode in the browser (the one-off decoder is about 1 MB) and come out as standard SDR JPG — the gain map that drives HDR displays is dropped in the re-encode
  • Results cluster a couple of hundred KB under the ceiling; that margin is deliberate
SourceUsual starting weightTypical arrival under 5 MB
Phone, 12 MP (4032 × 3024), 2–4 MBalready near the linequality about 75–90, pixels untouched
Phone, 48 MP (8064 × 6048), 5–12 MBone of two sizes overquality about 45–65, pixels untouched
Mirrorless, 24 MP fine, 8–14 MBusually overquality about 40–60 per pixel
iPhone HEIC, 12 MP, 2–3 MBdecodes, then re-encodesSDR JPG at quality above 80

Why stop 2 MB below the cap the platform advertises

Because the 20 MB you see on a listing platform is not the number that rejects your file. The per-attachment check usually lands lower, in the middle of the upload chain, and it is a hard wall: hit it and the whole message bounces, with no partial delivery. Landing at 5 MB when the outer gate says 12 or 20 MB costs a modest quality step on a phone photo and removes the single most common upload failure.

The decimal-megabyte trap

This page counts a megabyte the way Windows does — 5 MB is 5,242,880 bytes. Plenty of upload scripts, and the fine print of a few portals, count it as 5,000,000. A result the card reports as 5,150,000 bytes clears the first definition and fails the second, and the only symptom is the same file-too-large line. Two fixes: regenerate at a target a little below (the 1 MB page is not it — the general compressor's slider at 70 is), or ask your IT contact which kind of megabyte the gateway is running.

Frequently asked questions

Why does the card say 4.9 MB when my limit is 5 MB?

Because a byte-precise landing right at the ceiling is how upload checkers say no. The search runs until the result is a couple of hundred KB inside the limit, and that margin is the difference between accepted and bounced on a flaky gateway.

I compressed a photo to 3 MB earlier and my bank still rejected it. What gives?

Check whether the cap is per file or per session, and which megabyte is being counted. A 3 MB file sits safely under both 5-MB definitions, so a rejection at that size points to a smaller ceiling behind the login, a per-field limit, or a format rule — not the JPEG quality of your file.

Can I send five photos, each under 5 MB?

Yes — the batch mode runs the same target on every file and hands back one .zip. Unzip on the receiving machine and attach them normally, since most gateways will not open the zip themselves.

Does my photo ever leave my machine to get to 5 MB?

No. The decoder for HEIC (fetched once, about 1 MB) and the JPEG encoder both run inside your browser's canvas. The only thing that crosses the network in either direction is that one decoder file, and it is cached after first use.

The receiving form lists 5 MB but my 4.98 MB file still failed. What am I missing?

Two suspects: the gateway counts 5 MB as 5,000,000 bytes instead of 5,242,880, or the cap belongs to a different gate in the flow — per-field or total-per-message. Regenerate at a lower setting on the general compressor, or split the upload into two messages and watch which one trips.

Should I shrink the dimensions before running this?

Only when the file is a 48 MP flagship frame or a 10,000 px scan. At 5 MB a 12 MP photo keeps every pixel; at 48 MP the quality search may have to give up more sharpness than a modest width cap would. A width cap of about 6,000 px on the resize page, then a second pass here, is the cheapest path to the sharpest result.

Advertisement