30 / Read · EPUB ↔ EPUB

EPUB diff online

See exactly what changed between two EPUBs.

Compare two EPUB editions word by word and inspect changes by chapter. Switch between side-by-side, inline and changes-only views, then export a standalone HTML report. The comparison focuses on text and chapter pairing; it does not compare cover images, stylesheets or metadata, and a similarity percentage is not an editorial verdict.

  • Two DRM-free EPUBs, up to 100 MB each
  • Nothing is uploaded; both books stay here
  • A chapter list, word counts and one HTML report
All tools
Opening your workspace…

At a glance

EPUB Diff quick specs

Verified
Input
Two DRM-free EPUB 2/3 files
Output
Chapter-by-chapter word diff + self-contained HTML report
Scope & limit
Up to 100 MB per EPUB
Processing
Local in your browser — files never upload
Price & account
Free; no sign-up or install required
Key boundary
Compares extracted chapter text (not visual CSS rendering or plagiarism)

From file to finished

How to compare two EPUB editions word by word

  1. Choose book A and book B with the two pickers, or drop one EPUB on each slot. The hint names the limits: two DRM-free EPUBs, 100 MB each, 500 chapters per book. The sample pair loads two short books to try the controls.

  2. Leave Ignore whitespace checked for a word-only comparison, or clear it to see spacing edits. Ignore letter case is off by default; turn it on when The and the should count as the same word.

  3. Press Compare books. The progress panel names the phase, counts chapters done out of the total, and updates the elapsed timer every 200 ms; both books stay in the tab.

  4. Read the summary, pick a chapter, and switch between Side by side, Inline and Changes only. The subtitle above the text says whether the pair was aligned by title or by reading order.

  5. Press Export HTML report. The download is one self-contained HTML file with inline styles and no scripts, named after both books and ready to open offline.

Formats and inputs

Supported EPUB formats and inputs

Two EPUB archives can differ internally without changing readable prose, or keep similar filenames while their text changes substantially. This tool compares extracted chapter text from EPUB 2 or 3, pairing titles before falling back to reading order. Fixed-layout pictures and SVG text are not equivalent to ordinary chapter text. Different chapter divisions can affect alignment independently of wording.

InputSupportWhat to expect
A DRM-free EPUB 2 or EPUB 3 bookBest fitNormal XHTML chapters in the spine are read in order. A title comes from the navigation document or NCX, otherwise the first h1/h2 or title, otherwise Chapter N by position; text is compared chapter by chapter.
Two editions with real chapter titlesBest fitTitles match after case, accents, punctuation and spacing are normalized, so “The Map Room” and “the map room!” pair. Repeats pair in sequence.
Books with generic titles such as Chapter 1PartialAnonymous titles are paired by reading order when no title matches, or as leftovers when some do. A different chapter count can pair the wrong two chapters, so read the A #n ↔ B #m line.
Differences only in images, CSS, fonts, cover or metadataNot supportedThe comparison reads text. A new cover, a restyled chapter or a changed author field can leave every chapter Identical, so use a package checker for those parts.
A DRM-protected or encrypted EPUBNot supportedThe book is refused before its text is read, with a message naming DRM or encryption. Use a DRM-free copy; the tool has no key and does not remove protection.
A book over 100 MB or with more than 500 chaptersNot supportedThe size gate runs before the archive is opened, and the chapter count is checked after it. Both limits are per book, so a pair can have one book at the cap and one below it.
A fixed-layout EPUB with text in SVG or imagesPartialText in HTML is compared, but SVG and image-only pages are skipped, so a visually different page can read as empty or identical. The rest of the book still compares.
A PDF, MOBI, AZW3 or DOCX fileNot supportedOnly EPUB packages are accepted. A renamed ZIP or PDF fails the container check, and a Kindle or Word file has to be converted to EPUB before it can be compared here.

What it can do

What EPUB Diff can do

Line up chapters by title, then by position

