EPUB to Word Converter
Operator: Abdulla Al Fahad. How tools are built and checked
An EPUB is a zip of web pages: one XHTML file per chapter, a package file that lists them in reading order, and a table of contents. Reading apps are built for reading, not for getting the text back out, which is a problem when you are the author, the translator or a student who needs to quote long passages. The EPUB to Word Converter follows the book's own spine, converts each chapter and writes everything into one editable .docx with the chapter titles as headings.
The book's structure does most of the work. The spine gives the chapter order, the navigation document or NCX gives each chapter a title, and the package metadata gives the book its name, which becomes the Word document's title. Chapter files that contain no text, such as an image-only cover page, are skipped, and a chapter that opens without a heading of its own gets one inserted from the table of contents. Protected books are detected before any chapter is read and refused with an explanation rather than producing an empty document.
Key features
- Follows container.xml, the package manifest and the spine of EPUB 2 and EPUB 3 files, including chapter paths with percent-encoded names.
- Inserts chapter titles from the navigation document or toc.ncx as Heading 1 when a chapter has no heading of its own.
- Skips the navigation document and text-free pages such as the cover, and refuses DRM-protected books after checking encryption.xml.
- Names the Word document after the book's dc:title and keeps external links while dropping links between chapter files.
- Reports chapter, word and image counts for the whole book.
How chapters are read from the EPUB
The converter opens META-INF/container.xml to find the package (.opf) file, reads its manifest and spine, and takes the book title from the dc:title element. Chapters are processed in spine order. The navigation document (EPUB 3) or the toc.ncx file (EPUB 2) supplies chapter labels; when a chapter file has no heading in its first few blocks, its label from the table of contents is inserted as a Heading 1 so the Word document has a navigable structure. The navigation document itself is not included in the output.
Within chapters the HTML rules apply: heading tags become Word headings, p becomes a paragraph, ul and ol become lists, table becomes a table, blockquote becomes an indented paragraph, and strong, em, u, s, code and inline styles carry formatting. Links to external web addresses are kept. Links that point inside the book, such as footnote references to another chapter file, become plain text because their targets do not exist in a Word file. CSS classes, which many ebooks use for drop caps, small caps and poetry indentation, are not applied; only inline style attributes are read.
Images, including the cover, are counted and reported but not embedded. Protected books are detected by reading META-INF/encryption.xml and checking whether any spine chapter is listed there; fonts that are merely obfuscated do not trigger the check. The summary shows the number of chapters converted and the word count, which for a novel can run to six figures, so the preview shows only the beginning of the document.
How it works
After the zip is opened in the browser, the container file points to the package document. The manifest maps item ids to file paths and media types, and the spine lists the ids in reading order. The converter also parses the navigation document or NCX to build a map from chapter path to title.
Each spine item that is an XHTML document is read and passed through the HTML parser, producing headings, paragraphs, lists and tables. A chapter heading is added from the table of contents when the chapter lacks one, and the blocks of all chapters are concatenated into a single document in spine order.
Common use cases
- An author has only the published EPUB of an earlier book and wants the manuscript back in Word for a revised edition.
- A translator needs the source text of a public-domain novel in a Word file to work alongside the translation.
- A lecturer extracts chapters from an open-licence textbook to annotate and share as study material.
- An editor received an EPUB from a self-publishing platform and needs to proofread it with Word's tracked changes.
- A reader with low vision converts a DRM-free book to Word to set a large font and wide spacing for printing.
How to use this tool
- Drop an .epub file on the upload area.
- Compare the chapter count in the summary with the book's table of contents, and scroll the preview to confirm the chapter order.
- Note the number of skipped images, which includes the cover.
- Download the .docx, or open the book in the Word editor to remove front matter or adjust headings.
Example
Package file and a chapter (simplified)
<spine>
<itemref idref="cover"/>
<itemref idref="ch1"/>
</spine>
<!-- toc.ncx: ch1.xhtml -> "Chapter One" -->
<!-- ch1.xhtml -->
<p class="first">It was a bright cold day in April,
and the clocks were striking <em>thirteen</em>.</p>Word document structure
(cover.xhtml skipped: no text)
Heading 1: Chapter One <- inserted from the table of contents
Paragraph: It was a bright cold day in April, and the clocks were striking [italic]thirteen[/italic].Tips for best results
- Check the book is DRM-free before you start. Books bought from stores that apply Adobe or Apple protection cannot be read; books from Project Gutenberg, Standard Ebooks and most direct-from-author sales can.
- Compare the chapter count in the summary with the book's own table of contents. Several chapters in one file is normal; zero chapters means the file is not a text ebook.
- A long book produces a long .docx. Download it rather than relying on the browser autosave in the Word editor, which has storage limits.
- Kindle files (.mobi, .azw3) are a different format. Convert them to EPUB with a tool such as Calibre first, then use this converter.
Edge cases to watch
DRM-protected books fail with a clear message. There is no way around the protection in a browser, and none is attempted.
Fixed-layout EPUBs, such as comics, picture books and some textbooks, store little or no real text, so they produce a very short document or none at all.
Formatting carried by CSS classes is lost. Chapter openers with styled first letters, verse indentation and small-caps headings arrive as plain paragraphs.
Footnote and endnote links that jump between chapter files become ordinary text. The note text is still included where the book placed it, usually at the end of a chapter or the book.
The cover and every illustration are left out. The warning tells you how many images were skipped.
Books with front matter spread over many tiny files produce several short sections before the first chapter. Delete what you do not need in the Word editor.
Frequently asked questions
Can it convert a book I bought from a store?
Only if the file is DRM-free. Protected EPUBs have encrypted chapter files, which the converter detects and refuses. Nothing is done to bypass protection.
Does the Word file include the cover and pictures?
No. The cover is usually an image-only page, so it is skipped entirely, and illustrations inside chapters are counted in the warning but not embedded.
What about Kindle .mobi or .azw3 files?
They are not EPUBs and cannot be read here. Convert them to EPUB with Calibre or a similar tool first.
Where do the file name and document title come from?
The downloaded .docx is named after the uploaded file. The title stored inside the document, which Word shows in its properties and title bar, is taken from the book's dc:title metadata.