Toolbuns/Image → Base64

Image to Base64

Encode an image as a Base64 data URI to inline directly in HTML or CSS. Runs entirely in your browser.

Convert an image into a Base64 data URI you can paste straight into HTML, CSS, or JSON — no separate file needed. Encoded in your browser, never uploaded.

How to use Image → Base64

  1. Choose an image, or drop it onto the page.
  2. Copy the data URI, or grab a ready-made <img> or CSS snippet.
  3. Paste it into your code.

Frequently asked questions

When should I inline an image as Base64?

For tiny assets (icons, small backgrounds) it saves an HTTP request. For large images it's usually better to keep a real file, since Base64 adds about 33% to the size.

Are my images uploaded?

No. Encoding happens locally with the browser's FileReader; your image never leaves your device.

Related tools
Social Media Image ResizerCropConvertCompress