Image to Base64

Turn an image into a Base64 data URI, plus ready-made HTML and CSS snippets.

Runs on this device

When to inline an image

  • A data URL saves one HTTP request, which suits small icons and logos.
  • Base64 text is about a third larger than the original file.
  • Keep large images as separate files so they can be cached and do not bloat HTML or CSS.