HTML to PDF: Web Pages, HTML & Invoice Templates in Bulk
Pricing
$3.00 / 1,000 pdf createds
HTML to PDF: Web Pages, HTML & Invoice Templates in Bulk
Turn web pages, HTML documents or an HTML template plus JSON rows (invoices, certificates, reports) into PDFs. Page size, margins, landscape, headers, footers and page numbers. Cookie banners hidden. You only pay for PDFs that succeed.
Pricing
$3.00 / 1,000 pdf createds
Rating
0.0
(0)
Developer
Pandapi
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
21 hours ago
Last modified
Categories
Features
Share
Convert web pages, HTML documents or an HTML template filled with JSON data into clean PDF files, with a real Chrome browser.
- 🌐 URL to PDF: any public page, one PDF per URL, with cookie banners hidden and lazy images loaded
- 📝 HTML to PDF: paste a full HTML document (inline CSS, web fonts, images) and get one PDF
- 🧾 Template + data to many PDFs: one Handlebars template and a JSON array of rows gives one PDF per row. Perfect for invoices, receipts, certificates, tickets, letters and reports
- 📐 Page layout: A4, Letter, Legal, A3, A5 or Tabloid, portrait or landscape, margins, scale, background colors
- 🔢 Headers, footers and page numbers ("3 / 12") on every page
- 🏷️ Your file names:
invoice-{{number}}.pdfinstead of random keys - 💸 You only pay for PDFs that are created. Broken URLs and failed documents are free. No start fee.
Use cases
- Invoices and receipts from your shop, CRM or n8n / Make / Zapier workflow data
- Certificates for course or event attendees, from a spreadsheet exported as JSON
- Reports built as HTML (charts, tables) and sent as PDF attachments
- Archiving web pages for compliance, legal evidence or research
- Saving articles and documentation as printable PDFs
How to use it
- Pick what to convert: Web page URLs, an HTML document, or an HTML template with Data rows. You can mix all three in one run.
- Choose the page size, margins and footer.
- Run it. Each PDF is stored in the run's key-value store and listed in the dataset with a download link.
Example: invoices from JSON
{"template": "<html><body style=\"font-family:Arial\"><h1>Invoice {{number}}</h1><p>Bill to: {{customer}}</p><table>{{#each items}}<tr><td>{{name}}</td><td>{{qty}} × {{formatNumber price}}</td><td>{{formatNumber (multiply qty price)}}</td></tr>{{/each}}</table><h3>Total: {{formatNumber (sumProduct items \"qty\" \"price\")}} USD</h3></body></html>","data": [{ "number": "INV-001", "customer": "Acme Ltd", "items": [{ "name": "Design", "qty": 2, "price": 150 }, { "name": "Hosting", "qty": 12, "price": 9.5 }] },{ "number": "INV-002", "customer": "Globex", "items": [{ "name": "Audit", "qty": 1, "price": 900 }] }],"fileNameTemplate": "invoice-{{number}}","pageFormat": "A4","pageNumbers": true}
This gives invoice-INV-001.pdf and invoice-INV-002.pdf.
Template language: Handlebars. {{field}} is HTML-escaped, {{{field}}} inserts raw HTML, {{#each list}}…{{/each}} loops, {{#if field}}…{{/if}} tests. Extra helpers: multiply, add, sum list "field", sumProduct list "qty" "price", formatNumber value 2, uppercase, date, eq. {{_index}} is the row number (1, 2, 3…).
Example: web pages with page numbers
{ "urls": [{ "url": "https://en.wikipedia.org/wiki/PDF" }, { "url": "https://example.com" }], "pageFormat": "Letter", "pageNumbers": true }
Input
| Field | Default | Notes |
|---|---|---|
| Web page URLs | Public http(s) pages, one PDF each | |
| HTML document / File name | One PDF from your HTML | |
| HTML template / Data rows / File name template | One PDF per data row | |
| Page size | A4 | A4, Letter, Legal, A3, A5, Tabloid |
| Landscape | Off | |
| Margins | 10 mm | CSS style: 10mm, 10mm 15mm, 1in 0.5in 1in 0.5in. 18 mm top/bottom when a header or footer is on |
| Print backgrounds | On | |
| Scale | 1 | 0.1 to 2 |
| Page numbers | Off | Adds "3 / 12" at the bottom |
| Header HTML / Footer HTML | Use <span class="pageNumber">, totalPages, date, title, url. Give it a font-size | |
| CSS media | Print = like the browser's Save as PDF. Screen = like the page looks on screen | |
| Hide cookie banners | On | For URLs |
| Hide these elements | CSS selectors, e.g. .chat-widget | |
| Wait until / Wait for selector / Extra delay | Page loaded | For slow or script-heavy pages |
| Timeout per document | 45 s | |
| Parallel documents | 4 | |
| Max documents | 10,000 |
Output
Every PDF is saved in the run's key-value store under its file name. The dataset has one row per document:
{"source": "template","url": null,"rowIndex": 0,"fileName": "invoice-INV-001.pdf","status": "ok","pdfUrl": "https://api.apify.com/v2/key-value-stores/abc123/records/invoice-INV-001.pdf","pages": 1,"bytes": 18121,"title": null,"httpStatus": null,"finalUrl": null,"error": null,"durationSecs": 0.1,"createdAt": "2026-11-13T12:46:10.512Z"}
Failed documents have status: "failed" and an error, for example The page answered HTTP 404.
Pricing
$3 per 1,000 PDFs ($0.003 each), whatever the page count. No start fee. Failed documents are free. Apify's free plan credit covers about 1,600 PDFs a month.
| You make | You pay |
|---|---|
| 100 invoices | $0.30 |
| 1,000 web page PDFs | $3.00 |
| 10,000 certificates | $30.00 |
Use it from the API, n8n, Make or Zapier
Call the actor with the Apify API or the Apify app in n8n, Make or Zapier, then read the dataset for the pdfUrl links.
curl -X POST "https://api.apify.com/v2/acts/blueberry_rainstorm~html-to-pdf/run-sync-get-dataset-items?token=YOUR_TOKEN" \-H "Content-Type: application/json" \-d '{"html": "<h1>Hello PDF</h1>", "fileName": "hello"}'
FAQ
Can I use my own fonts? Yes. Load them in your HTML with @font-face or a Google Fonts <link>. The actor waits for fonts before printing.
Why does my page look different from the screen? Many sites have print styles. Set CSS media to Screen to get what you see in the browser.
My header or footer is tiny or missing. Chrome prints header and footer HTML at a very small default size: set font-size (e.g. 9px) in your template, and keep top/bottom margins at 12 mm or more.
Can it open pages behind a login? No. It converts public pages and the HTML you send.
Can my HTML read local files? No. file: URLs are blocked inside documents.
How long are the PDFs kept? In the run's key-value store, for as long as your Apify plan keeps run storage. Download them or copy them to your own storage if you need them longer.
Acceptable use
Convert only pages and content you have the right to copy. Don't use this tool to copy paywalled or copyrighted material for redistribution. You are responsible for the documents you create.
More from Pandapi 🐼
Pandapi makes friendly, no-nonsense data tools: simple input, clean output, and fair pay-per-result prices. Found a bug or need a feature? Open an issue on the Issues tab and we answer fast.
- Web Page to Markdown: clean, chunked Markdown from any URL or sitemap, ready for AI and RAG
- PDF to Text, Markdown & Excel: text, Markdown and real Excel tables from any PDF, with OCR
- Website Contact Details Scraper: business emails, phones and social links, one row per website
- Website Screenshot: full-page and mobile screenshots or PDFs of many URLs at once
- Broken Link Checker: every 404, dead link and redirect on a site, with the page it is on
- Public Tenders Feed: government tenders and contract awards from six official portals
- App Store Reviews Scraper: iOS reviews, ratings and app details from about 180 countries
- Google Play Reviews Scraper: Android reviews with developer replies, ratings and app data, many languages
- Hacker News Scraper: stories, comments, Show HN and job posts, filtered your way