Convert a PNG
Menu
Documentation
Type to search. Use the down arrow to browse results, or Escape to close them.

Quickstart

Take a PNG from pixels to SVG, in the browser or from your application.

Your first SVG

Open the Vectali converter, choose a PNG, and run the conversion. Compare the original with the vector preview, then download the SVG.

Start with a clear logo or illustration with distinct shapes. The output follows the image you upload, so a cleaner source gives you a better starting point for editing.

  1. Choose your image. Upload a PNG up to 10 MiB and 4 million pixels.
  2. Inspect the result. Compare the edges and small details at the size you need.
  3. Download the SVG. Open it in your design tool or use it as an image on the web.

Make an API request

Send a multipart POST request to https://vectali.com/api/vectorize. The uploaded file belongs in a field named image.

curl --fail-with-body \
  --request POST \
  --form 'image=@logo.png' \
  https://vectali.com/api/vectorize \
  --output result.json

The JavaScript example uses a relative URL for code running on the Vectali origin. From your own application, call the endpoint from your server; browser requests from a different origin require CORS support.

The Python example uses the third-party requests package: install it with python -m pip install requests. It is an HTTP example, not a Vectali SDK.

Save the response

A successful request returns JSON. The svg property contains the SVG document as a string; save that string to a .svg file. Saving the entire JSON response as .svg will not produce a usable image.

# After the cURL example above, extract the SVG string.
python -c 'import json,pathlib; pathlib.Path("logo.svg").write_text(json.load(open("result.json"))["svg"], encoding="utf-8")'

Read the response reference for the other fields, or the full endpoint reference for request details.

Before you integrate

  • Check file limits before uploading.
  • Handle non-success status codes using the error reference.
  • Keep the original image so you can compare or re-export later.

The current endpoint does not require an API key. There is no client SDK to install.

A useful next step? Read the journal