Flatten a PDF
in your browser.
Lock interactive form fields and annotations into static visuals. Recipients see the values but can't change them. No upload.
Verify yourself: open DevTools → Network tab → drop a file. Watch zero uploads happen.
Three steps. Your file never leaves this tab.
Drop your filled PDF
Pick the filled-out form. It loads into your browser's memory, not a server.
Click Flatten
We bake the field values and annotations into the page itself, removing the interactive layer.
Download the locked copy
The result looks identical, but recipients can't change the values. The original file stays untouched.
Baking the form into the page
The reasons to flatten a PDF are usually about freezing what's currently visible. A tax form filled in by typing into the PDF needs to go to an accountant — the recipient should see the answers but not be able to edit them. A signed agreement was completed with a filled signature field — sending it on, the field shouldn't still be a clickable form element that someone could overwrite. A scanned document that came back from someone with annotations and stamps needs to circulate to a wider audience without the annotations layer being editable. A printable booklet was authored in InDesign with interactive form widgets that should appear as static placeholders when laid out for print. The job here is small and predictable: take a PDF with form fields or annotations and convert their current visual state into permanent page content.
What you get back is a PDF that looks the same on screen but no longer has interactive elements. Every field that was filled in keeps its filled value as static text. Every empty field becomes whatever its background showed (often a grey rectangle, sometimes nothing visible at all). Annotations and stamps similarly bake into the page.
What flattening actually does
PDF stores form fields as a separate layer on top of the page. The page itself has no idea what the form contains; the field widget is laid over it at view time and the field's current value is rendered into the visible area. Flattening collapses that layer — it walks every field, captures its visual state at the moment of flattening, draws that capture as ordinary page content (text, lines, checkboxes drawn as paths), and then removes the form definition itself.
The result is one continuous static page where what you saw is what's drawn. There's no longer a "form" in the document. A reader looking at it cannot tell that it ever had fields, and no PDF tool can re-edit the values without OCRing the page from scratch.
What gets flattened, what doesn't
- Form fields (AcroForm). Text inputs, checkboxes, radio buttons, dropdowns, list boxes, signature fields, button fields. All of these flatten — their current value or selection becomes static page content.
- Empty fields keep their appearance. An unfilled text box still has its border and (often) a placeholder line; that visual stays as drawn shapes. An unchecked checkbox stays as an empty box.
- Calculated fields capture their current value. Fields with formulas (Acrobat Pro feature) freeze at the value they currently display — the formula is gone after flattening.
- Annotations may or may not flatten. Comment notes, highlights, and stamps depend on the viewer that wrote them; pdf-lib's form.flatten() targets AcroForm specifically. If you need annotations gone too, the right path is a full export from the source viewer.
- Existing static page content is untouched. Text, images, layout, bookmarks all carry over unchanged.
What survives and what doesn't
- The visible content stays the same. Text, images, layout, fonts, and form values as they appeared at the time of flattening — preserved exactly.
- Bookmarks, links, page structure all carry over. Flattening targets the form layer, not the document outline.
- Form interactivity is gone. No more clickable fields, no more dropdown selections, no more "tab to next field". This is the point of the operation.
- Digital signatures are invalidated. Any modification to the document, including flattening, breaks signature bindings. If a document is signed and the signature must remain valid, do not flatten — duplicate the file and flatten the duplicate.
- The operation is one-way. Once flattened, there's no un-flatten. The form definition is gone. To re-edit, you'd need to recreate fields from scratch using a PDF editor that supports form authoring.
If something looks off
- "Nothing happened" — no fields to flatten. The PDF didn't contain an AcroForm. The tool re-saves the file as-is in this case; the result is functionally identical to the input. To check if a PDF has form fields, open it in Adobe Reader and look for "Highlight Existing Fields" — if no fields appear, there's nothing to flatten.
- Some annotations didn't bake. The form.flatten() pass only flattens AcroForm widgets. Annotation-style overlays (sticky notes, highlight markup, freehand drawing) need a different operation. For those, re-export from the original viewer or use edit-pdf to consolidate annotations first.
- Filled values look wrong after flattening. The flattened representation captures what was drawn at the moment of operation. If the form had a font substitution or a field that displayed differently than expected, the bake captures that. Check the source PDF in a viewer first — the flatten will preserve whatever you see there.
- The PDF is encrypted. Run it through unlock-pdf first; encrypted PDFs cannot be modified.
Common reasons to flatten
- Sending a filled form to someone who shouldn't edit it. Tax returns to an accountant, contracts to counsel, employment forms to HR — flattening locks the values in place.
- Combining filled forms into a single archival document. Different copies of the same form filled by different people, merged into one bundle. Flatten each before merging so each copy retains its values without colliding field IDs.
- Preparing for printing or public distribution. Printed PDFs don't honour interactivity anyway, but a viewer that opens the file before printing might show fields differently than the print output. Flatten first to guarantee the screen and the page match.
- Removing fillable behaviour from a template. A template that was authored with sample values in the fields, ready to ship as a finished example. Flatten freezes the example values in place.
Practical notes
- Flatten last. If you also need to add page numbers, watermark, or compress — do those operations first while the document is still editable. Flattening once forecloses changes that depend on form awareness.
- Keep the original. The flattened version replaces functionality you can't get back. Save the editable source in case you need to update values later, then re-flatten.
- Test on one page first. If the document is large and you're unsure how the bake will look, split off a sample page via split-pdf, flatten the sample, check the result in a viewer, then flatten the full document.
- The original file stays untouched. What you download is a new flattened PDF; the source on your disk is unchanged.
What happens to your file
Flattening runs in your browser. Open DevTools and watch the Network tab during the operation — there are no outbound requests carrying the file content. The PDF stays on your disk; the flattened version is a new download alongside it.
Frequently asked
What does flatten mean?
Flattening converts interactive layers — form fields, annotations, comments — into static page content. Visually nothing changes, but the values are now part of the page itself and no longer editable.
Why would I flatten a PDF?
To send a final, non-editable copy: a signed contract, a filled-out tax form, a reviewed proposal. Flattening prevents recipients from accidentally (or intentionally) changing the values.
Will the document look different?
No — flattened pages render identically to how they looked before. The change is structural, not visual: form fields become baked-in text, annotations become baked-in marks.
Does it work on PDFs without forms?
Yes. If there are no fields or annotations, flattening is essentially a no-op pass that re-saves the document. Most useful when you have form fields or sticky-note annotations to lock down.
Where does my file go?
Nowhere. Flattening happens entirely in this browser tab. Verifiable in DevTools → Network: no upload happens.