Home / Base64 Tools / Binary to Base64 Converter
Base64 Tools

Binary to Base64 Converter

Convert byte-aligned binary bits or local file bytes to Base64 with exact byte-boundary diagnostics, Standard/Base64URL output, padding and line-wrap controls, SHA-256, 24-bit sextet evidence, batch conversion and byte-for-byte round-trip verification.

Binary → Base64 Byte & Sextet Studio

Trace the conversion from source bits to bytes, 24-bit Base64 groups, sextets and output characters. Files stay local; text bitstreams can be saved only when you explicitly choose to save them.

Browser-local · RFC 4648 evidence
Strict byte diagnosticsStandard + Base64URLPadding control24-bit / sextet proofSHA-256 + round tripBatch + exports

1. Enter binary bits

Whitespace and separators _ : , . - are ignored; every other character is diagnosed by exact raw position.

—source bytes
—normalized bits
—Base64 chars
—canonical pad chars
—encoded-size overhead
Ready.

3. Base64 output

Exact round trip

—

4. Same bytes, other representations

5. SHA-256 & audit handoff

—

6. Explicit repeat-use projects

Nothing is auto-saved. “Save locally” stores the current text bitstream only in this browser, up to eight projects. Local file bytes are never stored.

#ProjectSizeAction

7. Byte inspector

OffsetHex8-bit bytesASCII

—

8. 24-bit → 6-bit Base64 proof

Base64 consumes three bytes (24 bits) at a time, splits them into four 6-bit indices, and maps those indices to alphabet characters. The final group shows = only when fewer than three source bytes remain.

Byte offsetBytesSource bits6-bit groupsBase64 chars

—

9. Batch bitstreams

One bitstream per non-empty line. Uses the current alphabet, padding and incomplete-byte policy. Batch output is intentionally unwrapped so each source stays on one result row. Up to 500 rows / 512 KB.

No batch run yet.

10. Privacy, limits & truth boundary

  • All conversion runs in this browser. This Studio performs no remote URL fetch.
  • Base64 is an encoding, not encryption; anyone with the value can decode it.
  • Strict text mode requires complete 8-bit bytes. Optional left/right zero-padding is a deliberate data transformation, not Base64 padding.
  • Base64URL changes the +// alphabet to -/_. Omitting trailing = is a separate setting.
  • 76-character wrapping is MIME-style line wrapping only; it does not construct MIME headers or an email entity.
  • The byte inspector shows at most 256 bytes and the sextet table 64 groups; hashing, conversion and downloads still use the entire accepted payload.
  • File mode is limited to 20 MB here to reduce browser-freeze risk. This is a product safety boundary, not a Base64 format limit.

How binary bits become Base64

Base64 encodes bytes, not an abstract stream of unbounded bits. First establish 8-bit byte boundaries, then Base64 takes three bytes (24 bits) at a time, divides those bits into four 6-bit values, and maps each value to one character in the 64-character alphabet.

Byte alignment comes before Base64 padding

If a binary text string contains 13 bits, the missing three bits are part of the source-byte interpretation problem. That is different from Base64 = padding, which is added only after the byte sequence is known. This Studio therefore rejects incomplete bytes by default and records any explicit zero-padding transformation separately.

Standard Base64 vs Base64URL

Standard RFC 4648 Base64 uses + and /. Base64URL uses - and _ so the encoded value is easier to place in URLs and filenames. URL-safe output often omits =, but alphabet choice and padding choice are separate decisions.

Why encoded data grows

Every three source bytes become four Base64 characters. For large inputs that is roughly 33% size growth before line breaks or a Data URI prefix. Small inputs can have a larger percentage overhead because the final group still occupies two to four Base64 characters.

File bytes and bit text are not the same input

A file containing the characters 01000001 has eight ASCII bytes unless you explicitly interpret those characters as a textual bitstream. File mode encodes the raw file bytes; bitstream mode interprets 0 and 1 as bit values. Keeping those modes separate prevents a common conversion mistake.

Can I paste spaces between bytes?

Yes. Whitespace and common visual separators are ignored. Invalid characters are reported by their raw input position.

What does the sextet table prove?

It exposes each 24-bit group, its four 6-bit chunks and the exact Base64 characters they select, making the algorithm auditable rather than a black box.

Can I use URL-safe Base64?

Yes. Switch the alphabet to Base64URL and independently choose whether trailing = padding is kept.

Does the tool upload files?

No. Local file bytes are read by browser APIs and converted on-device. There is intentionally no remote URL-fetch mode on this focused page.

Is Base64 secure?

No. Base64 is reversible encoding and provides no secrecy. Use appropriate cryptography when confidentiality or integrity is required.

Why show SHA-256?

The digest is calculated over the raw source bytes so you can compare the exact payload across representations. It is evidence of byte identity, not encryption of the content.

Search by task, tool name, or category. Press Esc to close.
Start typing to find a tool.