Base64 Encode / Decode
Encode text to Base64 or decode Base64 to text. Supports file upload, image preview, URL-safe mode, and batch processing.
Drop a file here or click to browse
Any file type -- encodes to Base64
Related Tools
How to Base64 Encode and Decode Online
Base64 encoding converts binary data into ASCII text, which is essential when you need to embed binary content in text-based formats — JSON payloads, data URIs, email attachments (MIME), or HTTP headers. This Base64 converter handles both encoding and decoding in your browser, with no server round-trip.
Common use cases include decoding Base64-encoded secrets from Kubernetes manifests or environment variables, encoding images for inline CSS (data:image/png;base64,...), and inspecting Base64 content in JWTs or API responses. Paste in encoded text to decode it, or paste plain text to encode it.
The tool uses the browser's native btoa() and atob() functions, which implement standard Base64 (RFC 4648). For URL-safe Base64 (used in JWTs and some APIs), the + and / characters are replaced with - and _. Your data stays in your browser — important when you're decoding tokens or credentials.
Tips
- Base64 is encoding, not encryption — anyone can decode it. Never treat Base64-encoded secrets as secure.
- Base64 increases data size by roughly 33%. Consider this when embedding large files as data URIs.
- If decoding produces garbled text, the original data might be binary (like an image) rather than text.
- For CLI:
echo -n "text" | base64to encode,echo "dGV4dA==" | base64 -dto decode.