SVG is vector markup
Instead of storing pixels, SVG stores shapes, paths, text, and attributes.
what is an svg file
An SVG file is XML markup that describes vector graphics. It scales cleanly, can be styled, and can be inspected as code.
Instead of storing pixels, SVG stores shapes, paths, text, and attributes.
Vector geometry can render at many sizes without the blur of raster images.
Because SVG is XML, it should be reviewed and sanitized when it comes from untrusted sources.
A small SVG shows how markup becomes an image.
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 160 96" role="img"><title>Check badge</title><rect width="160" height="96" rx="14" fill="#0e7c66"/><path d="M39 55l18 18 64-64" fill="none" stroke="white" stroke-width="10" stroke-linecap="round" stroke-linejoin="round"/></svg>
Browsers, design tools, code editors, and online SVG viewers can open SVG files.
SVG is better for scalable graphics; PNG is better for detailed raster images and screenshots.