Image to Base64

Turn a picture into a Base64 data URI to paste straight into HTML, CSS or JSON — no image file needed.

How it works

  • Choose the output style: a full data URI, the raw Base64 string, a CSS background-image rule, or a ready-made HTML <img> tag.
  • Base64 makes a file about a third larger, which is why it suits small icons, logos and UI shapes rather than large photos.
  • The exact MIME type is taken from the file, so the data URI works directly in every browser.
  • Encoding happens on your device; the image is never uploaded.