Skip to content
@html2img

html2img

Providing free HTML to image APIs, including screenshot APIs, opengraph image generation APIs and templates, and lots more: https://html2img.com
HTML to Image

HTML to Image API

Convert HTML, CSS or any URL into a PNG with a single API call.

Website · Docs · Templates · Tools · Pricing · Compare

Free tier, 25 renders a month Getting started docs Sign up, no card required


HTML to Image is a REST API that turns raw HTML and CSS, a live URL, or a named JSON template into a PNG in seconds. Every render runs in real Chrome, so flexbox, grid, custom properties, web fonts and inline JavaScript behave exactly as they do in the browser. The first 25 renders each month are free, with no card required.

This organisation hosts the official client libraries for the API. Watch or star it to get notified when they ship.

Quick start

Send some HTML, get back a hosted PNG.

curl -X POST https://app.html2img.com/api/html \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"html": "<h1>Hello world</h1>"}'
{
  "success": true,
  "credits_remaining": 95,
  "id": "abc123",
  "url": "https://i.html2img.com/abc123.png"
}

Grab a key from your dashboard, then read the getting started guide and the authentication docs.

Three ways to render

Endpoint Use it for Docs
POST /api/html Your own markup and CSS, full design control html parameter
POST /api/screenshot Capturing a public URL you already host url parameter
POST /api/v1/templates/[slug] A tested design, JSON in, PNG out browse templates

The base URL for every endpoint is https://app.html2img.com. Full parameter reference is in the docs.

What you can build

There are 25 named templates in total, covering social, commerce, content and marketing.

Free browser tools

No sign-up needed. Build an image in the browser, then move to the API when you want to automate it.

See the full image generation tools hub.

Language guides

Worked examples for the seven languages developers reach for most. Anything that can make an HTTP request will work.

PHP · Laravel · Ruby on Rails · Python · JavaScript and Node.js · React · Vue

Built for production

  • Real Chrome rendering so your output matches the browser. Features
  • Webhook delivery for renders that run past the 30 second sync window. webhook_url docs
  • DPI control from 1x to 4x for retina output when you need it. dpi docs
  • Custom fonts from Google Fonts, Adobe Fonts and self-hosted @font-face, all server-side.
  • Global CDN, with images served from i.html2img.com.

How it compares

Honest, side-by-side notes against the common alternatives, covering pricing, features and migration effort.

Guides and articles

Official packages

Client libraries are in development and will live here under this organisation.

Language Package Status
PHP Composer In development
Laravel Composer In development
JavaScript and Node.js npm In development
Python, Ruby and more Planned

Until they land, the API works from any language over HTTP. Start with the language guides.

Pricing

Start free with 25 renders a month and no card. Paid plans raise the render volume as you grow. See pricing.

Links

Website · Features · Templates · Tools · Docs · Compare · Articles · Pricing · About · Contact


Built by the team behind HTML to Image.

Create a free account · Login

© 2026 HTML to Image

Popular repositories Loading

  1. .github .github Public

  2. html2img-php html2img-php Public

    Framework-agnostic PHP SDK for https://html2img.com service (HTML to Image API/Screenshot API)

    PHP

  3. html2img-laravel html2img-laravel Public

    Laravel integration for https://html2img.com service (HTML to Image API/Screenshot API)

    PHP

Repositories

Showing 3 of 3 repositories

People

This organization has no public members. You must be a member to see who’s a part of this organization.

Top languages

Loading…

Most used topics

Loading…