Open E-Book Standard.epubMIME: application/epub+zip

EPUB Format Specification: Reflowable E-Books, XHTML & Open Web Standards

Understand the open e-book packaging standard: reflowable typography, OPF package manifests, and client-side conversion.

EPUB (Electronic Publication) is the universal open standard for digital books and publications maintained by the W3C. Designed as a reflowable document format, EPUB automatically optimizes text layout, font size, and pagination to suit screens from small smartphones to massive desktop monitors. Internally, an EPUB file is a structured ZIP archive containing XHTML web pages, CSS stylesheets, embedded SVG illustrations, and an XML package document (OPF).

Format Specification & Header Signature

Core file signatures, developer metadata, and standard RFC specifications:

Magic Bytes (Hex Signature)50 4B 03 04 (PK.. - standard ZIP archive signature)
MIME Media Typeapplication/epub+zip
Standard / SpecificationW3C EPUB 3.3 Recommendation
Initial Developer / OrganizationInternational Digital Publishing Forum (IDPF) / W3C (2007 (EPUB 3 in 2011))
Container StructureOCF (Open Container Format - ZIP Archive)
Markup LanguageXHTML 1.1 / HTML5 Web Standards
Styling EngineCSS 2.1 / CSS3 Responsive Media Queries
Packaging ManifestOPF (Open Packaging Format XML)

Operating System & Browser Compatibility Matrix

Where .epub is natively supported without third-party codecs:

Platform / EnvironmentNative SupportImplementation Notes
macOS / iOSSupportedNative reader in Apple Books with iCloud sync across all devices.
AndroidSupportedSupported via Google Play Books, Moon+ Reader, and ReadEra.
WindowsSupportedSupported via Adobe Digital Editions, Thorium Reader, and Calibre.
LinuxSupportedNative support via Foliate, FBReader, and Calibre.

Advantages of Electronic Publication

  • •Reflowable responsive typography adapts automatically to any viewport and font size.
  • •Constructed entirely on open, accessible W3C web standards (HTML5, CSS3, SVG).
  • •Significantly smaller file footprint than fixed-layout PDF document files.
  • •Full accessibility support including text-to-speech audio synchronization.

Limitations & Trade-Offs

  • •Fixed-layout magazines and complex multi-column scientific papers are better suited to PDF.
  • •Legacy e-ink readers may not support modern CSS grid or interactive JavaScript elements.

Open Container Format (OCF) Internal Directory Hierarchy

Every valid EPUB file contains an uncompressed mimetype file containing application/epub+zip at exact byte offset 38.

The META-INF/container.xml file instructs e-readers where to find the root OPF package file. The OPF file specifies the book title, author, spine order of chapter XHTML files, and table of contents.

Frequently Asked Questions about Electronic Publication

How does EPUB differ from PDF?

PDF preserves exact fixed physical coordinates for printing, whereas EPUB reflows text dynamically to fit whatever screen size or zoom level the reader chooses.

Can I convert Markdown to EPUB?

Yes! Markdown easily compiles to XHTML chapters, which are then packaged with CSS and an OPF manifest into an EPUB file.