iLoveConverter
Categories 11 categories

The PDF (.pdf) Format, Explained

iLoveConverter Team 3 min read

On this page

PDF — Portable Document Format — is the reason your resume looks the same on your phone, a Windows laptop, a Mac, and a print shop’s prepress machine. Unlike HTML or Word documents which reflow text based on viewport and font availability, PDF locks every glyph, image, and line into exact positions. That makes it perfect for printing and archival, and awkward for editing on small screens.

How a PDF is built

A PDF file is a binary file organized as a sequence of objects:

  • Direct objects — numbers, strings, booleans, null, arrays, dictionaries, and streams (the only objects that hold large binary data like compressed page content).
  • Indirect objects — objects identified by an xref table entry, referenced by other objects.

A minimal PDF structure:

  1. Header (%PDF-1.7 — version number).
  2. Body — numbered indirect objects.
  3. Cross-reference table (or stream in PDF 1.5+).
  4. Trailer — points to the root object.
  5. StartXRef offset — tells readers where to begin.

Page content and streams

Each page has a Contents stream containing operators and operands:

BT                  % begin text
/F1 12 Tf           % set font F1 at 12 pt
72 720 Td           % move to position (72, 720)
(Hello World) Tj    % show text
ET                  % end text

Images are embedded as streams with Subtype /Image, a color space, width, height, and a filter (JPEG, FlateDecode, DCTDecode, CCITT for bilevel).

Font handling

PDF fonts are either embedded (font file included in the PDF) or referenced (just a name, hoping the viewer has it). Best practice: embed. PDF supports TrueType, OpenType CFF, and Type 1 fonts. Subset embedding (only the glyphs actually used) keeps PDFs small without breaking them.

Forms, annotations, and digital signatures

  • AcroForms — interactive form fields (text, checkboxes, dropdowns) with JavaScript validation.
  • Annotations — comments, highlights, sticky notes, links.
  • Digital signatures — cryptographically sign the PDF so recipients can verify the author and that the document has not been altered. Signatures are stored as Sig dictionary entries that reference a signed byte range.

Compression

PDF streams use various filters:

  • FlateDecode — DEFLATE/zlib, the default for page content.
  • DCTDecode — JPEG for photographs.
  • CCITTFaxDecode — bilevel (black/white) for scanned documents.
  • JBIG2Decode — better compression for bilevel scans, especially with repeated characters (text pages).
  • JPXDecode — JPEG2000.

PDF 2.0 (ISO 32000-2:2020) is the current standard, adding incremental improvements and deprecating some legacy features.

Converting to and from PDF

Common conversion tools:

ConversionTool
DOCX → PDFLibreOffice, Word
HTML → PDFwkhtmltopdf, Chrome print-to-PDF
PDF → DOCXpdf2docx, Acrobat
PDF → textpdftotext (poppler)
Compress PDFqpdf, Ghostscript

Always check PDF/A compliance for archiving: PDF/A-1B is the lowest bar; PDF/A-4 is current.

Common problems

  • Font missing warning — the PDF references a font your system lacks, so text reflows. Open in a PDF viewer that embeds fonts; re-export from the source with “embed fonts” checked.
  • Blurry images when zoomed — the PDF stores a low-resolution JPEG; replace with higher-res before export.
  • Scanned PDF is not searchable — the page is a single raster image, no text layer. Use OCR (Tesseract, Adobe Acrobat) to add one.
  • File too large — run through Ghostscript or qpdf to compress streams. Remove embedded thumbnails and unused fonts.

FAQ

Is PDF an open standard?

Yes. PDF was standardized as ISO 15900 in 2008 (PDF 1.7) and continues as ISO 32000 (PDF 2.0). The specification is free.

PDF vs PDF/A — what’s the difference?

PDF/A is an ISO-standardized subset of PDF designed for long-term archiving. It forbids features that could break over time (JavaScript, external references, some encryption). PDF/A-2 is a practical choice for most archival documents.

Why can’t I edit PDF easily?

Because PDF is a fixed-layout format. Text is positioned glyph-by-glyph, not stored as paragraphs. Editing tools (Acrobat, Illustrator) work by recognizing text blocks and approximating your changes — it is not like editing Word or HTML.

What is the difference between a PDF and a scanned PDF?

A “born-digital” PDF has actual text objects. A scanned PDF has raster images of pages, possibly with an invisible OCR text layer on top. Searchable scanned PDFs are best practice.

Try it yourself — free, right in your browser

Everything mentioned in this guide runs locally on this site: no upload, no watermark, no sign-up.

Format deep-dives: PDF (.pdf) , DOCX (.docx) , HTML (.html.htm) , TXT (.txt) , EPUB (.epub)