Try the API free — no sign-up needed
50 free tokens on sign-up

Generate PDFs & Images
from HTML via API

Simple REST API for converting HTML to PDFs and images. Perfect for AI agents and automation workflows.

or try the API right now — no account needed ↓

🚀 Headless Chrome rendering⚡ Sub-2 second responses🔒 Enterprise security
No API key · No account · Real output

Try it right now

Run this in your terminal. You get a real hosted file URL back in under 2 seconds — no sign-up needed.

Request

bash
curl -s -X POST https://www.agent-gen.com/api/v1/generate/image \
  -H "Content-Type: application/json" \
  -d '{"html":"<h1 style=\"font-family:sans-serif;color:#4f46e5\">Hello from AgentGen!</h1>","width":1200,"height":630,"format":"png"}'

Response

JSON
{
  "url": "https://cdn.agent-gen.com/output/abc123.png",
  "watermarked": true,
  "format": "png",
  "width": 1200,
  "height": 630,
  "request_id": "v7k9x2mf4a"
}
Free tier adds a small watermark1 request / minute per IPSign up to remove limits →
< 2s
Average response time
99.9%
Uptime
50k+
Images generated
25k+
PDFs created

Trusted by people and agents building with

N8N
Zapier
OpenClaw

Try the playground

Write HTML on the left, see your PDF preview on the right. Call the API to generate real files — no sign-up needed.

Go to playground
HTML Input
PDF Preview

Ready to generate real files?

No account needed to start — call the API directly and get a real file back in seconds. Sign in for full access, no watermark, and higher limits.

Built for every use case

From AI agent tools to developer scripts to serverless functions.

OG Images

Generate unique Open Graph images for every blog post, product, or user profile.

Invoices

AI agents that collect invoice data and deliver a PDF download link in one turn.

Reports

Auto-generate weekly reports, dashboards, or analytics summaries as PDFs.

Certificates

Issue personalized certificates, diplomas, or badges at scale.

Screenshots

Capture HTML emails, UI previews, or component snapshots as images.

Agent Outputs

Give your AI agent a visual artifact to send back — not just text.

Get started in minutes

Choose your path — try instantly or sign up for the full experience.

Instant — no sign-up

Call the API right now with no account. Output includes a small watermark and is rate-limited to 1 request/min.

Try it ↑
1

Sign up free

Create an account and get 50 tokens instantly. No credit card required.

2

Buy more tokens

One-time purchase when you need more. No subscriptions.

3

Get your API key

Copy it from the dashboard.

4

Generate

Call the API from code or your agent. No watermark.

Simple token pricing

Buy once. Use whenever. Tokens never expire.

🎁

No sign-up needed to try — call the API right now, watermark included. Sign up for 50 free tokens to remove the watermark and get higher limits. No credit card required.

Starter

$9

500 tokens

$0.018 / token

Most popular

Growth

$39

2,500 tokens

$0.016 / token

Scale

$129

10,000 tokens

$0.013 / token

Frequently asked questions

Tokens are the currency of AgentGen. Generating an image costs 1 token. Generating a PDF costs 2 tokens per page. Temp file uploads are free.

No. Tokens never expire. Buy once, use whenever.

Yes — that's exactly what AgentGen is built for. Register a generatePdf or generateImage tool in your agent framework and call the API via HTTP.

Full modern HTML/CSS support via headless Chromium. Google Fonts, Flexbox, Grid, CSS animations (first frame) — anything Chrome supports.

Two ways to try for free. First: call the API right now with no account — you get real output instantly (a small watermark is added, rate-limited to 1 request/minute). Second: sign up and get 50 tokens instantly with no credit card — that's 50 image generations or 25 PDF pages, no watermark.

Generated files are stored on Cloudflare R2 and served via CDN. Temp uploads expire after 24 hours; generated output is retained for 30 days.

Ready to generate?

Join developers and AI agents that use AgentGen to produce PDFs and images at scale.

Your HTML is processed ephemerally, never stored