skillfed

vl-convert-python

Convert Vega-Lite chart specifications to SVG, PNG, or Vega

vl-convert-python v1.9.0.post1 1.4M downloads/30d#3,969 on PyPI1
Permissive license BSD-3-Clause AGING released

What it is and what it does

vl-convert-python is a Python wrapper around a Rust library that converts Vega-Lite visualization specifications into static images (SVG or PNG) or into lower-level Vega specifications. It runs Vega-Lite and Vega JavaScript libraries inside a v8 runtime, then handles font metrics and SVG-to-PNG conversion. The package is self-contained—it needs no external web browser, Node.js, or system dependencies beyond what the wheels provide.

You can use it to export charts from Altair (which generates Vega-Lite JSON) or from raw Vega-Lite specifications. The main functions convert a specification string and optional parameters like scale for PNG resolution or vl_version to target a specific Vega-Lite schema version.

Use it for:

  • Export Altair charts to PNG or SVG for embedding in reports, dashboards, or web pages without a live rendering engine
  • Convert Vega-Lite JSON specifications to static images in batch processing or server-side workflows
  • Generate chart images programmatically for automated document generation or email delivery
  • Inspect the low-level Vega specification that Vega-Lite compiles to for debugging or further manipulation

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Converts Vega-Lite chart specifications to static SVG or PNG images, or to Vega specifications, with no external dependencies.

Yes, if you need to export Vega-Lite or Altair charts to static images without a browser or Node.js dependency. The package is dependency-free at runtime, has no known vulnerabilities, and works on common platforms. Install friction is moderate due to compiled wheels, but pre-built binaries are available. Maintenance is aging (205 days since last release, minimal repository activity), so expect slower response to issues, but the core functionality is stable.

Install

vl-convert-python on PyPI

pip

pip install vl-convert-python

uv

uv add vl-convert-python

poetry

poetry add vl-convert-python

Installing vl-convert-python

Before you install

Medium install friction due to compiled Rust bindings; wheels are available for common platforms (macOS x86_64 and ARM, Linux x86_64 and ARM64, Windows x64). Last release was 205 days ago; repository shows minimal activity (1 star, aging maintenance status).

License in practice

BSD-3-Clause is permissive; you can use, modify, and distribute this package freely in commercial and private projects provided you include the license notice.

Quickstart

pip install vl-convert-python

import vl_convert

vl_spec = '{"$schema": "https://vega.github.io/schema/vega-lite/v5.json", "mark": "circle"}'
svg_str = vl_convert.vegalite_to_svg(vl_spec=vl_spec)
png_data = vl_convert.vegalite_to_png(vl_spec=vl_spec)

Requires Python >=3.7; compiled wheels available for macOS (x86_64, ARM64), Linux (x86_64, ARM64), and Windows (x64) — other platforms may require building from source.

Verify before relying

  • Performance characteristics (conversion speed, memory usage) for large or complex charts
  • Supported Vega-Lite schema versions and any known compatibility limits
  • Quality and fidelity of PNG output at different scale factors

Package facts

License BSD-3-Clause (permissive)
Python support supports the current Python release (>=3.7)
Install friction medium — platform-specific wheel
Runtime dependencies none
Maintenance aging — 205 days since the last release
Last repo commit
First released
Downloads 1,389,181/month — #3,969 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: vl_convert_python-1.9.0.post1-cp37-abi3-macosx_10_12_x86_64.whl; vl_convert_python-1.9.0.post1-cp37-abi3-macosx_11_0_arm64.whl; vl_convert_python-1.9.0.post1-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; vl_convert_python-1.9.0.post1-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; vl_convert_python-1.9.0.post1-cp37-abi3-win_amd64.whl

Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Rust

Tags

vega-lite to svg png conversionconvert altair charts to imagesvega-lite static image exportchart specification renderingvega-lite to vega conversionheadless chart renderingvisualization export tool
visualization-exportvega-litealtair-integration

More Graphics packages