01→64 Encoding Utility

Binary to Base64 Converter

Convert binary bytes to Base64 online. Enter 8-bit binary data, a continuous binary byte stream, or separated byte groups and encode the exact byte sequence into standard Base64 with decimal, hexadecimal and byte-level details.

✓ Binary to Base64 ✓ 8-bit Bytes ✓ Continuous Binary ✓ Base64 Padding ✓ Hex Breakdown ✓ Copy Result
B64
Binary Base64 Encoding
● Ready
Enter complete 8-bit bytes. Spaces, commas, colons, hyphens, underscores and line breaks are accepted as separators.
Input Options
Base64 process: binary input is first interpreted as actual 8-bit bytes. Base64 then groups those bytes into 24-bit blocks and converts them into 6-bit Base64 indexes.
Binary to Base64 Result Encoded
Base64 Output
Input Bytes
Input Bits
Base64 Length
Padding
Decimal Bytes
Hex Bytes
Output Type
Status
Base64 Encoding Breakdown
Validation & Conversion Details

Binary to Base64 Converter

The Binary to Base64 Converter transforms binary byte data into a Base64 string. Instead of interpreting the binary as readable text first, this tool works directly with the byte values represented by the input bits. This makes it useful for encoding arbitrary binary data as well as binary representations of text.

Base64 is frequently used when binary data must be transported through systems that are designed primarily for text. Common examples include web APIs, JSON, XML, MIME email, data URLs, authentication tokens and software configuration formats.

How to Convert Binary to Base64

Enter your binary bytes in groups of eight bits. You can separate the bytes with spaces, commas, colons, hyphens or line breaks. A continuous binary string is also accepted when its length is a multiple of eight.

Click Convert Binary to Base64. The calculator converts each 8-bit group into a byte and feeds the complete byte sequence into the Base64 encoding process.

Binary: 01001000 01100101 01101100 01101100 01101111 Hex bytes: 48 65 6C 6C 6F Bytes interpreted as: H e l l o Base64: SGVsbG8=

How Base64 Encoding Works

Base64 represents binary data using a set of 64 printable characters. Since 64 different values can be represented with six bits, the encoder reorganizes the original byte stream into groups of six bits.

3 input bytes = 24 bits 24 bits ÷ 6 bits = 4 Base64 values

This is why three bytes normally produce four Base64 characters.

Binary Bytes to Base64 Example

Consider the three ASCII-compatible bytes for the text ABC. The Base64 encoder does not need to know that those bytes represent letters; it encodes the byte values themselves.

Binary bytes: 01000001 01000010 01000011 Combined bits: 010000010100001001000011 Split into 6-bit groups: 010000 010100 001001 000011 Decimal indexes: 16 20 9 3 Base64: QUJD

Base64 Alphabet

Standard Base64 uses uppercase letters, lowercase letters, digits and two additional symbols. Each character corresponds to a six-bit value from 0 through 63.

Index Range Base64 Characters
0–25 A–Z
26–51 a–z
52–61 0–9
62 +
63 /

What Is Base64 Padding?

Base64 operates most naturally on groups of three input bytes. If the final block contains only one or two bytes, padding is used in standard Base64 so the encoded output remains aligned to groups of four characters.

1 input byte: M Base64: TQ== Padding: 2 characters 2 input bytes: Ma Base64: TWE= Padding: 1 character 3 input bytes: Man Base64: TWFu Padding: None

Standard Base64 vs Base64URL

Standard Base64 uses the characters + and /. Base64URL is designed for URLs and filename-safe contexts, so those two characters are replaced with a hyphen and underscore.

Value Standard Base64 Base64URL
62+
63/_

This calculator can generate either standard Base64 or Base64URL. For Base64URL output, trailing equals-sign padding is removed.

Binary to Base64 Is a Byte Conversion

A common mistake is to treat the visible characters 0 and 1 as text and then Base64-encode those characters. That produces a completely different result. This tool interprets the bits as binary byte values first.

Binary byte: 01000001 Actual byte value: 65 Character representation: A Correct Base64 of byte 65: QQ==

Encoding the literal text “01000001” would instead encode eight ASCII characters and produce a different Base64 string.

Continuous Binary to Base64

You can remove the spaces between input bytes as long as the overall bit count is divisible by eight. The decoder automatically separates the stream into bytes before Base64 encoding.

With spaces: 01000001 01000010 01000011 Continuous: 010000010100001001000011 Both encode to: QUJD

Why Convert Binary to Base64?

Raw binary data cannot always be inserted safely into text-oriented formats. Some byte values may correspond to control characters, null bytes or other values that are difficult to transport or display. Base64 replaces the raw bytes with printable characters while preserving the original byte sequence.

When decoded correctly, the resulting Base64 data reconstructs the same original binary bytes.

Binary to Base64 Converter FAQs

How do I convert binary to Base64?
Enter binary data as 8-bit bytes and click Convert Binary to Base64. The tool converts the bits to bytes and then Base64-encodes those exact byte values.
What is 01000001 in Base64?
01000001 is decimal byte 65, which is ASCII A. A single byte with value 65 encodes to QQ== in standard Base64.
What is Hello in binary converted to Base64?
The UTF-8/ASCII binary bytes for Hello are 01001000 01100101 01101100 01101100 01101111. These bytes encode to SGVsbG8=.
Can I paste continuous binary without spaces?
Yes, provided the total number of bits is a multiple of eight.
Why does Base64 use equals signs?
Equals signs are padding characters used when the final input block does not contain a full three bytes.
Does Base64 compress binary data?
No. Base64 is an encoding, not compression. The Base64 representation is normally larger than the original byte sequence.
Is Base64 encryption?
No. Base64 does not provide secrecy or security. Anyone can decode Base64 back to the original bytes.
What is Base64URL?
Base64URL is a URL-safe variation of Base64 that replaces + with – and / with _. Padding is commonly omitted.
Can arbitrary binary data be converted to Base64?
Yes. Base64 operates on bytes, so the original data does not need to represent readable text.
Can Base64 be converted back to the original binary?
Yes. Base64 decoding reconstructs the original byte sequence, which can then be displayed again as eight-bit binary values.
Scroll to Top