Image to Base64
Turn an image into a Base64 data URI, <img> tag or CSS rule.
Runs on your device. Files are never uploaded.How to use Image to Base64
- Add an image
- Choose the output style
- Download the text file and copy the code
About this tool
Embed small icons directly in HTML, CSS or emails without a separate file. Choose a data URI, plain Base64, a ready <img> tag or a CSS background rule. Processed locally.
Like every tool on YantraStack, it is free with no accounts, limits or watermarks, and it works offline once the page has loaded. See how to verify that nothing is uploaded.
Questions
Should I embed large images?
Usually not. Base64 is about 33% bigger than the file and cannot be cached separately. It suits small icons.