Skip to content
ConvenTools

Image to Base64 — Encode an Image as a Data URI

Runs in your browser — your files never leave your device

Encode an image as a Base64 data URI, right in your browser. Drop an image and copy either the full data URI (ready for CSS or HTML) or the raw Base64. Your image is never uploaded.

Drop an image here, or click to choose
Encoded on your device — nothing is uploaded.

How to use it

  1. 1
    Choose an image

    Drop an image onto the drop zone, or click to select one.

  2. 2
    Copy the encoding

    Copy the full data URI, or just the raw Base64 string.

  3. 3
    Paste it in

    Use it in a CSS background, an <img> src, or anywhere a data URI is accepted.

Inline images without a request

A data URI embeds the image directly in your CSS or HTML, so the browser doesn’t make a separate network request for it. That’s handy for tiny icons, email templates, or bundling an image into a single file.

Frequently asked questions

Is my image uploaded to a server?

No. Encoding happens entirely in your browser — your image never leaves your device.

What is a data URI?

A string that encodes the whole image inline (data:image/png;base64,…), so it can be embedded directly in HTML or CSS.

Why is the Base64 larger than the file?

Base64 encoding adds about 33% overhead, so data URIs are best for small images.