mocop
Browse · Docs · Guide · Analyze

HTML to Image API

API by HTML to Image (html2img) · rest

Convert HTML, CSS or any public URL into a PNG image or a vector PDF, rendered in real headless Chrome. JSON in, a CDN URL out. When to use this API. Reach for it whenever your program needs a picture of something that is easier to describe as markup than to draw: Open Graph and social share cards generated per page, invoices, receipts, tickets and certificates as attachments, screenshots of pages you do not control, code and repository cards, charts and dashboard exports. It replaces running your own Puppeteer or Playwright cluster: no Chrome binary to ship, no memory ceiling to tune, no version drift. Which endpoint. POST /html when you generate the markup yourself, which is most cases and the cheaper path to debug. POST /screenshot when you only have a URL. POST /v1/templates/{slug} when a named template already draws what you want and you would rather post a JSON payload than write HTML. Authentication. One header, X-API-Key, on every request except GET…

Endpoint: https://app.html2img.com/api

Verification: observed. Source: crawl.

Capabilities (5)

  • Render HTML to a PNG or PDF
  • Read the account behind the calling key
  • Service liveness check
  • Capture a public URL as a PNG or PDF
  • Render a named template from a JSON payload
About · Contact · Privacy