Base64 Encoder / Decoder

This page provides a tool for encoding text to Base64 and decoding Base64-encoded strings back to their original text. Enter your string in the input field above and click the buttons to see the transformation results.

Input

Output

Base64 Encoding

Base64 encoding is a method of converting binary data into a text format to maintain data integrity while transmitting. Base64 encoding uses 64 characters (A-Z, a-z, 0-9, +, /) to encode binary data into text.

1. Input data is first divided into 8-bit bytes.

2. These bytes are then grouped into 6-bit blocks. Each 6-bit block is converted to a character in the Base64 character set.

3. The resulting Base64 string is padded with '=' characters if necessary to make the length a multiple of 4.

Base64 Decoding

Base64 decoding is the process of converting a Base64-encoded string back into its original binary data to restore the original information.

1. Remove '=' characters from the end of the Base64 string.

2. Convert each Base64 character to its corresponding 6-bit value.

3. Reconstruct the 8-bit bytes from these 6-bit values to restore the original binary data.

How to Use

1. Text Input: Enter the string you want to encode in Base64 or the Base64 string you want to decode in the text input area.

2. Encode / Decode: Click the 'Encode to Base64' / 'Decode to String' button to encode the string into Base64 or decode the Base64 string.

3. Check Results: The converted result will be displayed in the output area.

4. Copy Result: Click the copy button next to the output area to copy the result to your clipboard.

Security

All text entered and information related to encoding / decoding are not stored on the server.

Free to Use

This tool is provided completely free of charge. There is no need to download additional software; it can be used directly from the web.

Encoding Example

For example, the string 'Hello World' is converted to an ASCII byte sequence and then encoded in Base64, resulting in: SGVsbG8gV29ybGQ=.