How to Remove Metadata From a PDF(and Hidden Data)
A PDF stores metadata in two places: a document information dictionary (author, title, the software that made it, and creation and modification dates) and an XMP metadata block. On top of that it can carry hidden data that never shows on the page - comments, form fields, bookmarks, embedded thumbnails, attachments, and older versions of the content saved in the file's revision history. To remove it, clear the document properties and then save the file through a tool that rewrites it from scratch, because a plain re-save often leaves the old values behind.
What metadata does a PDF contain?
Two layers.
The document information dictionary is the older, simpler set of fields: Author, Title, Subject, Keywords, Creator (the program you wrote it in), Producer (the library that generated the PDF), and the creation and modification timestamps. Most viewers show these under File > Properties or Document Properties.
The XMP packet is a newer block of XML that can duplicate those fields and add more: editing history, the account or device that produced the file, color profiles, and application-specific tags. Many tools update the visible properties but leave the XMP packet untouched, so the same author name can survive in a place you never looked.
What can PDF metadata reveal about you?
More than most people expect. The Author and Creator fields often carry a full name or a company username pulled from the operating system. The Producer field names the exact software and version. Timestamps show when a document was drafted and last changed, which can contradict a stated date. Scanned files sometimes record the scanner model or the network path they were saved to.
Hidden data goes further. Comments and annotations can contain internal notes. Form fields keep values even after they look cleared. If a document was edited and saved incrementally, earlier text you thought you deleted can still be in the file, recoverable by anyone who opens it in a tool that can read those layers.
How to remove metadata from a PDF
The manual route in a desktop viewer:
- Open the file, go to File or the menu, then Document Properties.
- Clear the Author, Title, Subject, and Keywords fields. Check any Additional Metadata or Custom tabs and clear those too.
- If your viewer has a Sanitize or Remove Hidden Information command, run it. This is where comments, attachments, and leftover revision data get stripped.
- Save the result as a new file rather than overwriting the original.
A faster route that flattens everything: print the document to a new PDF (Save as PDF or Microsoft Print to PDF). This rebuilds the file from the visible page only and drops most metadata and hidden objects. The trade-off is that you may lose bookmarks, links, and the selectable text layer.
On the command line, exiftool clears the info dictionary and XMP, and qpdf or Ghostscript can rewrite the file to discard orphaned objects left behind by earlier edits.
Why editing the properties is not always enough
PDFs are often saved by appending changes to the end of the file instead of rewriting the file from scratch. This is called an incremental update. When you blank out the Author field and hit Save, some tools simply add a new instruction that says the author is now empty while the original value still sits earlier in the file. Anyone who inspects the raw bytes, or opens an earlier revision, can read it.
The fix is to save through a tool that rewrites the document as a single clean object stream, so nothing from the previous state carries over. Print-to-PDF does this, and so do proper sanitize functions.
Metadata and redaction are two separate jobs
Blacking out text on the page and cleaning metadata are different operations, and doing one does not do the other. You can perfectly delete a Social Security number from the visible page and still ship a file whose Author field names the person it belongs to. Several public document leaks came down to exactly this gap: the page looked clean, the properties did not.
If you are redacting sensitive content, use a tool that removes the page content and strips the metadata in the same pass. Our redactor does both. It deletes the text, image, and vector data under each box and clears the document metadata when it writes the output, so there is no second cleanup step to forget. It runs in your browser, so the file is never uploaded.
How to check the metadata is actually gone
Reopen the finished file and look at Document Properties again. Every field you cleared should be blank. For a deeper look, open the PDF in a plain text editor or run exiftool on it and scan for names, usernames, or software strings. If you still see old values, the file was saved incrementally; rewrite it with print-to-PDF or a sanitize step and check again.
For anything confidential, pair this with the copy test: select the text on each page and paste it elsewhere to confirm nothing hidden comes through. There is more on that in is PDF redaction reversible.
FAQ
Does saving a PDF remove its metadata?
No. A normal save usually keeps the metadata, and can even preserve old values in the file's revision history. You have to clear the fields and rewrite the file, or use a sanitize command.
Does printing to PDF remove metadata?
Mostly yes. Printing to a new PDF rebuilds the file from the visible page and drops most metadata and hidden objects. You may lose bookmarks and the selectable text layer in the process.
Is metadata the same as redaction?
No. Redaction removes content from the page. Metadata lives outside the page, so a redacted document can still leak names and dates through its properties unless you clear those separately.
Ready to clean a file? Redact a PDF for free in your browser. The content is removed and the metadata is stripped before you download it.