Chart Image API: Turn JSON into SVG and PNG chart images

An HTTP endpoint that turns a JSON config into an SVG or PNG. No libraries, no browser, no client-side JavaScript. One URL, one image – embed it in emails, dashboards, Slack bots, PDF reports, or anywhere an <img> tag works.

How the chart image API works

1. Write a JSON config. A flat data array, a mark type, and a theme. Typically 5–15 lines.

{
  "version": "2026-03-20",
  "theme": "editorial",
  "title": "Streaming Subscribers",
  "subtitle": "Paid subscribers, millions",
  "marks": [
    { "type": "line", "fill": "fill" },
    { "type": "dot", "fill": "fill", "r": 3 }
  ],
  "data": [
    { "x": "2020", "y": 192.9, "fill": "Netflix" },
    { "x": "2020", "y": 155, "fill": "Spotify" },
    ...
  ],
  "y": { "label": "Millions" }
}

2. Send it to the API. Two options – a GET request for simple embeds, or a POST request for authenticated access.

GET (no auth needed)

<img
  src="https://szum.io/chart
    ?config={...}"
  alt="Line chart"
  width="540"
  height="360"
/>

POST (with API key)

curl -X POST \
  https://szum.io/chart \
  -H "Authorization: Bearer sz_live_..." \
  -H "Content-Type: application/json" \
  -d '{ "version": "2026-03-20", ... }' \
  -o chart.svg

3. Get an image back. The API renders the chart server-side and returns the image. No headless browser, no canvas, no client-side JavaScript.

Default output with the editorial theme. No custom styling.

Chart image API output

Every chart below uses default theme settings. No colors specified, no typography overrides, no spacing tweaks. The theme handles it.

Stacked area – modern theme

Three series stacked over time. The modern theme handles background, grid, text colors, and palette. One fill field in the data does the rest.

Bar chart with labels – mark composition

A barY and a text mark in the same chart. Two marks, one data array – the text mark reads the Y values and positions them above each bar.

Scatter plot – dark theme

A dot mark with fill mapped to a data field. The classic Gapminder view – one dot per country, colored by region.

Curated themes instead of configuration

Most chart tools give you infinite configuration and zero opinion. You get a chart that looks like every other chart, unless you spend an hour on colors, typography, spacing, and grid lines.

szum ships six curated themes: modern, editorial, dark, technical, pastel, and neon. Each one handles typography, color palette, spacing, grid lines, and axis styling. One property replaces dozens of options.

On the Pro plan, use themeOverrides to customize colors, spacing, and typography. Set any of 1,938+ Google Fonts with a single property – fonts are fetched, cached, and embedded automatically.

GET and POST chart image API endpoints

GET /chart

URL-encode the config as a query parameter. No API key required –200 renders per month per IP address, no signup. Perfect for <img> embeds, quick prototypes, and testing.

POST /chart

JSON body with a Bearer token. Required for authenticated requests. Higher rate limits (30 req/sec vs 10), and your renders count against your plan quota instead of the IP limit.

Signed GET (Pro)

Generate HMAC-signed URLs that authenticate GET requests without exposing your API key. The signed URL works like any other image URL – embed it in emails, Markdown, or Slack. Available on the Pro plan.

Identical GET requests are served from the edge CDN and do not count against your render limit. See the API reference for full details.

Start making API calls.

Free API key, 1,337 renders/month, commercial license.

Try the playground first

Chart Image API pricing

Three tiers. No seat-based pricing – you pay for renders, not users.

Unauthenticated (no signup)

200 renders per month per IP address. No API key, no account. Rate limit: 10 requests per second. Good for prototyping and testing.

Free

1,337 renders per month, 1 API key, commercial license. Rate limit: 30 requests per second with a key. MCP server, Figma plugin, edge CDN caching – all included. Sign up in 30 seconds.

Pro ($29/month)

100,000 renders included, 10 API keys, custom themes, 1,938+ Google Fonts, signed URLs. Overage: $1 per 5,000 additional renders (opt-in). Annual billing: $23/month (save 20%). See plans and limits for the full breakdown.

Chart generation for AI agents and automation

szum is an infrastructure for generating charts programmatically.

  • MCP server. AI agents connect via Model Context Protocol. Render, validate, and iterate on charts through tool use.
  • Figma plugin. Designers insert charts into mockups without leaving Figma. Same grammar, same themes, same output.
  • Any language. No SDK required. Any language that can make an HTTP request works – copy-paste examples in Node, Python, Go, Ruby, and curl.
  • JSON Schema. Available at /schema.json for validation and IDE autocomplete.
  • LLM-friendly. /llms.txt provides a compact API reference designed for LLM context windows. Flat, shallow configs mean fewer hallucinated field names.

Where to embed chart images

  • Emails. <img> tag with a chart URL. Works in every email client – Gmail, Outlook, Apple Mail. See the email guide.
  • Slack and Discord bots. Unfurl a URL, show a chart. No JavaScript execution needed.
  • PDF reports. Server-side PDF generators need an image URL, not a client-side rendering library.
  • Dashboards. Embed SVGs directly or use <img> tags for PNG. Edge-cached for instant loading.
  • CI/CD and monitoring. Generate charts in pipelines, post to Slack or GitHub comments. Coverage trends, performance regressions, deploy metrics – as images.
  • Notion and Confluence. Paste a chart URL as an image embed. Updates when the data changes.

How szum compares to other chart image APIs

szum is not the only chart image API. The right choice depends on what you value.

  • szum vs. QuickChart. QuickChart renders Chart.js configs – more chart types, more output formats, but Chart.js defaults. szum uses a purpose-built grammar with curated themes. Simpler configs, better-looking output, lower price.
  • szum vs. Google Image Charts. Google shut down its chart image API in 2019. QuickChart is the drop-in replacement. szum is the modern alternative – readable JSON instead of cryptic URL parameters.
  • Headless browser screenshots. Puppeteer or Playwright rendering a Chart.js page. Works, but slow (1–3 seconds per chart), expensive to host, and brittle to maintain. A chart image API returns the same result in milliseconds with zero infrastructure.

Frequently asked questions

What is a chart image API?
An HTTP endpoint that accepts a chart definition and returns a static image – SVG or PNG. No JavaScript runs on the client. You send a JSON config describing your chart (mark type, data, theme), and the API renders it server-side. The result is an image URL you can embed in emails, Slack messages, PDF reports, dashboards, or anywhere an <img> tag works.
How do I generate a chart from JSON?
Send a JSON config to https://szum.io/chart. Use a GET request with the config URL-encoded as a query parameter (no signup needed), or a POST request with a Bearer token for authenticated access. The response is the rendered chart image. Try it in the playground to see it in action.
Is the szum chart image API free?
Yes. The free plan includes 1,337 renders per month with a commercial license. You can also make unauthenticated requests without signing up – 200 renders per month per IP address. The Pro plan is $29/month for 100,000 renders, custom themes, and signed URLs. Sign up to get your API key.
What chart types does szum support?
10 composable mark types: barY, barX, line, dot, areaY, areaX, text, ruleX, ruleY, and pie. Marks compose – combine a barY and a text mark to get labeled bars, or a line and a ruleY mark to get a line chart with a threshold.
Can AI generate charts with szum?
Yes, and this is a deliberate design choice. szum's grammar is flat and shallow – no deeply nested options objects, no ambiguous field names. LLMs produce valid configs more reliably than with Chart.js or other charting libraries. szum also ships an MCP server so AI agents can render and validate charts through tool use.