How to Flatten a PDF (And Why You Sometimes Need To)

Flattening a PDF merges all layers into a single document. Here's when and how to do it, with free tools and step-by-step instructions.

By PeacefulPDF Team

You filled out a PDF form. Everything looks great. You send it to HR. A week later, they email back: "The form is blank. Can you fill it out again?"

What happened? You filled in the form fields. You can see your answers. But HR opened the form and saw empty boxes because your computer didn't actually save what you typed into the form structure. It just remembered your input locally.

Flattening would have fixed this.

What Does Flattening a PDF Mean?

Flattening takes a PDF that has layers — annotations, form fields, comments, overlays — and merges everything into a single, unified document. After flattening, the form data isn't separate data in a field structure. It's baked into the document as visible text or images.

Think of it like this:

  • Unflattened PDF: Like a Photoshop file with layers. The background is one layer, the text is another, the annotations are a third. You can still move, edit, or delete each layer separately.
  • Flattened PDF: Like a JPG image. Everything merged into one. You can't separate the background from the text anymore.

Why Flatten a PDF?

There are solid reasons to flatten a PDF:

1. Form Fields That Don't Save

This is the big one. Some PDF forms don't actually save the form data — they just display your input while you have the file open. When you open the form elsewhere, it's blank. Flattening converts your input into regular text that saves as part of the document.

2. Preventing Edits

If you want to share a document but don't want people changing it, flattening helps. Annotations, comments, and markup tools usually don't work on flattened content. Someone can still edit the PDF using specialized tools, but it's harder than just clicking and typing.

3. Consistent Rendering

Layers and annotations can render differently in different PDF viewers. What looks like a perfect highlight in Adobe Reader might overlap text strangely in Chrome. Flattening removes that variability — everyone sees exactly the same thing.

4. Smaller File Size

Sometimes. Flattening removes the overhead of maintaining multiple layers and can reduce file size. But sometimes it increases size because it converts vector annotations into images. It depends on the document.

5. Printing Reliability

Printers sometimes struggle with complex layered PDFs. Annotations might not print, form fields might be empty, or colors might shift. Flattened documents are more predictable when printing.

6. Redaction Preparation

Before redacting a PDF, flattening can help ensure all content is accessible and nothing is hidden in layers that the redaction tool might miss. (Though dedicated redaction tools handle this natively.)

7. Converting to Images

If you need to turn a PDF into a set of images (JPG, PNG), flattening first ensures everything renders correctly — including form data, annotations, and overlays.

What Flattening Does to Your PDF

Let me be clear about what gets flattened and what doesn't:

Does Flatten:

  • Form field data (converts field content to regular text)
  • Annotations (highlights, underlines, strikeouts)
  • Comments and sticky notes
  • Digital signatures (but this breaks them — more on that later)
  • Overlays and watermarks
  • Some types of 3D content

