Convert Image to Data URI
Create a ready-to-copy data:image/...;base64 URL without resizing, recompressing, or removing metadata.
Create an embeddable image data URL
The preset reads the original image bytes, encodes them as Base64, and adds the detected image MIME prefix.
A data URI is convenient for small embedded assets, but Base64 text is roughly one third larger than the source bytes and does not share a normal browser cache entry.
How to convert an image to a data URI
- 1
Add an image
Choose a supported image stored on your device.
- 2
Keep the raw preset
The page starts with metadata removal, resizing, and format conversion disabled.
- 3
Copy the data URI
Encode the file and copy or download the complete single-line result.
Frequently asked questions
What is the data URI format?+
The result uses data:[media-type];base64,[data], for example a data:image/png;base64 prefix followed by Base64 text.
Is my image uploaded?+
No. This tool performs the encoding locally in your browser.
Related image tools
SVG to Base64
Encode original SVG source bytes as Base64
PNG to Base64
Encode original PNG file bytes as Base64
LQIP Generator
Create a tiny JPEG data URI for a CSS-blurred placeholder
JPG to Base64
Encode original JPEG file bytes as Base64
WebP to Base64
Encode original WebP file bytes as Base64
GIF to Base64
Encode original GIF file bytes as Base64