Making PDFs Smaller: What to Compress and What You Can't
Why PDFs get large: image re-encoding versus structural optimization, why fax scans won't compress, why signatures break, and how to fit upload caps from 100 KB to 5 MB.
Written by Faruq Zhao Updated 2026-10-31
An oversized PDF is oversized for one reason, nearly every time: photos or scans. Text, fonts, links and vector graphics cost a few KB per page even in a long document; a single 300 dpi color scan runs to hundreds of KB or several MB. That fact decides which approach works — and explains why some PDFs never compress no matter what you do.
The two kinds of compression don't substitute for each other: re-encoding images is lossy and can cut a scanned document by 90%; structural optimization is lossless and typically saves a few percent. Knowing which one your file needs comes before doing anything at all.
Where the bytes actually go
A PDF is a container, not a picture. Inside is a page description written in a small instruction language — this text at that coordinate in this font, these vector paths stroked that way — plus whatever images the author placed. The page description is inherently cheap: it says "draw these glyphs here in this font" and never stores a "photo of the text".
Images are the opposite. Scans and digital photos are stored as full pixel grids: A4 at 300 dpi is about 2480×3508 pixels, roughly 8.7 million pixels per page — around 25 MB of raw data before compression. And scanners compress page by page, so a 50-page scan is born as 50 independent images; even as lossy JPEG, each page often still runs to hundreds of KB.
What's inside a PDF and roughly how much of the file it is
| Content | Storage | Typical share |
|---|---|---|
| Photos placed in layouts | JPEG (DCTDecode), often several megapixels each | Usually the single largest item |
| Scanned pages | One image per page, JPEG or fax coding | The overwhelming majority of scanned documents |
| Text | Glyph coding + embedded font subsets | Tiny, a few KB per page |
| Vector graphics, charts, table lines | Paths and color instructions in the content stream | Tiny |
| Bookmarks, form fields, annotations, metadata | Small dictionaries and XML blobs | Negligible |
| Digital signatures | A signature dictionary plus certificates | A few KB — but it constrains everything else |
So a 60-page Word contract can easily be smaller than a 3-page scanned invoice: the contract is mostly instructions, the invoice is mostly pixels.
The two kinds of "smaller"
Lossless structural optimization
This changes only how the file is organized, never a single pixel or glyph: repeated objects are stored once and referenced; many small objects are packed into compressed object streams; leftover metadata and duplicate resources are stripped; uncompressed streams get deflated. qpdf and Ghostscript's structural options live here, and a PDF editor's "Save As" often does too.
The good part: it cannot damage the document. Text stays text, images stay bit-identical, printing and archiving are safe. The cost: the ceiling is low — a well-formed PDF was already optimized at birth, so this typically squeezes out a few percent. If your size comes from photos, structure won't save you.
Lossy image re-encoding
This goes after the images themselves: decode every embedded image, downscale it when it dwarfs what the page actually shows, re-compress at lower quality, and write it back in place — leaving text, vectors, links and form fields untouched. The big reductions come from here — and it's the only approach that can change how the document looks, so be careful with dense small print and technical drawings.
A practical rule: mostly text and you need an archive-grade copy — try structure first; big because of photos and scans — re-encode the images.
Neither approach can conjure detail that isn't there. If the scan resolution was too low, downscaling throws away what little there was. Keep the original file until you've confirmed the result.
The PDFs that won't shrink
Some PDFs come out nearly unchanged — recognize them and you'll stop blaming the tool:
- Pure-text PDFs. A letter, a CV, a report exported from a word processor has no embedded images and might already be tens of KB — there's nothing to save. Getting visibly smaller means deleting content or rasterizing pages, and rasterizing makes the file bigger while destroying selectable text.
- Black-and-white fax and bilevel scans. These pages use CCITT Group 4 or JBIG2 — coding designed specifically for pure black/white pixels, and browsers have no encoder for it. Converting to grayscale JPEG is a regression in both size and sharpness. The only real fix is a rescan at a sensible resolution.
- Uncompressed bitmaps and palette images. Unfiltered images, or indexed-color images (icons, logos), are often already small; JPEG conversion makes them bigger and adds fringing on sharp edges.
- Images with an alpha channel. Flattening a transparent image fills the transparent areas with a visible background color.
- Encrypted PDFs. Password- or certificate-encrypted files can't be rewritten without the password.
- Already-optimized files. Images that were small to begin with won't shrink twice — that's a result, not a failure.
A trustworthy tool tells you which of these it hit instead of reporting a "success" that didn't happen; PDFs whose images are stored as JPXDecode (JPEG 2000) are the same — browsers overwhelmingly can't re-encode them. When compression genuinely can't work, the honest direction is upstream: rescan at a sane resolution, have the sender re-export, or split the document.
Digital signatures and other hard limits
A digitally signed PDF breaks when you compress it. The signature is computed over the file's exact bytes, so any rewrite — compress, merge, split, edit, re-save — invalidates it, and you're holding a copy with no valid signature. When the signature matters for a contract, an invoice or a legal archive, leave the original untouched.
That's not a software defect — it's the reason signatures are worth having: they prove nothing changed after signing. Compress a signed contract and send it, and your counterparty's verification fails.
- Passwords: an encrypted PDF must be unlocked before compressing.
- Approval signatures and document timestamps: other signature flavors, same restriction.
- Linearization: a PDF that was linearized for fast web view stops being linearized after any rewrite; on slow connections it may open slightly slower.
Hitting a specific size cap
Most people aren't compressing for its own sake — they're stuck on a specific number from an inbox or an application portal. This table maps the common caps to what actually works; the real requirement is always the receiving system's.
Common upload and attachment caps
| Cap | Where you usually hit it | What tends to work |
|---|---|---|
| 100 KB | Government forms, ID photos, some HR portals | Maximum compression plus pixel downsizing where the document allows. A single mid-resolution scan page fits; a 20-page photo report doesn't — split it |
| 500 KB | Online application forms, scholarships, visa systems | Balanced or smallest mode for scan-heavy documents. Check the small print is still legible afterward |
| 1 MB | The most common web-form and mail-attachment tier | Ordinary mixed text-and-image documents usually clear it easily |
| 2 MB | A common default mailbox limit | A few dozen pages on the highest quality tier — usually indistinguishable |
| 5 MB | Relaxed submission systems, print services, some mailboxes | Only mega-scans and full albums exceed it. At that point verify pages and legibility instead of compressing further |
If it still doesn't fit after one pass:
- Run "smallest" once more. The criterion is whether it's legible at 100% zoom — not the file size.
- Delete what the recipient doesn't need. Blank pages, cover sheets, unsolicited attachments — that space was free; don't buy it back with image quality.
- Split the document. Most systems accept multiple files: a 12 MB report in three parts clears a 5 MB cap.
- Re-export from the source file if you have it — a lower-quality export setting beats reworking an already-compressed PDF.
- Rescan at 200–300 dpi when scans are the problem, and let the scanner do its own compression — usually better than attacking a 600 dpi scan afterward.
One thing not to do: rasterize pages to make the number. Rasterizing tools turn every page into an image — selectable, searchable text is gone permanently — and for text-dense documents the result can be larger than the original.
Compressing in the browser, batches included
This site's PDF compressor runs entirely in the browser on libraries the page has already loaded. The file goes from disk into the tab, gets processed there, and comes back to disk — nothing uploads, no account needed. That makes it safe for contracts, payslips and ID documents, which are precisely the files most often told to "shrink before you upload".
- Drag one or more PDFs onto the page, or click to pick them — batches are supported.
- Pick a tier: smallest re-encodes at the lowest quality and size, balanced sits in the middle, best quality keeps more detail. The tier applies uniformly to the whole batch.
- Compress. Files process one at a time with per-file progress, so even a big batch doesn't lock up the tab.
- Review each result: size before, size after, savings, how many images were re-encoded, how many pages.
- Download individually, or take the whole batch as one ZIP — generated in the browser too.
The tool replaces only the embedded JPEG images with re-encoded versions and leaves the rest of the file alone, so text stays selectable and searchable, links keep working, and page dimensions don't change. And it reports honestly when it can't help:
- No embedded images — the file is already near the floor of what its content costs.
- Images stored in formats it won't re-encode: raw bitmaps, palette images, or JPEG 2000.
- CMYK or alpha-bearing images. CMYK JPEGs decode fine in browsers but shift color; flattening alpha fills transparency with a background color. Neither gets touched.
- Pages that look like fax or bilevel scans — no browser-side tool can re-encode those usefully.
- Re-encoding made it bigger — the original image is kept instead.
- A digital signature is present — a rewrite would invalidate it.
- Encrypted PDFs need unlocking first, and single files are capped at 150 MB.
If the compressed result isn't smaller than the original, what you download is the untouched original file.
FAQ
Why did my PDF barely shrink?
Because there's little image data to re-encode. Pure-text PDFs carry no photos or scans — their size lives in fonts, page descriptions and metadata, and it doesn't come back without deleting content. Already-aggressively-compressed images, or formats no browser can re-encode, come out the same.
Does compression break a PDF's digital signature?
Yes. The signature covers the file's exact bytes, and any rewrite invalidates it — merging, splitting, editing and re-saving included. When a signature must stay verifiable, leave the original untouched and compress a separate copy you don't need signed.
Can an encrypted PDF be compressed?
Not while it stays encrypted. The content has to be unlocked before anything can rewrite it: use a decryption-capable tool, enter the password, save an unencrypted copy, and compress that one — knowing the unlocked copy has none of the original protection.
Why won't my black-and-white scan compress?
Bilevel fax scans use CCITT Group 4 or JBIG2, for which browsers have no encoder — and per unit of content these pages are already small. Converting to grayscale JPEG usually comes out bigger and blurrier. The one real fix is a rescan at a suitable resolution.
Does compression destroy searchable text?
Not when the tool works by replacing images. Text, fonts, vectors, links and form fields all stay in the file exactly as they were — still selectable, searchable, copyable. Tools that rasterize pages are a different story: those turn text into pixels permanently, and nothing you may want to search later should go through them.
Further reading
- Why PPT files get so big — the same methodology applied to slide decks.
- PDF compressor, PDF merge, PDF split — the three browser-side PDF tools.
- Compress image to 100KB — the target-size mode when a single image carries the cap.
Tools used in this guide
Compress PDF
Compress PDFs online free: re-encoding embedded images shrinks the file, text and vectors stay intact. Batches tell you honestly why a PDF won't shrink. 150MB each, no upload.
PDF Merger
Merge multiple PDFs into one file online free. No limit on count or size, encrypted files unlock in place, reorder and merge in one click. 100% local, files stay in your browser.
PDF Splitter
Split PDFs free online: click thumbnails or type page ranges to keep the pages you need, or save each page as its own file in a ZIP. 100% local, encrypted PDFs unlock in place.
PPT Compression – Shrink PPTX Files Online
Compress PPTX online for free: recompress embedded images, drop speaker notes and hidden slides, strip author metadata. Processed locally in your browser, files never uploaded.
Compress Image to 100KB
Compress images to exactly 100KB free online. Shrink JPG, PNG or WebP under 100KB for forms, applications and email attachments — no upload, entirely in your browser.
More guides
How Minecraft Locator Bar Colors Are Calculated (Java and Bedrock)
Where locator bar colors come from: the UUID hash on Java Edition, the join-order assignment on Bedrock, the Xbox ID mapping through Geyser, and the /waypoint syntax.
HEIC and JPEG: What iPhone HEIC Files Are and When to Convert Them
How the HEIF container relates to HEVC, why Apple chose it, how it compares with JPEG on size and compatibility, when conversion is mandatory, and how to convert in bulk offline.
Passport and Visa Photo Requirements: Pixels, DPI and File Size Limits
Why ID photos fail at the last step: print sizes to pixels, where 50 KB and 100 KB limits come from, why some are ranges not caps, and how to hit one without losing the face.