Doesn't Flatten:

  • The document's basic structure (pages remain pages)
  • Bookmarks and navigation (usually)
  • Metadata (you need separate metadata removal)
  • Embedded fonts (though they're still required for proper rendering)
  • Hyperlinks (some flatteners keep them, some don't)

How to Flatten a PDF

Method 1: Browser-Based Tool (Easiest)

The quickest way is with an online tool. Our PDF flatten tool does this right in your browser:

  1. Open the Flatten PDF page
  2. Drop in your PDF
  3. Wait for it to process
  4. Download your flattened file

Since everything happens in your browser, your file never leaves your device. This matters if your PDF contains sensitive information.

Method 2: Adobe Acrobat Pro

Adobe Acrobat Pro has a built-in flatten feature:

  1. Open your PDF in Acrobat Pro
  2. Go to Tools → Print Production → Preflight
  3. Search for "flatten"
  4. Run the "Flatten annotations and form fields" profile
  5. Save the output

Acrobat also has a simpler approach: print to PDF. When you print to a new PDF, it automatically flattens everything.

Method 3: Preview on Mac

Mac's Preview app can flatten PDFs indirectly:

  1. Open the PDF in Preview
  2. Fill in any form fields
  3. Go to File → Print
  4. Click "Save as PDF" at the bottom
  5. Save the new file

The printed PDF will have everything flattened. It's a workaround, but it works well for basic documents.

Method 4: Print to PDF (Any Platform)

This works on Windows, Mac, and Linux:

  1. Open the PDF in your preferred viewer
  2. Make sure form fields are filled and annotations are visible
  3. Go to File → Print
  4. Select "Save as PDF" or "Print to PDF" as the printer
  5. Print and save to a new file

The printed version will be flattened. The catch is you lose interactive elements — bookmarks might disappear, embedded fonts might get substituted, and navigation can get weird. For simple documents it's fine. For complex ones, use a proper flatten tool.

Method 5: Command Line with Ghostscript

Ghostscript is a powerful PDF processing tool that can flatten documents:

gs -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/ebook -sOutputFile=flattened.pdf input.pdf

This command tells Ghostscript to rewrite the PDF, which naturally flattens annotations and form fields. It's especially useful for batch processing — you can flatten hundreds of PDFs with a simple script.

Method 6: PDF-XChange Editor (Windows)

PDF-XChange Editor has a dedicated flatten feature:

  1. Open the PDF
  2. Go to Document → Flatten Pages
  3. Select what to flatten (annotations, form fields, etc.)
  4. Click OK

PDF-XChange is faster than Acrobat for many operations and has a one-time purchase option instead of Adobe's subscription.

When NOT to Flatten a PDF

Flattening is useful, but it's not always the right choice:

You Need to Edit the Form Later

Once you flatten, you can't just click and edit form fields. The data is now static text. If you might need to revise the form, keep the original unflattened copy.

You Need the Data Extractable

Some workflows rely on extracting form data automatically. Flattening breaks this — the data is no longer in a structured format that can be parsed.

You Need Digital Signatures

Flattening invalidates digital signatures. If you need a document to verify as signed, flattening will break that. Sign after flattening, or use a signature method that allows for post-signing modifications (some do).

You Need Searchable Text

Some flatten tools convert text to images, making the PDF unsearchable. Our flatten tool and most modern tools preserve text, but it's worth checking. A flattened PDF should remain searchable unless you specifically rasterize it.

Flattening vs. Merging

These get confused sometimes:

  • Flattening merges layers within a single PDF. One file in, one file out.
  • Merging combines multiple PDFs into one. Multiple files in, one file out.

They're different operations for different purposes. You might merge several PDFs and then flatten the result. Or flatten each file and then merge them. Depends on what you're doing.

Flattening and File Size

I mentioned this earlier, but let me expand on it. Flattening's effect on file size varies:

Smaller:

Annotations and form fields carry overhead. Removing this structure can reduce size, especially for documents with lots of markup.

Larger:

Some flatten tools convert annotations to bitmap images instead of vector shapes. A vector highlight is just a few lines of code. A bitmap highlight at high resolution is thousands of pixels. The result can actually increase file size.

What to Do:

If file size matters, compress the PDF after flattening. Compression can recover size from any image bloat introduced by flattening.

A Real-World Example

My accountant sends me a PDF tax form every year. I fill it out, sign it, and email it back. The first time I did this, I opened the form on my phone, typed in the answers, saved, and sent it.

The accountant called: "The form is blank. Did you actually fill it out?"

I checked on my computer — yes, it was filled in. But the form viewer on my phone wasn't saving the data into the form structure. It was just displaying my input locally.

Now I flatten the form before sending. All my answers are baked into the document as static text. The accountant can open it on any device and see everything correctly. Problem solved.

Common Flattening Issues

Issue: Some Annotations Don't Flatten

Certain types of annotations (like 3D content or multimedia) might not flatten properly depending on the tool. Solution: remove or manually handle these annotations before flattening.

Issue: Text Becomes Unsearchable

Some flatten tools rasterize the entire page into an image, making it unsearchable. Solution: use a tool that preserves vector text, or run OCR after flattening.

Issue: Formatting Shifts Slightly

Flattening can cause minor layout changes — especially if form fields had different fonts or spacing than the document body. Solution: review the flattened PDF carefully and compare it to the original.

Issue: Hyperlinks Disappear

Some flatteners remove hyperlinks. Solution: add links back after flattening, or use a tool that preserves them.

Best Practices

  • Keep the original. Always save a copy of the unflattened document. You never know when you might need to edit it.
  • Verify the output. Open the flattened PDF and check that everything looks right. Test in multiple PDF viewers if possible.
  • Consider compression. If file size matters, compress the PDF after flattening.
  • Remove metadata. For sensitive documents, strip metadata after flattening.
  • Test with the recipient. If you're sending to a specific person or system, confirm the flattened PDF works on their end.

The Bottom Line

Flattening is one of those tasks that seems technical but is actually straightforward once you understand it. It solves real problems — especially with form data that doesn't save properly and documents that render inconsistently across viewers.

For one-off flattening, a browser-based tool is the fastest option. For batch processing, Ghostscript or a dedicated tool like PDF-XChange Editor works well. And if all else fails, the old print-to-PDF workaround gets the job done.

Just remember: flattening is permanent. Keep your original, verify the output, and you're good to go.

Ready to try Flatten PDF?

No uploads, no sign-ups. Everything happens in your browser.

Try Flatten PDF Free →