An open document format like PDF, but with animated GIFs.
Build your document with the MPDF tools or write it by hand.
Share the .mpdf file via email, chat, or any file transfer.
The recipient opens it in any browser. No install needed.
This document demonstrates the MPDF file format — an open standard for creating portable documents that support embedded animated GIF images.
The Portable Document Format has been the standard for document exchange for over three decades. MPDF extends this paradigm with animated GIF support.
| <!DOCTYPE mpdf> | Own doctype — identifies the format |
| data-mpdf-version | Versioned format (currently 1.0) |
| mpdf: meta tags | Standardized metadata (title, author, date) |
| mpdf-* CSS classes | Defined document structure |
| Standard stylesheet | Deterministic rendering everywhere |
| No <script> | Static document format — safe to open |
| Base64 data URIs | All media embedded inline — one file, no dependencies |
pip install mpdf
mpdf create -t "My Paper" -o doc.mpdf \
h1 "Title" text "Hello" gif fig.gif
mpdf validate doc.mpdf