Image Transforms

Placeholder Image

Generate a placeholder image of any size with a text label. Returns SVG by default; ask for PNG, JPEG or WebP if you need a raster image.

GET/api/placeholder?width=&height=

Query parameters

NameTypeRequiredDescription
widthintegerOptionalWidth in pixels (1-2000). Default 300.
heightintegerOptionalHeight in pixels (1-2000). Default 200.
textstringOptionalLabel text. Default is the dimensions, e.g. "300 x 200".
bgstringOptionalBackground hex color, e.g. 336699. Default cccccc.
fgstringOptionalText hex color. Default 555555.
formatstringOptionalsvg (default), png, jpeg or webp.

Try it

Saved only in this browser. Requests use your key and count toward your quota. Get a key

GET /api/placeholder

Example request

curl "https://your-app.com/api/placeholder?width=400&height=200&text=Hello%20World&bg=336699&fg=ffffff&format=png" \
  -H "x-api-key: YOUR_API_KEY" \
  --output placeholder.png

Response

Content-Type: image/svg+xml (or the requested raster format) — the generated placeholder.