PDF Compress Tool
Reduce a PDF's file size by re-encoding the embedded images at a quality you choose. Slide down to 1 for aggressive compression, slide up to 100 for near-original quality. 100% client-side with pdf-lib — your file never leaves the browser. No signup, no upload.
About This Tool
PDF Compress is a free, browser-based utility for shrinking PDF file size by re-encoding the JPEG and PNG images embedded inside the document. The vast majority of "PDF bloat" comes from high-resolution images that were never optimized for the page they're printed on — a 4 MB cover photo on a 600 × 800 pt page is a typical offender. This tool lets you pick a target quality (1–100) and rebuilds those images at the smaller size, producing a new PDF that's often 50–80% smaller than the original.
Under the hood, the tool uses pdf-lib to walk every page, extract embedded images with their XObjects, decode the raw pixel data with the browser's built-in ImageDecoder / canvas APIs, re-encode at the chosen quality with canvas.toBlob('image/jpeg', quality), and re-embed the smaller image. Text, vector paths, fonts, and form fields are passed through untouched — only the raster image bytes change. This means text and line art stay perfectly sharp at any quality setting; only photographs and scanned images are affected.
The "Re-encode all images" toggle controls aggressiveness: when checked, every image is re-encoded (best compression, slight quality loss on already-small images). When unchecked, only images larger than ~1500 px on the long edge are touched (safer for documents that are already optimized). Maximum file size is 50 MB. There is no signup, no daily limit, and no server upload — your document never leaves the browser tab.
How to Use
- Upload your PDF — click "Choose PDF" and pick any PDF up to 50 MB. The filename and size appear next to the button.
- Choose a quality level — start at 60 for a good balance, slide lower (20–40) for maximum compression, slide higher (80–100) for minimal quality loss.
- Click "Compress & Download" — the tool walks every page, re-encodes the images, and saves a new, smaller PDF to your device. The original is not modified.
Common Use Cases
- Shrink PDFs for email attachments — most email providers cap attachments at 10–25 MB; a quick pass at quality 50–60 typically fits a 30 MB report under 8 MB.
- Optimize PDFs for web viewing — smaller PDFs load faster in browser-based viewers and consume less bandwidth when hosted on a website.
- Reduce scan archive size — multi-page scans of paper documents balloon quickly; quality 40–50 with "re-encode all" can cut the size by 70%+.
- Prepare PDFs for mobile / e-reader — strip high-res image cruft that bloats the file without helping readability on small screens.
Frequently Asked Questions
How much will my PDF shrink? It depends entirely on the source. PDFs made from scanned images at 300 DPI typically shrink 60–80%. PDFs with mostly text and a few small images might only shrink 10–20%. PDFs that are already optimized might even grow slightly because the re-encoding overhead exceeds the savings — in that case, leave the file alone.
Will the text and vector graphics lose quality? No. The compressor only re-encodes raster images (photos, scans, embedded bitmaps). Text, vector paths, fonts, and form fields are passed through completely untouched, so they remain pixel-perfect at any quality setting.
Is my PDF uploaded to a server? No. Everything happens inside your browser tab. The file is read with the FileReader API, processed with pdf-lib loaded as an ES module, and the result is saved via a Blob download — your document never leaves your device.
Why didn't my PDF get any smaller? If the source PDF is already well-compressed (most modern Office exports are) or contains mostly text and very few images, the savings can be minimal. Try lowering the quality to 30 or 40, or check the "Re-encode all images" box to force re-encoding of every embedded image.
Pro Tips
- Start at quality 60 — it's the sweet spot for most documents: visible savings (often 50%+) with quality loss that is imperceptible on a typical screen.
- Use 80+ for archival / print — if the file is destined for high-quality print or long-term archival storage, keep the quality high (80–90) so photographs don't show banding or posterization.
- Combine with other PDF tools — compress first, then split, merge, encrypt, or rotate the result. Combining tools gives you a clean, optimized, ready-to-distribute PDF in seconds.
Related Tools — Want to merge the compressed PDF with other documents? Try PDF Merge. Need to split a large compressed PDF into chapters? Try PDF Split. Looking to extract text from a compressed PDF? Try PDF Extract Text. Need to extract images from a compressed PDF (or extract them before compression to inspect them)? Try PDF Extract Images.