Base64 image encoder online - base64 converter
Image to Base64
This online utility is a converter between binary image data (gif, jpg, png .. file) and a base64 string. You can write output base64 string representation of the image directly to a html code or a css stylesheet, so the browser does not need to extra request server URL of the image and you can speed up your pages using the image-to-base64 code.
Sample Image-to-64 html code
Next sample html tag contains such image sample written directly to html as a base64 data. The tag represents one pixel transparent GIF with 42Byte size:
alt="One pixel transparent GIF"
As you can see, the whole 42Bytes one pixel GIF in Base64 representation above has a similar size as a plain URL for such image stored on server.
Http get & response headers are usually about 1kB, base64 encoding has +33% bigger output than the original binary image, so you can use such HTML tag for small single files with size up to 3kB to speed up your html pages. For example, if you take a single 1kB image as a base64, you will save up to 600B transfer data and one request/response time. The image-to-base64 code is great speed up for example on gradient web images.
If you want to decode image in Base64 format please use Base64 decoder.
Privacy notes for this online converter
* We do not store any data posted to this form.
* We do not log nor monitor the data.
* The encoded and dectypted data are stored only memory and converted on-the-fly using ASP or ASP.Net code.
Source code of the Base64 image encoder