Titles are normalized: case, accents, punctuation and spacing are ignored, and an ampersand reads as “and”. Chapter 4, Untitled and a bare number count as anonymous. Matched titles pair first, in sequence when one repeats. If no title matches, leftovers pair by reading order; when some match, leftovers pair by position only where at least one title is anonymous, and titled leftovers stay unpaired. The detail names the method and shows both positions for order pairs.

Read a word-level diff, not a line diff

Each chapter is split into words and punctuation with the browser’s word segmenter, so a one-word substitution marks that word and not a whole paragraph. In Side by side and Inline, removed text is struck through in red and added text sits on green; Changes only collects edits with 14 tokens of context. Punctuation is compared but not counted as a word, so a comma-only edit shows a change with no word counts.

Turn whitespace differences on or off

Ignore whitespace is checked by default, which matches the usual case: a reflowed EPUB can move line breaks without changing a sentence. Clear it and the comparison also checks the spaces before each word and at the end of the chapter, marking them in yellow; a trailing difference shows a ␠ symbol. Spacing marks are not counted as words, and a spacing-only chapter is labeled Whitespace only. Changing either option after a comparison disables export until you compare again.

Read counts, similarity and unpaired chapters

The summary counts chapters in each book, pairs, changed and identical chapters, chapters only in A or B, unreadable chapters, added and removed words, and a similarity percentage. Similarity compares the words the two chapters share with the words they contain; comparing a book with itself gives 100%. A one-sided chapter stays in the chapter count but adds no words to the totals, so a cut chapter does not lower the rest.

Export one self-contained HTML report

Export writes a single HTML file with the styles inline, no scripts and no remote images, so it opens offline, prints and can be attached to an email. The report repeats the summary, then a chapter table with status, word counts and similarity, a list of any unpaired chapters, and side-by-side marked text for every changed chapter. The filename is epub-diff-A-vs-B.html, with each book name cut to 40 characters after .epub is removed.

After you run it

What you get from EPUB Diff

Success is visible in the summary and in the downloaded report. These are the parts worth checking before you trust a comparison.

What you getWhat it means
Every chapter carries a statusChanged, Identical, Only in A, Only in B and Unreadable are the five states. A compared chapter also shows its added and removed word counts and its similarity; an unpaired chapter shows neither.
A summary with counts and one decimalChapters A and B, changed, identical, only A and B, added and removed words, similarity and elapsed time are printed together. Elapsed time is shown to 0.1 seconds.
A success test you can run in a minuteCompare a book with itself: every chapter should be Identical and similarity should read 100%. Then compare the revised file and confirm the changed chapters are the ones you expected.
A report that opens without a networkSave the HTML file, close the tab and open the file from your folder. It should render with its inline styles, with no font, image or script request.
Unpaired chapters are listed, not mergedA one-sided chapter is listed under Unpaired chapters in the report and marked Only in A or Only in B on the page. It counts as a chapter but not as words, so similarity stays fair.
Stale settings block the exportAfter a comparison, changing Ignore whitespace or Ignore letter case marks the result as stale and disables Export HTML report. Run Compare books again to apply the options.

When people reach for it

Common EPUB Diff use cases

A text comparison is useful when wording is the subject of review. Decide whether the editions have comparable chapter divisions first; a layout-only revision or a book made from page images needs a different comparison method.

If you need to…What this tool does
Check what a new edition changedCompare the edition you own with the new one and read the changed chapters before buying again. The chapter list separates a rewritten scene from a new preface, and a chapter that exists only in the new file is counted as Only in B.
Audit a copyedit passCompare the manuscript export from before the edit with the one after it. Identical chapters confirm that no text drifted, and Changes only lists the sentences the editor touched, which is faster than rereading the whole book.
See whether two store downloads are the same textTwo files with the same title can come from different conversions. A 100% similarity and every chapter Identical means the words match; the report cannot confirm that covers, images or metadata match.
Find the chapter cut from an abridged editionCompare the unabridged file with the abridged one. Chapters that exist on only one side appear as Only in A or Only in B, while the shared chapters are still compared word by word.
Compare two conversions of one sourceRun the same manuscript through two EPUB builders, then compare the results. A paragraph dropped by one converter shows as removed text in the chapter where it should be, instead of hiding in a whole-file checksum.
Confirm a shared file matches your masterBefore you archive or send a copy, compare it with the master EPUB. The summary and chapter list show whether the text is untouched, and the HTML report gives you a dated record of what you checked.

