Base64 Encoder/Decoder

Encode text to Base64 or decode Base64 strings. All processing happens locally in your browser.

Input
Press Ctrl+Enter to encode
0 characters
Output
0 characters
What is Base64?

Base64 is a binary-to-text encoding scheme that represents binary data in an ASCII string format. It uses 64 characters (A-Z, a-z, 0-9, +, /) to represent data, making it safe for transmission over text-based protocols.

Common Uses:
Data URIs

Embedding images directly in HTML/CSS without external files.

HTTP Basic Auth

Encoding username:password credentials for authentication headers.

Email Attachments

MIME encoding for sending binary files via email (SMTP).

URL-Safe Base64:

Standard Base64 uses '+' and '/' which have special meanings in URLs. URL-safe Base64 replaces these with '-' and '_' respectively, eliminating the need for URL encoding.

Frequently Asked Questions

No! Base64 is an encoding, not encryption. It's easily reversible and provides no security. Anyone can decode Base64 data. Never use Base64 alone to protect sensitive information.

Base64 encoding increases data size by approximately 33%. This is because it converts every 3 bytes of binary data into 4 ASCII characters. This overhead is the trade-off for being able to transmit binary data as text.

Use URL-safe Base64 when the encoded data will be:
  • Part of a URL query parameter
  • Used in file names
  • Stored in JSON (to avoid escaping issues)
  • Used in JWT tokens