100% local, no upload

Image to Base64 Converter

Drop or upload an image to instantly get its base64 data URI, ready to paste into your code.

Click to choose an image or drag & drop it here PNG, JPEG, GIF, WebP, SVG — processed entirely in your browser
Uploaded image preview
File name- File type- File size- Dimensions-
Base64 data URI

How it works

1

Choose an image

Click the drop zone to browse for a file, or drag an image straight from your desktop into the box.

2

It's read instantly

Your browser reads the file with the FileReader API and encodes it as a base64 data URI on the spot.

3

Copy the result

Check the file size and dimensions, then press Copy to grab the full data URI for use in HTML or CSS.

FAQ

Is my image uploaded to a server?

No. The conversion uses the browser's built-in FileReader API entirely on your device. Your image never leaves your computer.

What image formats are supported?

Any image format your browser can read, including PNG, JPEG, GIF, WebP and SVG. The output data URI includes the correct MIME type automatically.

How do I use the base64 output in my code?

Copy the full data URI and paste it directly as the src of an <img> tag, or inside a CSS url() value, with no separate image file needed.

Try other tools