By Tim King · Updated
Flatten PDF
Lock Form Fields, Comments and Stamps Into the Page So They Cannot Be Edited
OneTask is free, with no sign-up, and built by one person.
If this tool saved you time, a coffee helps keep new ones coming.
How the Flatten PDF works
Flatten PDF forms and comments so what you see is fixed into the page. Choose whether to include comments, drop the file in and download the flattened copy. The work happens in your browser, so the PDF never leaves your computer.
A filled PDF form is two things layered together: the printed page, and a set of live fields that float on top of it. The same goes for comments, highlights and stamps added in a reader. Each layer can be edited, moved, hidden or lost depending on the app that opens the file. Flattening merges the top layer into the page, so the file looks the same everywhere and nothing can be changed by clicking on it.
Why flatten a PDF
- Sending a finished form. A signed application, invoice or tax form should not be editable by the next person who opens it. Flattened fields cannot be retyped.
- Printing and merging. Some printers and older merge tools drop live fields entirely, so a form prints blank. Flattened values are ordinary page content and always print.
- Mobile and browser viewers. Many lightweight viewers show form fields poorly or not at all, and some show comments as tiny icons. After flattening, every viewer shows the same page.
- Archiving. A record that will be kept for years should not depend on a reader's form support.
- Sharing a reviewed draft. Flattening comments turns highlights, sticky notes and stamps into marks on the page, so a reviewer's markup cannot be edited or deleted by the recipient.
How Flatten PDF works
The file is opened with pdf-lib, an open-source PDF library, inside your browser.
Form fields only reads every field in the form. Each field's visible appearance, the drawing a reader shows for its current value, is painted onto its page at the field's position. The field and the form structure are then removed. Text boxes, checkboxes, radio buttons, dropdowns and list boxes all keep their current look.
Form fields and comments also goes through every annotation on every page. Annotations that have an appearance, which includes highlights, underlines, ink drawings, shapes, stamps and free-text notes, are drawn onto the page in the same way and then removed. Pop-up note windows and hidden annotations have no place on the printed page, so they are removed without being drawn. Links are always kept, because a link is not a mark and flattening it would just break it.
| Item | Form fields only | Fields and comments |
|---|---|---|
| Text fields, checkboxes, dropdowns | Flattened | Flattened |
| Highlights, ink, shapes, stamps | Kept as comments | Flattened |
| Sticky-note pop-ups | Kept | Removed |
| Links | Kept | Kept |
Tips and pitfalls
Keep the original. Flattening cannot be undone. Save the editable form first in case a value needs to change later.
Check the fields are filled the way you want. A field shows whatever value it holds when it is flattened. If a reader saved a value without updating its appearance, open and save the form in a form filler first so the appearance matches.
Digital signatures. A cryptographic signature covers the exact bytes of the file. Any change, flattening included, breaks it. Flatten before signing, never after.
Sticky-note text is lost. A note's comment text lives in its pop-up, not on the page. Only its icon is drawn. If the wording matters, copy it out or use a reader's "summarise comments" export.
Hidden fields stay hidden. A field marked as hidden or no-print has nothing to draw, so it simply disappears.
How to read the result
The stats show how many pages the file has, how many form fields were flattened, how many comments were drawn onto pages and how many pop-ups or hidden notes were removed, plus the file sizes before and after. If the file has nothing to flatten you get a message instead of an unchanged copy.
FAQ
What does flattening a PDF do?
Flattening turns form fields and comments into ordinary page content. The values, checkmarks and markup stay exactly where they were and look the same, but they can no longer be clicked, typed into, moved or deleted, and every viewer and printer shows them.
Can I unflatten a PDF?
No. Once a field is flattened its value is just text drawn on the page, with no field behind it. Keep the original editable copy if you might need to change anything, and flatten a fresh copy each time.
Why do my form answers disappear when I print?
Some printers, print drivers and older readers only print the base page and skip live form fields. Flattening draws the answers into the page itself, so they print every time on any device.
Is my PDF uploaded to flatten it?
No. The PDF is opened and flattened by your browser on your own device. Nothing is sent to a server, so completed forms with personal details stay private.
See also: all PDF tools, Images, Audio, Video & Screen, SVG, Simulations & Screensavers, Generative Art, Chart Makers, 3D Model Viewers, Drawing Pads, Mockups & 3D Making, Diagram Makers, 3D Science, Tracker Music.
Related tools
Fill PDF Form
List a PDF form's fields and fill them in.
PDF Metadata Editor
Edit a PDF's title, author, subject and keywords.
PDF Merger
Combine PDFs into one file in your browser: nothing uploaded, pages in any order.
PDF Watermark
Stamp text across every page of a PDF, in-browser.
PDF Page Numbers
Stamp page numbers on every page of a PDF, any position.