Skip to the tool

Base64 Encode

Encode text or UTF-8 strings to Base64 instantly in your browser. Nothing is uploaded.

Base64 is a binary-to-text encoding scheme that represents binary data as ASCII text using 64 printable characters (A–Z, a–z, 0–9, +, /). It is not encryption—it only changes how data is represented, so anyone can decode it.

It is commonly used to embed small images or files directly in HTML, CSS, JSON, or email, and to safely transmit binary data over channels that only support text.

Padding at the end is always a multiple of four characters. If you see '=' or '==' at the tail, that is Base64 aligning the final group to the required block size.

Common uses

Frequently asked questions

Is Base64 encryption?
No. Base64 is encoding, not encryption. It is fully reversible by anyone, so never use it to hide passwords or secrets.
Why does Base64 increase size?
Base64 stores 3 bytes in 4 characters, so output is about 33% larger than the input. The padding '=' characters make the length a multiple of 4.
Can I decode Base64 in my browser?
Yes. All modern browsers support atob() and btoa(), and this tool runs entirely client-side using those same primitives.
Can I encode a file?
Yes, but this page is for text. For files use the FileReader API to get a data URL, then strip the 'data:' prefix.

Related tools