CustomJS: HTML to PDF, PNG & Merge icon

CustomJS: HTML to PDF, PNG & Merge

All-in-one toolkit for PDF, HTML, JSON and file conversions

Convert → HTML to PDF

AI-generated

Summary

Convert the supplied HTML to a PDF using the configured page width and height. The result is returned as binary data on the data property, with the input item’s JSON retained.

Inputs

  • HTML (required) — HTML content to convert.
  • PDF Page Width in Millimeters — PDF page width in millimeters; defaults to 210.
  • PDF Page Height in Millimeters — PDF page height in millimeters; defaults to 297.
  • Output Filename — Filename for the generated PDF, including its extension; defaults to output.pdf.

Output shape

One output item per input item, containing the original JSON and a binary PDF in data.

If the conversion returns no data or an empty buffer, the output retains the input JSON but has no binary property. Each output is paired with its corresponding input item.

Links

Discussion