Why use it

Why compare two EPUB editions word by word

Use this comparison when you need to review wording between editions, not just see whether two ZIP files differ. The chapter alignment and marked passages provide the evidence; counts and percentages help prioritize review but cannot judge the significance of an edit.

Find small edits that a new cover does not explain

A revised edition can change a date, name or negative word while leaving most paragraphs intact. A marked text comparison directs attention to those edits, which a simple file-size or metadata comparison cannot establish.

Separate chapter matching from the change itself

A mismatched pair can make a harmless reorganization look like a wholesale rewrite. Seeing whether titles or reading positions produced the pair helps you decide which differences deserve trust and which need a source-level check.

Prioritize review without treating a score as proof

Similarity is useful for finding heavily revised chapters, but an important correction can occupy very few words. Reading the marked evidence keeps an editorial decision tied to the text rather than to a reassuring percentage.

Share a review record without sharing a tool session

A self-contained report is useful for a co-author or editor who needs to inspect the marked passages later. It preserves the comparison context as a file, while the original editions remain the references for layout, images and metadata.

When it does not work

Why EPUB Diff may fail

Most failures happen before any comparison starts, while the EPUB is opened or its chapter count is checked. These are the messages the page shows and the branch behind each one.

  • The file is over 100 MB

    The EPUB loader stops at the size gate with Choose an EPUB smaller than 100 MB. Large illustrated books can need more memory than this browser can safely use. Images are not compared, but the archive still has to be opened and each chapter read, so a smaller edition is the practical fix.

  • One book has more than 500 chapters

    After a book opens, the tool counts its chapters and stops with This book has N chapters. The limit is 500 per book. The comparison function repeats the check with Each book can have at most 500 chapters. Split editions are difficult to align, so choose a shorter edition or compare in parts.

  • The book is DRM-protected or encrypted

    An encrypted package is refused before its text is read. The page names DRM-protected or unsupported encrypted content, or says the reading content is encrypted. These tools open DRM-free EPUBs only; the tool has no key and does not attempt to remove protection.

  • The file is not a real EPUB

    A PDF, MOBI or renamed ZIP fails the container check with This archive has no EPUB container.xml. Choose an actual EPUB, not a renamed ZIP or PDF. A download that was cut short can fail earlier as not a readable EPUB ZIP archive.

  • A chapter cannot be read

    One malformed XHTML file does not stop the run. The chapter gets the status Unreadable, the detail says This chapter could not be read followed by the error, and the rest of the comparison stays available. The summary also counts the unreadable chapters.

  • Export is disabled after a settings change

    Changing Ignore whitespace or Ignore letter case after a comparison leaves the old result on screen but marks it stale: Settings changed — run the comparison again to apply them. The export button is disabled and its title explains why.

  • The report cannot be built

    If the browser cannot finish the export, the page says The report could not be built. Try again with fewer changed chapters. The comparison itself is still on screen, so you can close other tabs and export again, or compare a smaller pair.

Repair paths

How to fix common EPUB Diff issues

The first column is what the page says; the last column is the action that changes the outcome. Fixing the books first is faster than comparing repeatedly.

