🔤 Base64 Encoder
Turn text, images or any file into Base64 you can paste into JSON, CSS or HTML.
🔒 Runs in your browser · files never uploaded
Drop a file here or click to browse Any file → Base64 (with a ready-to-use data: URI). Files stay on your device.
0Input chars
0Output chars
0 BBinary size
How to use the Base64 Encoder tool
- Type text or drop a file.
- Tick URL-safe or line wrapping if your target needs it.
- Copy the Base64 or download it as .txt.
Frequently asked questions
How do I embed an image in CSS or HTML with Base64?
Drop the image and copy the data URI shown in the input box (data:image/png;base64,…). Use it as src="…" or url("…"). Keep it for small icons – large images bloat your CSS.
Should I wrap Base64 at 76 characters?
Only for MIME email bodies and PEM files, which expect line breaks. JSON, URLs and data URIs need one unbroken line.
Does it handle non-English text?
Yes. Text is converted to UTF-8 bytes before encoding, so Hindi, Chinese, Arabic and emoji all encode correctly.