Image to Base64

Convert PNG, JPG, WebP, GIF, SVG and ICO images to Base64 data URIs with ready <img>, CSS and Markdown snippets, or decode a Base64 string back to a downloadable image.

Runs locally — nothing is uploaded
Drop images to encode

PNG, JPG, WebP, GIF, SVG, ICO · several at once · or browse

How to use Image to Base64

  1. Drop one or more images.
  2. Pick the snippet you need: data URI, raw Base64, <img>, CSS or Markdown.
  3. Copy it — or switch tabs to decode Base64 back into an image.

FAQ

When should I inline an image?

Only for tiny icons and placeholders (a few KB). Base64 adds about 33% to the size and can’t be cached separately, so larger images are better as normal files.

About the Image to Base64

Inline small icons and placeholders as data URIs to save an HTTP request. Keep it for images under a few KB — larger files bloat your CSS. For text and files in general, use the Base64 Encoder / Decoder encoder; to shrink SVG markup first, run it through the CSS & HTML Minifier. Need a quick placeholder graphic? The Placeholder Image Generator tool can copy an SVG data URI directly.

Also useful: Format Converter · Favicon Generator

Popular searches

People find Image to Base64 by searching for:

  • image to base64
  • base64 image encoder
  • png to data uri
  • base64 to image
  • inline image css
  • svg to base64