HTML is the markup of the web, with native headings and tables. AZW3 is the current Kindle format, which replaced MOBI. calibre sits between the two, and this page says exactly what happens to an HTML file on the way to becoming an AZW3 one.
What runs when an HTML file becomes AZW3
calibre the ebook-convert binary, on a machine we rent and watch. Your HTML file is uploaded once, calibre runs once, the AZW3 comes back, and neither file is kept. HTML to AZW3 is one of the 3649 pairs that engine was probed on with a real file, which is why it has a page here and why the pairs the probe could not prove do not.
What survives from the HTML into the AZW3
The reading order and the chapter split of the HTML file. calibre rebuilds it as a book on the way to AZW3, rather than as a pile of pages.
Headings, and with them the table of contents: HTML and AZW3 both carry a heading hierarchy calibre can map one onto the other.
Tables, as tables. HTML and AZW3 can each hold one, so calibre does not have to flatten them.
Cover art and book metadata, which calibre carries from the HTML container into the AZW3 one.
What HTML to AZW3 costs you
Fixed layout. calibre reflows the HTML text by design, because an AZW3 is meant to be read at any font size on any screen width.
Nothing we could measure, which this page used to deny. The same EPUB carrying a heading, a table, bold text, a colour and a font comes back out of the AZW3 with all five of them still in it. Whether a device renders them well is a separate question, and one no measurement here reaches.
Everything the HTML file linked to. calibre runs with zero recursion here, so no link inside the HTML is followed. That is what stops an HTML file from a stranger pulling the server own files into the AZW3.
If a model is going to read the AZW3
Structure is what survives from the HTML file, and structure is what a model needs. HTML in, AZW3 out, with the heading tree intact instead of flattened into one long paragraph.
HTML to AZW3, measured rather than promised
Running HTML to AZW3 against the real engine with a real file, calibre wrote 10,818 bytes of AZW3 in 0.6 seconds, machine otherwise idle. That is one HTML file on one day and not an average, which is why the number is given together with the file that produced it.
The HTML to AZW3 verdict was reached by a format signature, meaning at least four bytes unique to the format were found at the right offset. Which check was used matters, because they do not all prove the same thing, and a status code of 200 proves nothing whatsoever about whether the AZW3 file has anything inside it.
The same HTML file, sent somewhere else
Other outputs the probe measured out of an HTML file, so the cost of choosing AZW3 can be read against something. Sizes do not compare across engines, because each family was probed with its own HTML witness file.
HTML to PDF: 25,178 bytes in 1.9 seconds, verified by a format signature.
HTML to MD: 371 bytes in under a tenth of a second, verified by a pandoc round trip.
HTML to DOCX: 10,277 bytes in 0.1 seconds, verified by a pandoc round trip.
HTML to EPUB: 5,027 bytes in 0.1 seconds, verified by a pandoc round trip.
HTML to TXT: 270 bytes in under a tenth of a second, verified by reading the text back.
HTML to RTF: 775 bytes in under a tenth of a second, verified by a pandoc round trip.
Other ways into AZW3, and what they measured
Among the published routes into AZW3, HTML is the eighth largest output of the 9 measured. The witness files differ, so this ranks the probe run and not your document.
MD to AZW3: 10,849 bytes in 0.6 seconds.
MOBI to AZW3: 61,343 bytes in 0.6 seconds.
ODT to AZW3: 11,155 bytes in 0.8 seconds.
RTF to AZW3: 10,837 bytes in 0.7 seconds.
TXT to AZW3: 10,607 bytes in 0.6 seconds.
What we will not pretend about HTML to AZW3
An HTML file over 50 MB is refused before the upload finishes rather than after it, so you do not wait for a rejection.
An HTML to AZW3 run that passes 120 seconds is killed, and the calibre process is killed with it. A run left behind would sit on one of the machine's two cores until somebody noticed.
The HTML file used to prove this pair was short. calibre is allowed 120 seconds and a long book can genuinely need all of them, so the AZW3 timing below is a measurement of one small file and not a guarantee about your thousand page one.
One HTML file at a time, chosen in the browser. There is nothing else to set up and nothing else on offer.
HTML to AZW3: what people ask
What actually converts my HTML file to AZW3?
calibre does it, the ebook-convert binary, on a machine we rent and watch. Not a browser trick and not somebody else service: the HTML file is uploaded once, calibre runs once, the AZW3 comes back, and neither file is kept afterwards.
How long does HTML to AZW3 take?
On the file the probe used, calibre took 0.6 seconds and wrote 10,818 bytes of AZW3. That is one real measurement on one real HTML file, not an average and not a promise about yours: a larger HTML takes longer, and past 120 seconds the run is stopped.
What do I lose going from HTML to AZW3?
The one to know about first: Fixed layout. calibre reflows the HTML text by design, because an AZW3 is meant to be read at any font size on any screen width.
Does the table of contents survive from HTML to AZW3?
It does, as long as your HTML file has real headings rather than text that merely looks like headings. calibre builds the AZW3 contents from the heading structure it finds, and hand-formatted big bold lines are not a structure.
Is HTML to AZW3 free?
There is a free allowance every month, and one HTML to AZW3 conversion costs half a credit against it. When the allowance runs out the tool says so and stops, rather than quietly handing you a worse AZW3.