ConvertAPI

ConvertAPI demo page

A fixed page for trying HTML to PDF conversion

ConvertAPI keeps this page for code examples and tests. The URL to PDF examples in the ConvertAPI SDKs convert it, so they give the same result on every run: a two-page PDF with headings, a table, lists, a code block and an image. The page loads no scripts, web fonts, trackers or cookie banners. Read more about the HTML to PDF API.

Convert this page

Send the page's URL to the HTML to PDF converter. Replace YOUR_API_TOKEN with your API token:

curl -X POST https://v2.convertapi.com/convert/html/to/pdf \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -F "Url=https://cdn.convertapi.com/public/files/demo" \
  -F "StoreFile=true"

The response is JSON with a link to download the PDF.

What the PDF keeps

Paper sizes

Choose the page size with the PageSize parameter. Some common sizes:

SizePageSizeMillimetresInches
A3a3297 × 42011.69 × 16.54
A4a4210 × 2978.27 × 11.69
A5a5148 × 2105.83 × 8.27
Letterletter215.9 × 279.48.5 × 11
Legallegal215.9 × 355.68.5 × 14

Images

A scanned handwritten page
demo.jpg, a scanned handwritten page from the same folder as this page

How the SDK examples use this page

  1. The example sends this page's URL to the HTML to PDF converter.
  2. ConvertAPI opens the page in a browser, waits for it to load and prints it to PDF.
  3. The example saves the PDF it gets back.