Base64 Encoder/Decoder
Encode text to Base64 or decode Base64 to text
Input Text
Base64 Output
What is Base64?
Base64 is an encoding scheme that converts binary data into ASCII text. It’s commonly used to encode data in URLs, emails, and data URIs. Each Base64 character represents 6 bits of data.
Frequently Asked Questions
What is Base64 encoding used for?
Base64 converts binary or text data into an ASCII-safe string that can be embedded in emails, URLs, data URIs, and APIs without corruption from special character handling. It is commonly used for embedding images in CSS (data:image/png;base64,…), encoding email attachments, and transmitting JSON tokens such as JWTs.
How do I encode text to Base64?
Type or paste any text into the Input Text box and click Encode to Base64. The encoded result appears in the Output box. Each Base64 character represents 6 bits, so the output is roughly 33% longer than the original. The character count is shown for both input and output.
How do I decode a Base64 string?
Paste the Base64-encoded text into the Output box and click Decode from Base64. The original plain text appears in the Input box. If the string is invalid Base64 (wrong length or illegal characters), the decoder will show an error rather than produce garbled output.
Is Base64 the same as encryption?
No. Base64 is an encoding scheme, not encryption. Any Base64 string can be decoded instantly by anyone with a decoder. It does not hide data. Its purpose is to represent binary data as printable ASCII text for compatibility, not security. For encryption you need algorithms like AES, and for one-way hashing you need SHA-256 or similar.
What characters does Base64 use?
Standard Base64 uses 64 characters: A-Z (26), a-z (26), 0-9 (10), plus (+), and forward slash (/), with padding done by the equals sign (=). URL-safe Base64 replaces + with – and / with _ to avoid conflicts in URLs. The tool uses standard Base64 encoding by default.