Base64 Encoder/Decoder
encode · decode · file support
$ how-to-use
Paste text or data in the input field. Click Encode to convert to Base64, or paste a Base64 string and click Decode to get the original text back.
What is Base64?
Base64 is a binary-to-text encoding that represents binary data using 64 ASCII characters (A-Z, a-z, 0-9, +, /). It's used whenever binary data needs to be transmitted through text-based systems like JSON, XML, email, or URLs.
Common uses include encoding API authentication tokens (HTTP Basic Auth sends credentials as Base64), embedding small images in CSS/HTML as data URIs, and transmitting binary file contents in JSON payloads.
The encoding increases size by approximately 33% — every 3 bytes of input becomes 4 bytes of Base64 output. This overhead is the trade-off for guaranteed safe transmission through text-only channels.
Common Use Cases
API Auth Headers
HTTP Basic Authentication encodes username:password as Base64 in the Authorization header.
JWT Tokens
JSON Web Tokens use Base64URL encoding for the header and payload sections. Decode them here to inspect claims.
Data URIs
Embed small files directly in HTML/CSS using data:text/plain;base64,... format. Eliminates extra HTTP requests.
Email Attachments
MIME email encoding uses Base64 for binary attachments sent through text-only SMTP protocols.
FAQ
Is Base64 encryption?
No. Base64 is encoding, not encryption. Anyone can decode it instantly. Never use Base64 to "hide" sensitive data — use proper encryption instead.
Is my data private?
Yes. All encoding/decoding runs in your browser. Nothing is sent to any server.