What you seeLikely causeWhat to do
Choose an EPUB smaller than 100 MBThe file is above the per-book size gateUse a smaller edition or an EPUB with fewer embedded images; the limit applies to each file, not to the pair.
This book has N chapters. The limit is 500 per book.The spine contains more than 500 HTML documentsCompare a shorter edition. Splitting both books changes alignment, so keep the chapter order and titles if you split them.
This book contains DRM-protected or unsupported encrypted contentThe EPUB is encrypted or uses an unsupported protection schemeChoose a DRM-free copy you are allowed to read; the tool has no key and will not open an encrypted book.
This archive has no EPUB container.xmlThe file is a PDF, a ZIP renamed to .epub, or an incomplete downloadExport a real EPUB 2 or EPUB 3 file, or download the book again; do not rename another format.
This chapter could not be read: …One XHTML chapter is malformed or uses content the reader cannot parseRepair that chapter in an EPUB editor and run the comparison again; the other chapters still compare meanwhile.
Settings changed — run the comparison again to apply them.Ignore whitespace or Ignore letter case changed after the runPress Compare books again. Export stays disabled until the result matches the options on screen.
The report could not be built. Try again with fewer changed chapters.The export threw while writing the HTML reportClose other tabs, run the comparison again, then export; or export a pair with fewer changed chapters.

Plain-language notes

Key EPUB comparison terms explained

These terms decide how the books are paired, how the numbers are calculated and what the report can claim.

Chapter alignment

The pairing of one chapter in book A with one chapter in book B. Alignment uses normalized titles first and reading order second, and every pair records which method placed it, so the result can be checked rather than assumed.

Normalized title

A chapter title after case, accents, punctuation, ampersands and repeated spaces are flattened: Café & Co. becomes cafe and co. Normalizing lets two tables of contents match even when one uses curly quotes, a different case or an accented spelling.

Reading-order fallback

Pairing leftover chapters by their position in the spine rather than by title. It runs when no titles match at all, or for chapters whose titles are empty, numeric or a bare Chapter N; a titled leftover stays unpaired only when its counterpart also has a real title.

Word token

One word, number or punctuation mark produced by the browser’s word segmenter. Whitespace is attached to the token that follows it, which is what makes a spacing-only change visible without turning it into an added or removed word.

Similarity

Two times the shared word count divided by all words in both compared chapters, rounded to one decimal. Comparing a book with itself gives 100%; a chapter that exists on only one side is excluded from the calculation.

Whitespace-only change

A chapter whose words and punctuation match but whose spacing differs while Ignore whitespace is off. The page labels it Whitespace only, marks the spaces in yellow and reports no added or removed words.

Unpaired chapter

A chapter that exists in only one book. It is listed as Only in A or Only in B, counted in the chapter totals and left out of the word totals and similarity, because there is no second text to compare it with.

Self-contained HTML report

One HTML file with its CSS inline, no scripts, no font files and no remote images. It opens from a folder or an email attachment without a network request, and it is the only file the export writes.

Edit-distance cap

The diff stops using the full Myers algorithm after 3,000 edit steps in one chapter. Beyond that it keeps the common start and end and marks the whole middle as removed and added, which keeps a heavily rewritten chapter from freezing the tab.

Text comparison versus archive comparison

An EPUB is a ZIP whose compression, timestamps and resource ordering can change independently of prose. A byte-level comparison detects those differences too. This tool instead narrows the question to extracted chapter text and its alignment.

Other ways to do it

EPUB Diff vs. alternatives

Comparing here is not the only route. These are the cases where a desktop tool, a script or a manual read does the job better, and what each one costs.

OptionBetter whenTrade-off
diff on unzipped XHTMLYou want a raw line diff and are comfortable in a terminal.Markup noise from IDs, classes and line wrapping hides the prose; you get no chapter alignment, word counts or unpaired list.
Pandoc to plain text, then diffYou want a repeatable command over many books and your own output format.You install and script the toolchain, and you still decide how chapters align; a one-word edit can look like a whole-block change.
Calibre’s book comparison toolYou need to compare package text, styles and images and may also repair the book in a desktop editor.Calibre includes a book comparison view for text, styles and images. Choose it for package-level investigation; this page focuses on aligned extracted chapter text and a standalone HTML report.
A desktop folder-compare toolYou compare whole EPUB folders, including CSS and images, or need a three-way merge.Compare supported file types, text granularity and merge features in the chosen app. Folder comparison and this page’s extracted chapter pairing answer different questions.
Read both editions yourselfThe change is small, or you need the surrounding story to judge it.Easy to miss a changed name or date, and slow for a full-length book.

