Extract embedded files and attachments from PDFs
Most people think of a PDF as digital paper, but it can actually act a lot like a ZIP archive.
The PDF specification explicitly allows you to embed arbitrary external files (like Word documents, Excel spreadsheets, XML data, or even other PDFs) completely inside the host file's structure.
These attached files are not drawn or stored on the visual pages themselves. They are stored in a specialized data structure in the document's root dictionary called the Name Tree.
Specifically, attachments live in the /EmbeddedFiles node. Each attached file is stored as a compressed binary stream accompanied by a dictionary containing metadata like the filename, creation date, and MIME type.
When you use this tool to extract an attachment, we use WebAssembly to parse this Name Tree and locate the binary stream associated with the file you clicked.
If the stream is compressed (usually using the FlateDecode algorithm, which is standard zlib compression), our engine decompresses it in memory and triggers a standard browser download of the raw binary data.
Where are attached files (like an embedded Excel sheet) stored inside a PDF?