Integrations

Use HTML to Image in the stack you already work with.

There are official SDKs for PHP, JavaScript, Python and Ruby, framework packages for Laravel and Django, plugins for WordPress, Statamic and Craft CMS, and an Action for generating assets in CI. Each one covers the same three jobs: turning your markup into an image, capturing a live URL, and producing a vector PDF. Each page below is a complete implementation guide for that ecosystem, not a signpost back to the reference.

The same call in four languages

Every SDK wraps one REST API, so the shape of a render is the same wherever you call it from: a document in, a hosted URL out.

$client = new Html2img\Html2imgClient(getenv('HTML2IMG_API_KEY'));

$response = $client->html(new Html2img\Request\HtmlRequest(
    html: $document,
    width: 1200,
    height: 630,
));

echo $response->url;

Not in one of these languages? Any HTTP client works. POST JSON to https://app.html2img.com/api/html with an X-API-Key header, as described in the getting started guide.

What every integration shares

The packages differ in shape because the ecosystems do. What they render, and how they fail, does not.

One key, every endpoint

The same API key renders HTML, captures screenshots, fills named templates and produces PDFs. No separate products, no separate billing.

Real Chrome, everywhere

Every package posts to the same renderer, so flexbox, grid, custom properties, web fonts and inline JavaScript behave exactly as they do in your browser.

Nothing to host

No Chrome binary in your image, no Puppeteer version drift, no memory ceiling to tune. Your application makes one HTTP request.

Typed failures

Each SDK maps every API status onto its own exception or error class, so an out-of-credits response is something you can catch, not a string you have to parse.

Pick your stack and start rendering

50 free credits when you sign up. One credit renders one image or one PDF.