What Is a PDF File and How Does It Work?
What Is a PDF File and How Does It Work?
PDF (Portable Document Format) is the most widely used document format on earth — used for contracts, bank statements, government forms, academic papers, and ebooks. Yet most people who use PDFs daily have no idea what is actually inside them.
The Core Purpose of PDF
PDF was created by Adobe in 1993 with one goal: make a document look identical regardless of where it is opened. Before PDF, a document created on one computer often looked completely different when opened on another — different fonts, different margins, different line breaks.
PDF achieves this by embedding everything the document needs inside the file itself: fonts, images, layout instructions, and metadata. A PDF opened on Windows 95 and Windows 11 looks identical.
What Is Inside a PDF File?
A PDF is a structured binary file containing:
1. Objects Everything in a PDF is an "object" with a number. Objects include:
- Page descriptors (dimensions, rotation)
- Text streams (the actual characters, compressed)
- Image data (JPEG, PNG, or raw pixels embedded directly)
- Font definitions (the font metrics and glyph descriptions)
- Annotation objects (comments, form fields, links)
2. Cross-Reference Table (xref) An index at the end of the file mapping every object number to its byte position. When you open a PDF, the viewer reads this table first to know where to find everything.
3. Trailer A small section at the very end that tells the viewer where the xref table starts. It is the entry point for reading the entire file.
Advertisement
Why PDFs Look the Same Everywhere
When a PDF is created, fonts are embedded inside the file. The viewer does not use the fonts installed on your computer — it uses the fonts stored in the PDF itself. This is why a PDF designed in a custom corporate font looks correct even on a computer that has never had that font installed.
Why PDFs Are Sometimes Large
PDF size is driven by:
- High-resolution embedded images — a single 300 DPI scanned page can be 2–5 MB
- Full font embedding — every non-system font is stored complete inside the file
- Revision history — each incremental edit adds a new layer without deleting the old one
Why PDFs Get Corrupted
The xref table is written last when saving a PDF. If the application writing the file crashes or loses connection before the xref is written, the file body is intact but there is no directory — viewers cannot find any content.
This is why a corrupted PDF often:
- Fails to open in strict viewers (Adobe Reader checks the xref strictly)
- But opens partially in lenient viewers (Chrome's pdf.js scans the file body directly)
A PDF repair tool fixes this by scanning the body, reconstructing the object list, and writing a new valid xref.
PDF Versions and Standards
| Standard | Year | Purpose |
|---|---|---|
| PDF 1.0 | 1993 | Original format |
| PDF 1.7 | 2006 | Added 3D, digital signatures |
| PDF 2.0 (ISO 32000-2) | 2017 | Open standard, improved encryption |
| PDF/A | 2005 | Archival — self-contained, no external references |
| PDF/X | 2001 | Print production — embedding requirements |
| PDF/UA | 2012 | Universal accessibility — screen reader support |
Is PDF Editable?
A basic PDF is not directly editable — by design. To edit a PDF you need:
- Adobe Acrobat (paid) — full editing capability
- LibreOffice Draw (free) — basic text and image editing
- Convert back to DOCX — if you need to make major changes and have the original
- Form fields — if the PDF has form fields, you can fill them in any PDF viewer
For most users, the best workflow is: edit the source document (Word, Google Docs) and re-export to PDF rather than editing the PDF directly.