Skip to main content
Conversion
Format conversion

HTML → MOBI/AZW3

Converting a novel from HTML to MOBI/AZW3: what each format is, what gets lost, the pitfalls for long fiction, and the right tools.

Tide Reader Editorial6 min read

What is HTML?

HTML / XHTML is the structural language of the web and is literally the content format inside an EPUB; .mhtml (MHTML) packs a page together with all its resources (images, CSS) into one file, which is what "save as a single page" produces. XML is the general markup language that formats such as FB2 and OPF are themselves written in. The whole family is tagged text where the tags carry the structure, so how much structure survives a conversion depends on how well the tool understands them.

Extensions.html.htm.xhtml.xml.mhtml
Typical useCaptured web content, EPUB internal content, and a general intermediate representation for other formats.

What is MOBI/AZW3?

Mobipocket (.mobi) was long the default format Amazon accepted for Kindle delivery. AZW3 (also called KF8) is its successor with fuller HTML5/CSS support, and .azw is an earlier Amazon container. All three reflow and carry navigation and metadata, so they behave as one family. They are proprietary to Amazon's ecosystem, and since 2022 Amazon sends KFX/EPUB instead, so .mobi is mostly a legacy format now.

Extensions.mobi.azw3.azw
Typical useReading on Kindle devices and the Kindle app; one of the most common proprietary formats in existing libraries.

What to watch out for when converting HTML to MOBI/AZW3

Extracting from the source

All structure lives in the tags, but real pages mix in navigation, ads and footers that a naive conversion carries along. Extract the content container first (a readability pass), and note that <img> usually points outside the file — images must be downloaded and embedded before producing a single-file format.

Writing the target format

Producing .mobi/.azw3 requires Amazon's toolchain or Calibre. AZW3 supports reasonable CSS while legacy .mobi supports very little; for newer devices, target AZW3 — or simply deliver an EPUB.

Where the two formats interact

  • Chapter headings in the source are ordinary lines while the target demands a real table of contents. Converters try to match patterns such as "Chapter N"; when the match is poor the TOC is garbled or the book has a single chapter. Check that TOC entries match the actual chapter count.

What gets lost

  • Both sides are structurally similar; only fine typographic detail is lost

What you gain

  • A real table of contents with chapter jumps
  • Full support in mainstream readers and libraries

Post-conversion checklist

  1. Convert the first three chapters as a trial and check for lost text, interleaved lines or misplaced blocks before doing the whole book.
  2. Check chapter splitting: the TOC entry count should match the real chapter count.
  3. Jump to five random spots and search a character name to confirm the text is fully searchable.
  4. Confirm illustration count and placement — check that images are not all dumped at the end of a chapter.
  5. Fill in title, author and language — a wrong language tag breaks typesetting such as Chinese line breaking.

Converting novels: what is different

Fiction is the most common and the most peculiar kind of e-book: hundreds or thousands of chapters, almost no figures, often nothing but a TXT source, and Chinese sources that frequently carry anti-piracy garbling. These are the points that bite hardest.

  • A long novel can run to hundreds or thousands of chapters, so the table of contents decides whether the result is usable. Normalise chapter headings to one recognisable pattern first — say "Chapter N Title" alone on its own line — or the target will miss chapters, merge them, or collapse the whole book into one.
  • Volume markers ("Volume One", "Volume Two") usually degrade to ordinary headings, losing the volume/chapter hierarchy. If that matters, promote volume headings one level in an editor afterwards so they are not siblings of chapter titles.

Tools for converting HTML to MOBI/AZW3

Any of the tools below can handle this direction; pick one by your operating system and how many files you have. Read the previous section first — doing the steps out of order (converting a scanned file before running OCR, for instance) usually means starting over.

Kindle Previewer

FreeDesktop app

Amazon's official tool: it converts EPUB/DOCX to AZW3 and previews the result exactly as a real Kindle would render it. It is the most reliable way to verify how a conversion actually looks on a Kindle, and avoids hand-building the proprietary container.

Platforms: Windows / macOSkdp.amazon.com/en_US/help/topic/G202131100 ↗

Calibre

FreeDesktop app

The de-facto standard for e-book conversion, free and open source. It converts EPUB, MOBI, AZW3, PDF, TXT, FB2, DOCX, HTML and nearly everything else, generating tables of contents, fetching metadata and batch-processing whole libraries. The interface is utilitarian, PDF output is mediocre, and the option set takes time to learn.

Platforms: Windows / macOS / Linuxcalibre-ebook.com ↗

SumatraPDF

FreeReader

A lightweight reader for PDF, EPUB, MOBI, CBZ and more that can save PDF content as text. It is a fast way to check whether text extracts cleanly — if the selection comes out garbled, OCR is needed before converting.

Platforms: Windowswww.sumatrapdfreader.org ↗

Common questions

What is lost when converting HTML to MOBI/AZW3?

Both sides are structurally similar; only fine typographic detail is lost.

Which tool should I use to convert HTML to MOBI/AZW3?

Recommended: Kindle Previewer, Calibre, SumatraPDF. Kindle Previewer fits this pair best. Amazon's official tool: it converts EPUB/DOCX to AZW3 and previews the result exactly as a real Kindle would render it. It is the most reliable way to verify how a conversion actually looks on a Kindle, and avoids hand-building the proprietary container.

What should I watch out for when converting HTML to MOBI/AZW3?

Chapter headings in the source are ordinary lines while the target demands a real table of contents. Converters try to match patterns such as "Chapter N"; when the match is poor the TOC is garbled or the book has a single chapter. Check that TOC entries match the actual chapter count.

Converted it — now what do you read it with?

Tide Reader opens TXT and EPUB, detects chapters on import, lays the text out the way you like it, and syncs your reading position across Windows, macOS, iOS and Android. Drop the converted file in and start reading.

Download Tide Reader

TXT and EPUB; local-first reading, with optional cloud sync and WebDAV.