Image Tools
Image to Base64
Convert images to Base64 data URIs in your browser. Drop PNG, JPG, GIF, WEBP, AVIF, or SVG and copy the data URI, raw Base64, CSS, or HTML snippet.
Output format
Full data:[mime];base64,[payload] string. Drop straight into src or url().
Output
Drop one or more images above to get the Base64 string, data URI, or ready-to-paste CSS and HTML snippet.
How to use
- Drop one or more image files onto the upload area, or click to pick them with the file picker.
- Pick an output format: Data URI, Raw Base64, CSS background, or HTML img tag.
- Read the file size, dimensions, and Base64 character count for each image.
- Click Copy on any row to copy the encoded output, or Remove to drop a single file.
About this tool
Image to Base64 turns image files into Base64 data URIs that can be inlined directly in HTML, CSS, JSON, SVG, or email templates. Drop PNG, JPG, GIF, WEBP, AVIF, BMP, SVG, or ICO files (or pick them with the file picker) and the tool reads each one in your browser, encodes it as Base64, and shows the file name, MIME type, dimensions, byte size, and resulting Base64 length. Switch between four output formats: a full data URI (data:[mime];base64,[payload]), the raw Base64 payload alone, a ready-to-paste CSS background-image declaration, or an HTML img tag with the data URI inlined. Files never leave your device, since FileReader runs entirely in the browser. Useful for embedding small icons or favicons inline, prototyping email templates, packing assets into a single CSS file, or working in environments where a remote image URL is not an option.
Free to use. Works in your browser. No signup, no login.
Related tools
You may also like
Base64 to Image
Decode a Base64 string or data URL into a previewable, downloadable image.
Open tool
DeveloperBase64 Encoder Decoder
Encode and decode Base64 with full Unicode.
Open tool
ConverterHEX to RGB Converter
Convert HEX, RGB, RGBA, and HSL with a live preview.
Open tool
DeveloperURL Encoder Decoder
Encode and decode percent-encoded URLs.
Open tool