Everything you need to go vector
API reference, guides, and developer docs for converting, editing, and shipping clean SVGs with SVGFast.
Guides & articles
Convert a PNG to SVG the right way
Prep, convert, and verify — a repeatable workflow for clean results.
GuideWhy SVG beats PNG for logos
Resolution independence, tiny files, and instant recoloring explained.
EngineeringInside the SVGFast engine
How fidelity scoring produces small files without quality loss.
GuideWhat is an SVG file?
Vector vs raster, what's inside the file, and when to use one.
TutorialHow to vectorize an image
Pick the right source, convert, and verify a clean result.
GuideJPG to SVG without losing quality
Prep a lossy JPG and verify the vector matches the original.
Convert images to SVG over HTTP
One endpoint takes a raster image and returns clean, optimized SVG from the same fidelity-first engine that powers the site. Free API access while SVGFast is in beta.
https://api.svgfast.com/vectorize
Authentication
Send your key in the X-Vectorize-Auth header on every request. Keys are created automatically when you sign in — grab one here. Keep it server-side; never ship a key in client code.
Request body
Send the image as multipart/form-data. Conversion options are tuned automatically during the beta — one field is all you need.
| Field | Type | Description |
|---|---|---|
| file | file · required | Raster image to vectorize. PNG, JPG, WebP, AVIF, or GIF, up to 10 MB. |
Responses
A successful request returns the optimized SVG document with Content-Type: image/svg+xml. Failures return JSON with a stable code you can branch on.
| Status | Code | Meaning |
|---|---|---|
| 400 | missing_file | No image field in the request. |
| 413 | file_too_large | Image exceeds the 10 MB limit. |
| 415 | invalid_file_type | Unsupported format — use PNG, JPG, WebP, AVIF, or GIF. |
| 503 | engine_unavailable | Engine briefly unreachable. Retry shortly. |
| 504 | engine_timeout | Conversion took too long. Try a smaller image. |
{
"error": {
"code": "file_too_large",
"message": "Image is too large. Maximum size is 10 MB."
}
}curl -X POST https://api.svgfast.com/vectorize \
-H "X-Vectorize-Auth: YOUR_API_KEY" \
-F "[email protected]" \
-o logo.svg
const form = new FormData();
form.append("file", input.files[0]);
const res = await fetch("https://api.svgfast.com/vectorize", {
method: "POST",
headers: { "X-Vectorize-Auth": "YOUR_API_KEY" },
body: form,
});
const svg = await res.text(); // optimized SVG markup
import requests
with open("logo.png", "rb") as image:
res = requests.post(
"https://api.svgfast.com/vectorize",
headers={"X-Vectorize-Auth": "YOUR_API_KEY"},
files={"file": image},
)
# res.text holds the optimized SVG document
open("logo.svg", "w", encoding="utf-8").write(res.text)
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">
<path d="M256 32 64 480h384z" fill="#3a86ff"/>
</svg>
Can't find what you need?
Head to support for FAQs and troubleshooting, or ask the community on GitHub.