PDFSnap › Image to Base64
Convert an image to Base64, free
Get a Base64 data string for an image so you can embed it directly in HTML, CSS or JSON.
Need several steps at once? Just type what you want →How to use Image to Base64
- Add an imageSelect the picture.
- ConvertThe Base64 string is generated in your browser.
- Copy and use itPaste it into your code where you need it.
Why use PDFSnap
- Handy for small icons in HTML or CSS.
- Nothing leaves your device.
- Private by design: your files are processed in your browser and are not uploaded to a server.
- Free, with no signup and no watermark on the result.
Frequently asked questions
When should I use Base64 images?
For small icons and graphics. Base64 makes the data about a third larger, so avoid it for big photos.
How do I use the string in HTML?
Use it as the source of an image: src="data:image/png;base64,...", adjusting the type to match your file.
Is Image to Base64 really free?
Yes. There is no signup, no watermark and no paid plan. The site is supported by ads.
Is my data sent to a server?
No. Your file is processed by code running in your browser. The page only downloads the open-source libraries it needs (for OCR, also the language data), never your file.