Format Guides

SVG to PNG — When and Why to Rasterize Vector Graphics

· 3 min read · Format Guides

SVG files are perfect for logos, icons, and illustrations because they scale to any size without losing quality. But there are plenty of situations where you need a rasterized PNG instead — and knowing when to convert matters.

When to Rasterize SVG to PNG

Email: Most email clients strip SVG from HTML emails or display it inconsistently. Convert logos and icons to PNG before embedding in newsletters.

Social media uploads: Platforms like Twitter, Instagram, and LinkedIn don’t accept SVG. Upload a high-resolution PNG instead.

Favicons: While modern browsers support SVG favicons, you still need a PNG fallback for older browsers and for apple-touch-icon. Generate both with the SVG to ICO converter.

Presentations and documents: PowerPoint, Google Slides, and Word handle PNG reliably but often mangle SVG rendering.

Image processing pipelines: If you need to composite, watermark, or process images programmatically, raster formats are easier to work with.

DPI and Resolution

The key decision when rasterizing SVG is the output resolution. SVG has no inherent pixel dimensions — it’s defined by a viewBox. You choose the size:

  • 1x (standard DPI): 72 or 96 PPI — fine for web at standard displays
  • 2x (retina): Double the dimensions for sharp rendering on high-DPI screens
  • 3x or 4x: For print or when you need maximum detail

For example, a logo displayed at 200x50 on your website should be exported as: - 200x50 for standard screens - 400x100 for retina screens

KoalaPic’s SVG to PNG converter lets you specify the exact output dimensions.

Transparency

SVG inherently supports transparency, and PNG preserves it perfectly. When converting SVG to PNG, all transparent areas remain transparent — no white background fill.

If you need a white background (for example, for a JPG conversion), convert to SVG to JPG instead, which automatically fills transparent areas.

Text Rendering

SVG files that use custom fonts may render differently when converted if the font isn’t available. Two solutions:

  1. Convert text to paths in your vector editor before uploading (Illustrator: Type > Create Outlines; Inkscape: Path > Object to Path)
  2. Use web-safe fonts in your SVG

KoalaPic uses CairoSVG for rendering, which handles most standard SVG features including gradients, filters, and clipping masks.

Batch Processing

For icon libraries or design systems with dozens of SVG files, use the API to batch convert:

for svg in icons/*.svg; do
  curl -X POST https://koalapic.com/api/v1/convert \
    -H "Authorization: Bearer kp_your_api_key" \
    -F "file=@$svg" \
    -F "output_format=png" \
    -F "width=512"
done

When NOT to Rasterize

Keep SVG when you can — it scales perfectly, has tiny file sizes for simple graphics, and is editable. Only convert to PNG when the target platform requires it.

Next Steps

Enjoyed this article? Share it.

Related Posts

Send Feedback

Thank you! We'll get back to you soon.

Install KoalaPic

Add to your home screen for quick access

Cookie & Storage Preferences

We use cookies and local storage to improve your experience. Essential storage is always active for core functionality. Learn more

Essential

CSRF protection, dark mode, error tracking. Always active.

Functional

Conversion presets, UI preferences, PWA install state.

Analytics

Anonymous usage statistics to improve the service.