How to Flatten a PDF
Flattening a PDF converts editable form fields, annotations, and comments into static page content. After flattening, you cannot click into a form field to change its value, drag an annotation, or edit a comment — they are baked into the page. This guide covers why you would flatten, the trusted local tools that do it, and the honest state of IXPDF's research.
Why flatten a PDF?
- Lock a filled form. You filled out a PDF form and want to share it without the recipient accidentally editing the fields. Flattening turns the field values into static text.
- Preserve annotations. You marked up a document with highlights, shapes, or stamps and want to share it so the markup cannot be removed or changed.
- Print reliably. Some printers and print pipelines do not render form fields or annotations correctly. Flattening converts them to regular page content that prints reliably.
- Prevent further edits. Flattening is a one-way operation — once flattened, the form fields are gone. This is useful for finalizing a document before sharing or archiving.
- Reduce file size (sometimes). Form fields and annotations carry their own data structures. Flattening can shrink the file, though not always.
What flatten does to the file
A PDF with form fields has AcroForm or XFA field dictionaries that describe each field: its name, type (text, checkbox, radio, dropdown), value, and appearance. Annotations (highlights, shapes, stamps, comments) are stored as annotation dictionarieson each page. When you flatten:
- The field's current value is drawn as static text/graphics on the page.
- The annotation's appearance is drawn as static content on the page.
- The field and annotation dictionaries are removed from the file.
- The page's content stream is rewritten to include the baked-in appearance.
The result looks identical to the original, but the form fields and annotations are gone — they are now part of the page content.
Three tools that flatten a PDF locally
Every option below runs on your machine. None of them upload your document. For a filled form with sensitive data (medical intake, tax filing, legal disclosure), that matters — the file should not travel to a "free online PDF flattener" before being flattened.
1. Adobe Acrobat Pro (paid)
Acrobat Pro has a dedicated flatten step in the Print Production workflow. Open the PDF, then Tools > Print Production > Flattening Preview. Configure the options (form fields, annotations, or both), click Apply, and save. Acrobat Pro also lets you flatten via the Print to PDF trick: File > Print > Print to PDF flattens form fields and annotations in the output. Acrobat Standard and the free Adobe Reader cannot flatten via Print Production — only Pro can. Reader can flatten via Print to PDF in some versions.
2. Preview (macOS, free)
Preview does not have a "flatten" button, but the Print to PDFtrick works: open the PDF, choose File > Print, then in the print dialog click Save as PDF at the bottom. The saved PDF has form fields and annotations baked into the page content. This is the simplest free option on a Mac and works for most forms. It does not always handle XFA forms correctly — those are Acrobat-only.
3. qpdf (command line, free, cross-platform)
qpdf does not have a single "flatten" command, but it can flatten rotations and normalize the file. For form fields and annotations, pair qpdf with a Python script using pypdf to walk the fields, draw each field's appearance onto the page, and remove the field dictionary. This is the most reproducible option if you are comfortable with the command line. For a simple flatten, thepdftoppm + img2pdf round-trip rasterizes the pages (lossy — you lose selectable text), so prefer thepypdf approach for text-quality output.
Step-by-step: flatten a PDF with Preview (macOS)
- Open the PDF in Preview.
- Choose File > Print from the menu (or press Cmd+P).
- In the print dialog, click the PDF dropdown at the bottom.
- Choose Save as PDF.
- Name the file and click Save.
- Verify: open the saved file and try to click into a form field. It should be static text, not an editable field.
Step-by-step: flatten a PDF with Adobe Acrobat Pro
- Open the PDF in Adobe Acrobat Pro.
- Go to Tools > Print Production.
- Click Flattening Preview.
- In the dialog, choose what to flatten: Form Fields,Annotations, or both. Pick Transparencyif the document has transparency that should be flattened too.
- Click Apply.
- Save the flattened PDF with File > Save.
- Verify: reopen the file and try to edit a form field or annotation. It should be static content.
Flatten vs. other "lock" operations
Flattening is one of several ways to "lock" a PDF. They do different things:
- Flatten converts form fields and annotations to static content. The fields are gone. The content is still selectable and copyable. File size may shrink.
- Password protect encrypts the file so it cannot be opened without a password. The form fields are still editable once opened. See How to Password Protect a PDF.
- Owner-password restrictions (no edit, no print) are enforced by the viewer, not the file. A non-cooperating viewer can ignore them. See How to Password Protect a PDF.
- Rasterize converts each page to an image. This flattens everything but loses selectable text and increases file size. Use only when you need a flat image of each page.
Common mistakes
- Flattening the only copy. Flatten is irreversible. Keep a copy of the original if you might need to edit the fields.
- Flattening before filling. Flatten after you have filled every field. Flattening an empty form makes the empty fields permanent — you cannot fill them later.
- Using a "free online" flattener for a sensitive form.The filled form is uploaded to a server before flattening. For a medical intake or tax form, use a local tool.
- Expecting XFA forms to flatten in non-Acrobat tools.XFA (XML Forms Architecture) is an Adobe-only form technology. Most non-Acrobat tools either fail silently or produce a broken file. If your form is XFA, use Acrobat Pro.
- Confusing flatten with password protect. Flatten bakes fields into the page; password protect encrypts the file. They solve different problems.
- Not verifying. After flattening, open the file and try to click a form field. If it is still editable, the flatten did not work.
Add a watermark locally today
IXPDF's Add Watermark tool stamps text on every page in your browser — your file never leaves your device. Flatten is Research Required; until then, use Preview or Acrobat Pro for that.
Open Add WatermarkTry it now
Ready to put this into practice?
Run the tool locally in your browser — no upload, no account, no watermarks. Your file never leaves your device.