azw3-to-pdf

Turn Kindle books into PDFs, from a terminal interface or a single command.

azw3-to-pdf reads .azw3, .azw, .mobi and .prc files and lays them out as PDFs. The MOBI/KF8 parser, the layout engine and the PDF writer are all part of the binary, so there is no Calibre, no Python and no Ghostscript to install alongside it. Run it with no arguments to get a file browser in the terminal and pick a book, or drive it from the shell with --no-tui to convert a single file, a whole folder recursively, or several books at once with --jobs. Layout presets cover e-reader, paperback, print and large print, and every setting can be tuned by hand. Output keeps chapter breaks, headings, illustrations, the cover, hanging indents and justified text taken from the book’s own stylesheet, and produces real PDFs with selectable text, outline bookmarks from the book’s headings, page numbers and document metadata. A probe subcommand inspects a book without converting it.

Install

go install github.com/jparkerweb/azw3-to-pdf/cmd/azw3-to-pdf@latest

Or clone and build:

git clone https://github.com/jparkerweb/azw3-to-pdf.git
cd azw3-to-pdf
make build