|Internet media type||
|Magic number||PK 0x03 0x04|
|Developed by||International Digital Publishing Forum (IDPF)|
|Initial release||September 2007|
(June 26, 2014)
|Type of format||e-book file format|
|Contained by||OEBPS Container Format (OCF; Zip)|
|Extended from||Open eBook, XHTML, CSS, DTBook|
|Standard||ISO/IEC TS 30135|
An EPUB is an e-book that can be downloaded and read on a device like a smartphone, tablet, computer, or e-reader. It is a free and open standard published by the International Digital Publishing Forum. The term is short for electronic publication and is sometimes styled ePub. EPUB became an official standard of the IDPF in September 2007, superseding the older Open eBook standard. The Book Industry Study Group endorses EPUB 3 as the format of choice for packaging content and has stated that the global book publishing industry should rally around a single standard. EPUB is the most widely supported vendor-independent XML-based (as opposed to PDF) e-book format; that is, it is supported by the largest number of hardware readers, including Amazon Kindle Fire.
It is also widely used on many software readers such as iBooks on Apple devices, and Google Books on Android. iBooks also supports the proprietary iBook format. This format is based on the EPUB format but depends upon custom widget code in the iBooks app to function.
EPUB 2.0 was approved in October 2007, with a maintenance update (2.0.1) approved in September 2010. The EPUB3 specification was published in November 2014. New major features include support for precise layout or specialized formatting, such as for comic books, and MathML support.
The format and many readers support the following:
- Reflowable document: a reader can optimize text for a particular display device. EPUB also supports fixed-layout content Fixed-layout pre-paginated content can be useful for certain kinds of highly-designed content such as illustrated books that are designed to be consumed only on a larger-screen device, such as a tablet.
- Like an HTML web site, the format supports inline raster and vector images, metadata, and CSS styling.
- Bookmarking of a page.
- Highlight passages and make notes.
- Many readers include a library where books can be sorted and searched.
- Font size can be enlarged or made smaller. Text and background color can be changed.
- MathML: theoretical support of a subset of MathML.
- Digital rights management: an EPUB can contain Digital Rights Management (DRM) as an optional layer. The EPUB specification does not enforce or suggest a particular DRM scheme. This could affect the level of support for various DRM systems on devices and the portability of purchased e-books. Consequently, such DRM incompatibility may segment the EPUB format along the lines of DRM systems, undermining the advantages of a single standard format and confusing the consumer.
An EPUB file is a ZIP archive that contains what is in effect an entire website including HTML files, images, CSS style sheets, and other assets. It also contains metadata. EPUB 3 is the latest version. By using HTML5 publications can contain video, audio, and interactivity, just like websites in modern browsers.
An ePub publication is delivered as a single file. This file is an unencrypted zipped archive containing a set of interrelated resources.
An OCF Abstract Container defines a file system model for the contents of the container. The file system model uses a single common root directory for all of the contents of the container. All (non-remote) resources for publications are in the directory tree headed by the container’s root directory, although no specific file system structure is mandated for this. The file system model includes a mandatory directory named META-INF that is a direct child of the container's root directory and is used to store the following special files:
The first file in the archive must be the mimetype file. It must be uncompressed so that non-ZIP utilities can read the mimetype. The mimetype file must be an ASCII file that contains the string application/epub+zip. It must be unencrypted, and the first file in the ZIP archive. This file provides a more reliable way for applications to identify the mimetype of the file than just the .epub extension.
An example file structure:
--ZIP Container-- mimetype META-INF/ container.xml OEBPS/ content.opf chapter1.xhtml ch1-pic.png css/ style.css myfont.otf toc.ncx
There must be a META-INF directory containing container.xml. This file points to the file defining the contents of the book, the OPF file, though additional alternative rootfile elements are allowed. Apart from mimetype and META-INF/container.xml, the other files (OPF, NCX, XHTML, CSS and images files) are traditionally put in a directory named OEBPS. An example container.xml:
<?xml version="1.0" encoding="UTF-8" ?> <container version="1.0" xmlns="urn:oasis:names:tc:opendocument:xmlns:container"> <rootfiles> <rootfile full-path="OEBPS/content.opf" media-type="application/oebps-package+xml"/> </rootfiles> </container>
The ePUB container must contain:
- At least one content document.
- One navigation document.
- It may contain zero or more style sheets.
- It may contain zero or more PLS Documents.
- It may contain zero or more media overlay documents.
- One package document listing all publication resources. This file should use the file extension .opf. It contains metadata, a manifest, fallback chains, bindings, and a spine. This is an ordered sequence of ID references defining the default reading order.
Content documents include: HTML 5 content, navigation documents, SVG documents, scripted content documents, and fixed layout documents. Contents also include CSS and PLS documents. Navigation documents supersedes the NCX grammar used in EPUB 2.
- Books with synchronized audio narration are created in EPUB 3 by using media overlay documents to describe the timing for the pre-recorded audio narration and how it relates to the EPUB Content Document markup. The file format for Media Overlays is defined as a subset of SMIL.
Many editors exist including calibre, Adobe InDesign, Genebook and LaTeX. An open source tool called epubcheck exists for validating and detecting errors in the structural markup (OPS, OPF, OCF) as well as the XHTML and image files. The tool can be run from the command line, or used in webapps and applications as a library. A large part of the original work on the tool was done at Adobe Systems.
- "Specifications". IDPF. Retrieved January 25, 2012.
- "OPS 2.0 Elevated to Official IDPF Standard". IDPF. eBooklyn. Oct 15, 2007.
- "Endorsement of EPUB 3". BISG. Book Industry Study Group. Retrieved 18 September 2015.
- "Amazon Kindle Direct Publishing: Get help with self-publishing your book to Amazon's Kindle Store". Kdp.amazon.com. Retrieved 2015-08-31.
- Arnold Kim (January 19, 2012). "New ibooks not technically in epub format". MacRumors.
- "1.1 EPUB Revision History". IDPF. 11 October 2011.
- Rothman, David (July 27, 2008). "The ePub torture test: Starring ‘Three Shadows,’ a graphic novel". TeleRead: Bring the E-Books Home.
- "Fixed-Layout Properties". International Digital Publishing Forum. Retrieved 11 September 2015.
- "Understanding EPUB 3". EPUBZone. International Digital Publishing Forum. Retrieved 11 September 2015.
- "Embedded MathML". IDPF. Retrieved 12 September 2015.
- "Digital Book Standards FAQs". IDPF. November 20, 2006.
- Rothman, David (August 13, 2009). "Adobe-DRMed ePub isn’t ‘open’: Why the New York Times urgently needs to clarify its Sony eBook Store article". TeleRead: Bring the E-Books Home.
- "EPUB Open Container Format (OCF) 3.0 – Recommended Specification". IDPF. Retrieved 11 September 2015.
- "EPUB Publications". IDPF. Retrieved 12 September 2015.
- "EPUB Content Documents". IDPF. Retrieved 12 September 2015.
- "EPUB Media Overlays". IDPF. Retrieved 12 September 2015.
- "epubcheck: Validation tool for Epub". Google Code. Retrieved January 29, 2010.