Base64 Encoding/Decoding

How to use Base64 encoding/decoding?

  1. Enter your original text or Base64 code.
  2. Click the 'Encrypt' button to encode, or click the 'Decrypt' button to decode.
  3. Click the 'Copy' button to paste it into your clipboard.
  4. Click here to convert an image to Base64.

What is Base64 encoding/decoding?

  1. The online Base64 encoding/decoding tool is a utility that can encode/decode strings into Base64 format. It uses JavaScript for simplicity and speed.
  2. Base64 encoding converts three 8-bit bytes (3*8=24 bits) into four 6-bit bytes (4*6=24 bits), then prepends two zeros to each 6-bit byte to form an 8-bit byte. If the remaining characters are insufficient to form three bytes, they are padded with zeros, and the output characters become '='. Therefore, the encoded text may end with one or two '=' characters.
  3. To ensure readability of the output code, Base64 defines a standard character set for uniform conversion. This character set contains 2^6 = 64 characters, which is the origin of the name "Base64".
  4. This tool can be used to encrypt or decrypt Base64-formatted code. Base64 is one of the most commonly used encoding methods for transmitting 8-bit byte data on the Internet.

Base64 Encoding Table

The 64 printable characters include uppercase letters A-Z, lowercase letters a-z, digits 0-9 (totaling 62 characters), plus two additional characters: + and /.

 000001010011100101110111
000ABCDEFGH
001IJKLMNOP
010QRSTUVWX
011YZabcdef
100ghijklmn
101opqrstuv
110wxyz0123
111456789+/