Base64 Encoder/Decoder

Encode and decode Base64 strings quickly and easily.

Free
3 total uses
Loading... uses today
We track which tools are used (not your inputs) to improve our service. Your IP address is anonymized for privacy.

Encoded Result

0 characters

Encode File to Base64

Click to select a file to encode

About Base64 Encoding

Base64 is a binary-to-text encoding scheme that represents binary data in ASCII string format. It's commonly used to encode data that needs to be stored or transferred over media designed to handle text.

Common Uses:

  • Embedding images in HTML or CSS (Data URLs)
  • Encoding binary data in JSON or XML
  • Email attachments (MIME)
  • Storing complex data in databases or configuration files
  • API authentication (Basic Auth)
  • Encoding files for transmission

How It Works:

Base64 encoding converts binary data into a set of 64 characters (A-Z, a-z, 0-9, +, /). Every 3 bytes of data is converted to 4 Base64 characters, making the output approximately 33% larger than the input.

URL-Safe Encoding:

Standard Base64 uses + and / characters which have special meaning in URLs. URL-safe Base64 replaces these with - and _ respectively, making it safe to use in URLs and filenames.

Example:

Original Text:

Hello World!

Base64 Encoded:

SGVsbG8gV29ybGQh

Important Notes:

  • Base64 is encoding, not encryption - it doesn't provide security
  • Anyone can decode Base64 data
  • Use encryption if you need to secure data
  • The output is always larger than the input (approximately 33% larger)