CairoSVG

Convert your SVG files to PDF and PNG.

About CairoSVG

CairoSVG is:

Let's go!

Install

CairoSVG is available on PyPI, you can install it with pip:

$ pip install cairosvg

You can have more information and help in the "Installation" part of the documentation .

Convert

You can use CairoSVG as a standalone command-line program:

$ cairosvg image.svg -o image.png

Embed

You can also use CairoSVG as a Python 3 library:

$ python3
>>> import cairosvg
>>> cairosvg.svg2pdf(url='image.svg', write_to='image.pdf')

Want more?

Please read the documentation to learn more about how to use CairoSVG.

What's new?

Latest version of CairoSVG is 2.0.0rc4, released on July 16, 2016 (changelog).

Last call before 2.0.0

CairoSVG 2.0.0rc4 has been released today and may be the last release canditate before 2.0.0. It’s time to test and check that everything is OK for you, dear users and developers of CairoSVG!

2.0.0 is a new major version, its changelog includes:

I’d also like to thank the people who took some time to report issues, fix bugs and add new features. Your tireless help is really appreciated!