Base64 Encoder & Decoder

Encode text, decode Base64 strings, and convert files to data URIs — all in your browser.

100% Client-side
Plain Text
Base64

What is Base64?

Base64 is a binary-to-text encoding scheme that represents binary data using 64 printable ASCII characters: A–Z, a–z, 0–9, +, and /. The output is padded with = to make its length a multiple of four.

Base64 is commonly used to encode binary data so it can be safely transmitted in text-based protocols like HTTP headers, email (MIME), and JSON. It increases the data size by approximately 33% compared to the raw binary.

Common Use Cases

JWT Tokens

JSON Web Tokens use URL-safe Base64 to encode the header, payload, and signature segments.

Images in CSS/HTML

Small images and icons can be embedded directly as data URIs to eliminate HTTP requests.

Email Attachments

The MIME standard uses Base64 to encode binary file attachments in email messages.

Frequently Asked Questions

Disclaimer: This tool runs entirely in your browser. No data is sent to any server. Base64 encoding is not encryption — do not use it to secure sensitive data. The file encoding feature uses the FileReader API and does not upload files anywhere.