Image to Base64
Choose or drop an image and get its Base64 as plain text, Data URI, CSS, HTML or JSON. Everything happens in your browser.
Image file
Nothing is stored or sent to any server.
Choose or drop an image and get its Base64 as plain text, Data URI, CSS, HTML or JSON. Everything happens in your browser.
Nothing is stored or sent to any server.
The Image to Base64 tool turns an image file into a text string that you can embed directly in your code. Pick a file or drop it on the upload area and you will see a preview together with its name, type, dimensions and size. The result comes in five formats: plain text, Data URI, a CSS rule with background-image, an HTML img tag and a JSON object. Switching format is instant and does not read the file again. It accepts PNG, JPEG, GIF, WebP, BMP, ICO, AVIF and SVG up to 10 MB. Everything happens in your browser and the image is never uploaded to a server.