Browser processing Input is processed on your device. Privacy & storage

Image to Base64 Converter

Turn an image into a Base64 data URL you can inline into HTML, CSS, JSON or a config file. Drop a file below and copy the string — the conversion runs entirely in your browser, so nothing is uploaded anywhere.

Image → Base64
Drop an image here or click to choose a file
PNG · JPG · WebP · GIF · SVG — one file at a time

Why convert an image to Base64?

A Base64 data URL embeds the picture inside the file that references it. That removes one HTTP request, keeps small icons and logos working offline, and lets you paste a single self-contained string into JSON, YAML or a database field. The trade-off is size: Base64 is about 33% larger than the binary file, so it suits small assets (roughly under 10 KB) — for photos, keep the file separate.

Which output should I pick?

Data URL is the universal form for HTML attributes, JSON values and Markdown. Raw Base64 is what an API or an email attachment field usually expects. CSS and HTML give you a ready-made snippet to paste straight into a stylesheet or a template.

FAQ

Are my images uploaded to a server?

No. The file is read locally with the browser's FileReader API and never leaves your device, which makes it safe for private screenshots and internal assets.

Is there a file size limit?

No artificial limit — it depends on your device's memory. Keep in mind that inlining large images inflates your HTML by about a third, so big files are usually better served as separate, cacheable assets.

Need the other direction?

Paste a data URL or raw Base64 into the Base64 to Image converter to get the picture back.