Optimize your images and convert them to base64 online. Drag & Drop your files, copy to clipboard with a click and use the result in HTML and CSS.
What Is Base64
In programming, Base64 is a group of binary-to-text encoding schemes that represent binary data (more specifically, a sequence of 8-bit bytes) in an ASCII string format by translating the data into a radix-64 representation. The term Base64 originates from a specific MIME content transfer encoding. Each non-final Base64 digit represents exactly 6 bits of data. Three 8-bit bytes (i.e., a total of 24 bits) can therefore be represented by four 6-bit Base64 digits.
Common to all binary-to-text encoding schemes, Base64 is designed to carry data stored in binary formats across channels that only reliably support text content. Base64 is particularly prevalent on the World Wide Web where its uses include the ability to embed image files or other binary assets inside textual assets such as HTML and CSS files.
Why Use base64 Images
Every image is one request to the server if we can embed images as code to HTML or CSS documents we can have fewer requests and our site will work faster. This is just a good practice for smaller images that will NOT be reused on other parts of the website. It’s ridiculous to embed the same image as code to more than one page as it’s 99% ridiculous to convert images larger than 200KB to base64.
Go and use this free online base64 tool website is base64-image.de