The short answer
Text, links, form fields, page count and the document title came through every one of the 20 files we made, unchanged. What compression changes is pictures. A lossless rewrite left every page pixel for pixel the same and saved 0.7% to 9.6%. Asking for a smaller size made the pictures lighter, and the smaller we asked for, the more of the pictures' detail went.
So the question to ask is not how much quality a setting loses. It is whether your file's size is in its pictures. A PDF made from a word processor is mostly text and fonts, and no setting makes it much smaller. A PDF of photos or slides is mostly pictures, and it can shrink a long way.
The settings we tested
- Lossless: the file is rewritten with unused objects removed and its parts packed more tightly. No picture is decoded, so nothing can get worse.
- A target size: after the lossless rewrite, each JPEG picture is re-encoded until the file fits. The engine starts at 75% quality, steps down to 30% at most, and scales a picture down when quality alone is not enough, never below 13% of its width.
We asked for four targets on each file: 75%, 50%, 25% and 10% of its own size. Many tools offer named levels instead. Ours takes a size, so the trade is visible: you choose the bytes, and the table below shows what those bytes cost.
A quick test: bytes per page
You can tell before you start which kind of file you have. Divide its size by its page count. Our four files came out like this: the US Constitution at 20.6 KB a page, the slide deck at 36 KB, the IRS form at 110.2 KB, and the photo page at 540.7 KB.
The Constitution is plain text, so its pages are small and there is little to take away. The IRS form is only two pages but carries its fonts and form fields, which is why each page weighs more without being any more compressible. The slide deck and the photo page carry pictures, and that is where every saving in the table came from. A file with a high size per page and pictures you can see is a good candidate. A file with a high size per page and no pictures is usually carrying fonts, and compressing harder will not help.
What lossless does not touch
Lossless here means the engine never decodes a picture. It writes out only the objects the document uses, packs small objects into compressed object streams, and re-compresses every Flate stream at the highest level (qpdf's own options, listed in its manual). What the streams hold, the text, fonts, bookmarks and form fields, comes back the same once decoded. In our run every page drew identically on every file, the strictest check we could make.
That also explains its limits. If a picture was saved at a high quality, lossless leaves it there. On the photo page the rewrite saved 0.7%, because almost all of the file is one picture.
File by file
| File | Setting | Size | Fit the target | Largest picture | Worst page | Kept |
|---|---|---|---|---|---|---|
| IRS Form 1040 | Lossless | 199.1 KB | No target | None | – | Text, links, fields, title |
| IRS Form 1040 | Target 75% | 199.1 KB | No, smallest reached | None | – | Text, links, fields, title |
| IRS Form 1040 | Target 50% | 199.1 KB | No, smallest reached | None | – | Text, links, fields, title |
| IRS Form 1040 | Target 25% | 199.1 KB | No, smallest reached | None | – | Text, links, fields, title |
| IRS Form 1040 | Target 10% | 199.1 KB | No, smallest reached | None | – | Text, links, fields, title |
| US Constitution (pdf-lib test file) | Lossless | 363.5 KB | No target | 2,860 × 625 | – | Text, links, fields, title |
| US Constitution (pdf-lib test file) | Target 75% | 363.5 KB | No, smallest reached | 2,860 × 625 | – | Text, links, fields, title |
| US Constitution (pdf-lib test file) | Target 50% | 363.5 KB | No, smallest reached | 2,860 × 625 | – | Text, links, fields, title |
| US Constitution (pdf-lib test file) | Target 25% | 363.5 KB | No, smallest reached | 2,860 × 625 | – | Text, links, fields, title |
| US Constitution (pdf-lib test file) | Target 10% | 363.5 KB | No, smallest reached | 2,860 × 625 | – | Text, links, fields, title |
| Photo and drawing (pdf-lib example) | Lossless | 536.7 KB | No target | 1,920 × 1,080 | – | Text, links, fields, title |
| Photo and drawing (pdf-lib example) | Target 75% | 386.1 KB | Yes | 1,339 × 753 | 45.2 dB | Text, links, fields, title |
| Photo and drawing (pdf-lib example) | Target 50% | 263.6 KB | Yes | 960 × 640 | 31.7 dB | Text, links, fields, title |
| Photo and drawing (pdf-lib example) | Target 25% | 263.6 KB | No, smallest reached | 960 × 640 | 31.7 dB | Text, links, fields, title |
| Photo and drawing (pdf-lib example) | Target 10% | 263.6 KB | No, smallest reached | 960 × 640 | 31.7 dB | Text, links, fields, title |
| Slide deck with photos (pdf-lib test file) | Lossless | 725.9 KB | No target | 1,038 × 1,084 | – | Text, links, fields, title |
| Slide deck with photos (pdf-lib test file) | Target 75% | 497.9 KB | Yes | 1,038 × 1,084 | 29.3 dB | Text, links, fields, title |
| Slide deck with photos (pdf-lib test file) | Target 50% | 318.2 KB | Yes | 1,038 × 1,084 | 25.3 dB | Text, links, fields, title |
| Slide deck with photos (pdf-lib test file) | Target 25% | 187.2 KB | Yes | 1,038 × 1,084 | 20.4 dB | Text, links, fields, title |
| Slide deck with photos (pdf-lib test file) | Target 10% | 186.5 KB | No, smallest reached | 1,038 × 1,084 | 20.5 dB | Text, links, fields, title |
PSNR compares every page of the output with the same page of the input, drawn at 72 dpi. Higher means closer, and the table shows the worst page. A dash means no pixel moved at all.
Text documents barely shrink
The IRS Form 1040 went from 220.3 KB to 199.1 KB with the lossless rewrite, and no target below that was reachable. The US Constitution did the same: 389.7 KB to 363.5 KB, and no further. Their bytes are fonts, text and form structure, which have no lossy setting. A tool that makes such a file much smaller has either turned the pages into pictures, which loses the selectable text, or removed something you may need, such as the fonts.
When a text PDF is still too big for a form, splitting it is usually a better answer than squeezing it.
Photos and slides are where the bytes are
The photo page shrank to 386.1 KB at the first target. Its picture went from 1,920 × 1,080 to 1,339 × 753 pixels, and the worst page scored 45.2 dB, the closest to its original of any lossy result in the run. At the next target it reached 263.6 KB, with a 960 × 640 picture and 31.7 dB, and could go no smaller because the engine will not shrink a picture past its floor.
The 21-page slide deck reached 187.2 KB from 754.4 KB, a quarter of its size, with every link and page kept. Its worst slide scored 20.4 dB at that point, the lowest in the run: its screenshots lost fine detail to get there. If the deck is going to be read on a phone or attached to an email, that is often a good trade. If it is going to be printed, stop at the first target.
How to choose a setting
- Always start lossless. It costs nothing and sometimes is enough.
- If the file must fit a limit, type that limit, not a percentage. Our tool tells you plainly when a file cannot get that small, and how small it got.
- For a file you will print or archive, keep pictures near their original size: ask for no less than about three quarters of the original.
- For a mostly-text file that is still too big, split it rather than compress harder.
How we measured
We ran the site's own compress code, the same qpdf build and JPEG encoder the browser uses, in Node 22.23.4 on a 4-core Intel Xeon, on November 11, 2026. The four files are public and pinned by their SHA-256, so anyone can fetch the same bytes. Each output was read back with tools that are not ours: Poppler for pages, pictures, text and drawing, and pikepdf for links, fields and the title. Text was compared word for word after normalising whitespace. The script is in our repository, and the full results are in the table above.
A browser's JPEG encoder can differ slightly from Node's stand-in, and a phone is slower. The sizes will be close but not byte for byte the same on your device.