An SVG can gain different dimensions or margins depending on its width, height and viewBox. Before editing numbers, separate output size from artwork coordinates.

Output pixels and artwork coordinates

With viewBox="0 0 100 50", the artwork uses a 100-by-50 coordinate range. Exporting at 800×400 does not require multiplying every shape coordinate by eight.

Keep the intended ratio

A 100×50 drawing is 2:1. So is 800×400, but not 800×800. A different ratio can introduce padding or cropping depending on preserveAspectRatio. Change the viewBox origin and bounds only when you intend to change the visible region.

What sanitization removes

PolishTools does not insert the original SVG into the page. Previews and PNGs use a source restricted to supported shapes and attributes. Artwork relying on external images, stylesheets, scripts, use references or filters can lose parts.

If it changes, inspect the cleaned source and export simpler shapes or paths from your editor. If letterforms must stay fixed, consider converting text to paths in the source editor.

Example: a 2:1 symbol at 800×400

Export a symbol with viewBox 0 0 100 50 as a PNG for a web page.

Steps

  1. Load the SVG and keep its viewBox.
  2. Set width 800 and height 400, then generate.
  3. Check text and referenced artwork before downloading the PNG.

Result

The PNG is 800×400 and retains the 2:1 ratio. Unsupported artwork may need adjustment in the source editor first.

Frequently asked questions

What if I leave viewBox blank?

The source viewBox is used. If absent, valid positive pixel dimensions define the bounds. With neither, the input is rejected.

References

Related guides