Your files and this tool

Privacy, accuracy and EPUB Diff limits

The files stay in the browser, but that is not a promise about the result. These are the boundaries worth knowing.

  • The tool has no server-side step: it runs as static files in this tab, so there is nowhere for a book, its text or a report to be stored between visits.
  • The report is assembled in memory and downloaded as a blob. No copy is posted to the site, and the only place it lands is your browser’s download folder.
  • Nothing is stored in localStorage, IndexedDB or a cookie by this tool. The books, the chapter text and the result live in memory, and the page disposes the books when you leave or reload the page.
  • The page loads its own scripts, styles and Google Analytics, while the comparison makes no network request for your books; the sample pair is fetched only when you choose it.
  • The original files are not modified. The result is a normal download you can open, copy or delete, and it is not checked by EPUBCheck or a store preview.
  • Similarity is a word ratio, not a plagiarism check, an editorial judgment or proof that two editions are legally distinct. It only describes the text this tool read.

A little more detail

Frequently asked questions about EPUB Diff

Are the books uploaded when I compare them?

No. Both EPUBs are opened with the browser’s File API and read with JSZip in this tab. No request carries the files or their text, there is no account and no comparison queue. Closing the tab or reloading the page clears the books and the result. The files on disk are not changed, and the HTML report is built locally as a download.

How does the tool decide which chapters to compare?

It normalizes both chapter lists first, ignoring case, accents, punctuation and spacing, and treating an ampersand as “and”. Chapters with matching titles pair in order. Titles such as Chapter 4, Untitled or a bare number count as anonymous: if no titles match, leftovers pair by reading order; if some match, a leftover pairs by position only where one side’s title is anonymous. The chapter detail states the method and both positions.

What counts as a changed chapter?

Any difference in the compared text: an added word, a removed word, a reworded word or a changed punctuation mark. With Ignore whitespace off, a spacing difference also counts, and the chapter is labeled Whitespace only when nothing else changed. Chapters that exist on only one side are listed as Only in A or Only in B but are not word-diffed.

How is the similarity percentage calculated?

It is two times the number of shared words divided by the total words in both compared chapters, rounded to one decimal. Punctuation and spacing do not count as words, and unpaired chapters are excluded. A book compared with itself returns 100%. The number describes the text only, so 98% can still hide a changed name or a removed “not”.

Can I compare two books with different chapter counts?

Yes. Extra chapters appear as Only in A or Only in B, and the shared chapters are still compared. The risk is alignment: generic titles plus a different count can shift which chapters meet, so read the A #n ↔ B #m line in the chapter detail. If the pairing is wrong, rename the chapters in an EPUB editor and run it again.

What is in the exported HTML report?

One file with the summary, a chapter table (status, added and removed words, similarity), an Unpaired chapters list and side-by-side marked text for each changed chapter. Styles are inline, there are no scripts and no remote assets, so it opens offline.

Does it compare images, CSS, fonts or metadata?

No. The comparison reads chapter text. A new cover, a different font, restyled CSS or an edited author field does not change the comparison, so every chapter can still read Identical. Use an EPUB package checker or a folder-compare tool for those parts; this page only claims what it read from the XHTML chapters.

Can a chapter move be mistaken for a large text revision?

Yes, especially when chapter names are missing or generic and pairing falls back to reading order. A chapter inserted near the beginning can shift later pairs even if much of their prose is unchanged. Review the pairing method and both source titles before interpreting a large difference as a rewrite. The report provides comparison evidence, not automatic editorial judgment.

What are the size and chapter limits?

Each book must be a DRM-free EPUB 2 or EPUB 3 file, no larger than 100 MB, with at most 500 readable chapters. A file over either limit stops before the comparison starts. Large books take longer and the tab must stay open, because every chapter is read and compared in the browser.