HTML → FB2
Converting a novel from HyperText (.html, .htm, .xhtml, .xml, .mhtml) to FictionBook (.fb2) is a routine step in practice — FB2 is a single XML file holding text, metadata and illustrations together, so nothing goes missing in transit. Fortunately HyperText and FictionBook are structurally close, so there is not much to lose. Below we explain in detail how HyperText becomes FictionBook and what to watch out for, and the page ends with a converter that does the job right in your browser — nothing is uploaded, the file never leaves your machine.
What is HTML?
HTML and XHTML are the structural languages of the web, and XHTML is also what EPUB uses internally to hold its content — so converting between HTML and EPUB is essentially a matter of swapping the shell and how assets are packaged. .mhtml goes further and packs a page together with its images and styles into one file, which suits preserving online pages that may disappear. HTML's strength is that it is universal and opens in any browser; its weakness is that styles and images are usually external links, so shipping one self-contained file means inlining them first. Read the HTML format guide
| Extensions | .html.htm.xhtml.xml.mhtml |
|---|---|
| Typical use | Captured web content, EPUB internal content, and a general intermediate representation for other formats. |
What is FB2?
FB2 (FictionBook) is an open e-book format based on XML. Text, metadata and illustrations all live in a single file, with images embedded as Base64, so one file distributes completely and you never end up with the text present but the images missing. Its structure is simpler than EPUB and therefore easier for readers to implement, and it is most popular in Russian-speaking regions. The drawback is that it supports almost no complex CSS, so it suits text-plus-illustration books rather than titles that depend on fine layout. Read the FB2 format guide
| Extensions | .fb2 |
|---|---|
| Typical use | Russian-language e-books; single-file distribution where embedded illustrations and full metadata matter. |
How to convert HTML to FB2
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.
FB2 requires structured XML body text, Base64-embedded images and metadata inside <description>. It supports almost no CSS, so it suits text-plus-illustration books rather than layout-heavy titles.
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.
Convert HTML to FB2
HTML → FB2
The conversion runs entirely in your browser — your file is never uploaded.
A novel reader that syncs your progress across every platform
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 ReaderTXT and EPUB; local-first reading, with optional cloud sync and WebDAV.
