Problem → SolutionApril 2, 20264 min read

File Saved as PDF Is Not Recognized as PDF

A file saved with a .pdf extension that other applications refuse to open as a PDF, or that shows a MIME type error, is not actually a PDF despite its filename. Here's how to diagnose and fix unrecognized PDF files.

A file with a .pdf extension that applications refuse to open with errors like "not a valid PDF," "file format not supported," or "unable to open" is not actually a PDF file. Files can be renamed to .pdf without becoming PDFs — the extension is just a label. The actual file format is determined by the content, not the name.

How to Identify the Actual File Format

Open the file in a text editor (Notepad on Windows, TextEdit on Mac in plain text mode). Look at the first 4-5 characters. A genuine PDF starts with %PDF- followed by the version number (e.g., %PDF-1.7). If you see something else — HTML tags, XML declarations, "PK" (a ZIP file), binary data, or a Microsoft OLE2 header — the file is not a PDF despite its extension. Note what you see, as that identifies the real format.

Common Disguised File Types

Files frequently mislabeled as PDF: (1) HTML pages saved as .pdf — open in a browser and use File → Print → Save as PDF to convert. (2) Word documents (.docx) renamed to .pdf — rename back to .docx and open in Word, then export as PDF. (3) Image files (JPEG, PNG, TIFF) renamed to .pdf — rename with the correct extension, open, and convert via a proper PDF converter. (4) Corrupt downloads — the file is truncated mid-download, starting with valid PDF header but ending abruptly. Re-download the file.

Check File Integrity

Use FixMyPDF PDF Inspector to analyze the file structure. It reports whether the file has a valid PDF header, a consistent cross-reference table, and correctly structured page objects. If the inspector cannot parse the file at all, the file is not a PDF. If it can partially parse it, the file may be a truncated or corrupted valid PDF that needs repair.

Files Generated by Broken Export

Some applications generate invalid PDF output under certain conditions: running out of disk space mid-save, a crash during PDF generation, or a buggy PDF library. Signs: the file starts with %PDF- but has no pages, has an empty cross-reference table, or ends without the required %%EOF marker. These partially-valid PDFs may be repairable with Ghostscript: gs -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=recovered.pdf broken.pdf — Ghostscript attempts to extract whatever valid objects are present and writes a new valid PDF.

Try PDF Inspector Now — Free

Browser-based, private, and instant. No account or software required.

Open PDF Inspector
Report Bug
Send Feedback
Feature Request