Free tool
HTML to PDF
Paste HTML, choose a paper size and margin, and get a PDF printed by a real browser. Backgrounds, fonts and page breaks all respected.
your result appears here
the same call with your key
curl -X POST https://api.imageapis.com/v1/pdfs -H 'X-API-Key: YOUR_KEY' -H 'Content-Type: application/json' -d '{"html":"<h1>Invoice #1042</h1>","format":"A4","margin":"20mm"}'What this is
Chromium's print engine, driven by the API: CSS @page rules, page-break-before, print backgrounds and web fonts all behave as they do when you print from the browser. The result is a real multi-page PDF at a hosted URL.
Cost
One unit per page. The record tells you how many pages the document had, and the gateway's X-Gw-Cost header says what the call cost.
From a template or a URL
The API also prints a saved layer template at its own pixel size, one page, which is how certificates and tickets are done, and prints any public URL. See the invoices guide for a complete example with a webhook.