Command line
PDF to text, Markdown and PNG from the terminal.
One binary, eleven subcommands. pdfboss converts, inspects and creates PDFs, takes a local path or an http(s) URL for anything it reads, and reports what it had to skip instead of failing silently. Installed from crates.io, MIT OR Apache-2.0.
--no-default-features for a leaner binary.Convert
Text, Markdown, PNG and images.
render prints what it wrote and warns on stderr about anything dropped; images names every file it writes. Page numbers are 1-based on the command line.
$ pdfboss info report.pdf # version, page count, sizes, metadata
$ pdfboss text report.pdf --page 2 # PDF to text (omit --page for all pages)
$ pdfboss md report.pdf > report.md # PDF to Markdown: headings, lists, tables
$ pdfboss render report.pdf --page 1 -o page.png --scale 2.0 # or .ppm / .bmp / .jpg
$ pdfboss images report.pdf -o out/ # embedded images as native-size PNGsSubcommands
Everything the binary does.
| info | Version, page count, page sizes and metadata |
|---|---|
| text | Extract plain text, all pages or one |
| md | Extract Markdown with headings, lists and tables from layout |
| render | Rasterize a page to PNG, PPM, BMP or JPEG at a scale |
| images | Write every embedded image on a page at native size |
| obj | Print one object by number |
| json | The whole document as a JSON element tree |
| hex | Hexdump of any object, xref section or byte range |
| q | jq-style queries over the element tree |
| tui | The terminal explorer |
| create | blank, text, images, md or a TOML manifest to a new PDF |
Encrypted files open with --password. Full flags per subcommand in the CLI reference.
Explore
See inside any PDF, local or remote.
tui opens the file as a lazy tree: pages with their fonts, images and content streams, a pretty-printing inspector, a live page preview and a tracking hexdump. The same element model answers json, q and hex.

# fetched in byte ranges, never downloaded whole
$ pdfboss json https://example.com/report.pdf --no-logical > tree.json
$ pdfboss q https://example.com/report.pdf -r '.pages[].fonts[].base_font'
$ pdfboss hex report.pdf header
$ pdfboss tui https://example.com/report.pdfCreate
New PDFs from text, images, Markdown or a manifest.
create md composes CommonMark+GFM with a CSS theme; create manifest assembles pages, metadata, bookmarks and attachments from one TOML file. Output is deterministic.
$ pdfboss create blank -o blank.pdf --pages 3 --size letter
$ pdfboss create text notes.txt -o notes.pdf --font times-roman
$ pdfboss create images scan-1.png scan-2.png -o scans.pdf
$ pdfboss create md notes.md -o notes.pdf --theme theme.css
$ pdfboss create manifest q3.toml -o q3.pdf