Pay-per-use · No subscriptions

Replace wkhtmltopdf with a Modern PDF API

No deprecated Qt. No installation. Chromium rendering via REST API.

wkhtmltopdf is based on an outdated WebKit engine and is no longer maintained. Modern CSS (Flexbox, Grid, CSS variables) often renders incorrectly. HTML2DocHub uses a current Chromium build — the same engine as Google Chrome — for pixel-perfect rendering of any modern HTML.

Why developers choose HTML2DocHub

Chromium (Chrome) rendering — not outdated WebKit
Supports modern CSS: Flexbox, Grid, CSS variables, custom fonts
No installation, no system dependencies, no PATH configuration
REST API — works from any language, any platform
No segfault crashes or memory corruption issues
Maintained and updated with each Chrome release
Works on all architectures: x86, ARM, Apple Silicon
Pay per page — no server licensing costs

Code Examples

Before: wkhtmltopdf (deprecated CLI)bash
# wkhtmltopdf: installation headaches, old rendering engine
# Ubuntu: apt install wkhtmltopdf (outdated version)
# macOS: brew install wkhtmltopdf (ARM issues)

wkhtmltopdf \
  --page-size A4 \
  --margin-top 20mm \
  --margin-bottom 20mm \
  input.html output.pdf

# Problems:
# - Flexbox/Grid may not render correctly
# - JavaScript execution is limited
# - No longer actively maintained
After: HTML2DocHub API (modern Chromium)curl
# HTML2DocHub: REST API, current Chromium, works everywhere
curl -X POST https://api.html2dochub.com/v1/render \
  -H "X-API-Key: sk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "pdf",
    "html": "'"$(cat input.html)"'",
    "options": {
      "format": "A4",
      "margin_top": "20mm",
      "margin_bottom": "20mm",
      "print_background": true
    }
  }' | python3 -c "import json,sys; print(json.load(sys.stdin)['''download_url'''])"
Python – wkhtmltopdf replacementpython
# Before (pdfkit / wkhtmltopdf)
import pdfkit
pdfkit.from_file("input.html", "output.pdf")
# Requires wkhtmltopdf binary, PATH config, etc.

# After (HTML2DocHub) — no binary dependencies
import requests

with open("input.html") as f:
    html = f.read()

resp = requests.post(
    "https://api.html2dochub.com/v1/render",
    headers={"X-API-Key": "sk_live_YOUR_KEY"},
    json={"type": "pdf", "html": html, "options": {"format": "A4"}},
)
pdf_url = resp.json()["download_url"]

# Download
import urllib.request
urllib.request.urlretrieve(pdf_url, "output.pdf")

Simple, transparent pricing

Pay only for pages rendered. No subscriptions. No minimum monthly fee.

1 page PDF:~₹0.10
10 page PDF:~₹0.80
100 pages/day:~₹8/day
See full pricing details

Frequently Asked Questions

Why is wkhtmltopdf problematic?+
wkhtmltopdf is based on a WebKit fork from 2012 that is no longer maintained. Modern CSS features like Flexbox, CSS Grid, custom properties, and many web fonts render incorrectly or not at all.
Will my existing HTML templates work?+
Yes, and they'll likely render better. Chrome renders all modern HTML and CSS correctly, often fixing layout issues you may have worked around in wkhtmltopdf.
Does it support wkhtmltopdf features like headers and footers?+
Yes. Pass `header_template` and `footer_template` HTML strings in the options object.
What about running in CI/CD or serverless?+
wkhtmltopdf requires a binary install that's unavailable in many serverless environments (AWS Lambda, Vercel, etc.). HTML2DocHub is a pure HTTP call — works anywhere.

Start rendering PDFs today

Free account. No credit card required. API ready in minutes.

Get your free API key