← Back to tools
Compress PDF
Image-based compression
How to use
Purpose
Compress a PDF for smaller file size — useful for email attachments and upload-size limits. The strategy is rasterization-based: each page renders as an image and re-embeds, often hitting 10-30% of the original size. Note: text becomes a flat image layer (no longer selectable or searchable) — best for scans or final-distribution copies. Runs locally via pdfjs-dist + pdf-lib; no upload, no watermark, no page limit, free.
Steps
- Drag or pick a PDF
- Review the left-side file info: current size, page count, whether a text layer exists
- Pick a compression level: "Maximum" (smallest, lower quality) / "Balanced" / "High quality" (lightest compression, quality preserved)
- (Optional) Tune the "Output DPI" between 72 and 200
- (Optional) Enable "Preserve selectable text layer" (less reduction but keeps search functionality)
- Review the estimated output size
- Click "Process"
- Wait per-page (about 1-3 sec each)
- Download the compressed file with reduction percentage shown
FAQ
- Will text become blurry after compression?
- Image-based compression turns text into pixels. "High quality" mode (DPI 200) keeps text readable; "Maximum" mode (DPI 72) has visible blur — only fit for screen preview. To keep text crisp and selectable, enable "Preserve selectable text layer" (size reduction is smaller but functionality stays).
- How does this compare to server-side tools like Smallpdf or iLovePDF?
- Server-side tools use more sophisticated algorithms (resource dedup, font subsetting, intelligent image compression) — they can achieve smaller output at the same quality. But they require uploading. pdfbox's edge: "the file never leaves your device". If file confidentiality > maximum compression ratio, pick pdfbox.
- Can I OCR a compressed PDF to make it searchable again?
- Yes. If you compressed in "image-based" mode, the output is essentially a page of images — perfect input for the OCR tool to re-add a searchable text layer.
- Will the file be uploaded?
- No. pdfjs-dist renders each page locally, pdf-lib reassembles the new PDF locally — no uploads at any stage.
- Why do compression rates vary so much between files?
- It depends on source content: high-image PDFs compress dramatically (70-90% reduction); pure-text PDFs may even grow after image rasterization (you wouldn't compress those); scans grow or shrink proportional to DPI vs the original scan resolution.
Use cases
- Squeeze a PDF under 25MB for an email attachment
- Compress a large PDF to under 100MB for WeChat transfer
- Save cloud storage space by archiving compressed PDFs
- Get a resume PDF under a 5MB job-site upload limit
- Batch-compress scans before sharing to save bandwidth
Tip
Check the file's makeup first: pure-text PDFs may actually grow when rasterized — convert to Word format instead. High-image PDFs compress most dramatically. To preserve search functionality, pick "Preserve selectable text layer" + "Balanced" mode.