Quick answer: A NimbusCalc base64 encoder rewrites arbitrary bytes as a string of 64 printable ASCII characters, and its matching decoder reverses the process byte for byte. Open the tool, choose tab 1. Text to Base64, type into Plain text, set the Alphabet, Padding and Line width selects, and read the ENCODED OUTPUT panel. The base64 encoder maps every three input bytes to four output characters, so the result is about 33.3 percent larger: Hello, world! becomes SGVsbG8sIHdvcmxkIQ==. Base64 is standardised in RFC 4648. It is an encoding, not encryption. There is no key, and anyone can reverse it. All work happens locally in your browser, with no upload, no signup and no stored data.

I keep a notebook for encodings because Base64 has no idea what a letter is. Last week I pasted a cafe with an accented e and wondered why the output grew. The answer was in the byte count. These notes follow the four tabs in page order.

What a base64 encoder does to three bytes at a time

A byte carries eight bits. A Base64 character carries six, because two to the power of six equals 64. A base64 encoder therefore takes input bytes in groups of three, treats each group as one 24-bit value, and slices that value into four 6-bit indices. Each index is looked up in a fixed alphabet. Uppercase A sits at index 0, uppercase Z at 25, lowercase a at 26, lowercase z at 51, the digit 0 at 52, the digit 9 at 61, plus at 62 and slash at 63. The equals sign is padding, not data.

Decoding reverses those shifts. The tool applies them to the UTF-8 representation of your input, as specified in RFC 3629.

The live quick-reference table is computed by the same encoder:

Input text UTF-8 bytes Standard Base64 Padding
(empty string) 0 (empty) 0
M 1 TQ== 2
Ma 2 TWE= 1
Man 3 TWFu 0
Hello 5 SGVsbG8= 1
Hello, world! 13 SGVsbG8sIHdvcmxkIQ== 2
cafe with e acute 5 Y2Fmw6k= 2
123 3 MTIz 0

Which alphabet, padding and line width options the base64 encoder exposes

Three selects sit above the encode output. They are the only knobs that change the characters. Four numbered tabs read 1. Text to Base64, 2. Base64 to Text, 3. Hex Converter and 4. Data URI Inspector. Buttons read Copy output, Load sample and Clear.

Control Options shown on the live page Effect
Alphabet (b6-enc-alpha) Standard Base64 (RFC 4648); Base64URL (URL and filename safe) Characters 62 and 63 become hyphen and underscore in the URL-safe variant.
Padding (b6-enc-pad) Keep equals sign padding; Omit padding Removes or keeps the trailing equals signs.
Line width (b6-enc-wrap) No line breaks; 76 characters (MIME); 64 characters (PEM style) Inserts newlines. RFC 2045 MIME uses 76; PEM certificate blocks use 64.

Decode offers Alphabet (Auto detect, Standard Base64, Base64URL) and Show output as (UTF-8 text, Hexadecimal bytes). The Hex Converter adds Direction (Hex to Base64, Base64 to Hex). Auto detect switches alphabets when it sees a hyphen or underscore.

How to encode UTF-8 text in the base64 encoder, tab by tab

Base64 encoder workflow from UTF-8 input bytes through 24-bit triples and four 6-bit indices to the RFC 4648 alphabet and padded output

The ENCODED OUTPUT line reports character, byte and overhead counts, alphabet, padding and line width. The default reads Characters: 13, UTF-8 bytes: 13, Base64 characters: 20, Overhead: 53.8 percent, Alphabet: Standard Base64, Padding: on, Line width: none.

  1. Select 1. Text to Base64. Type or paste into the Plain text textarea. The default value is Hello, world! and the placeholder reads Type or paste text here.
  2. Choose the Alphabet. Keep Standard Base64 (RFC 4648) for email, JSON or XML. Choose Base64URL (URL and filename safe) for query parameters, JWT segments, cookies and file names.
  3. Set Padding and Line width. Keep equals sign padding unless the receiving protocol forbids it. Pick No line breaks for config values, 76 characters (MIME) for email, or 64 characters (PEM style) for certificate blocks.
  4. Read ENCODED OUTPUT and press Copy output. For 13 bytes you get 20 characters. Paste it into tab 2. Base64 to Text to confirm the round trip returns the original bytes.

How to decode, convert hex and inspect a data URI

Reference table of Base64 padding rules for one two and three remaining bytes plus size overhead and standard versus Base64URL alphabets

Tab 2. Base64 to Text holds a Base64 string textarea with placeholder Paste Base64 here. Paste the value, set Alphabet to Auto detect, and choose UTF-8 text or Hexadecimal bytes under Show output as. If the bytes are not valid UTF-8, switch to the hex view. Strict validation rejects overlong sequences, stray continuation bytes, surrogate code points and values above U+10FFFF instead of inserting replacement characters. Whitespace is ignored, so 76-character MIME wrapping decodes cleanly.

Tab 3. Hex Converter accepts 4d616e and returns TWFu, because 4D 61 6E are the ASCII letters M, a, n. Tab 4. Data URI Inspector reads data:text/plain;base64,SGVsbG8= and reports the declared MIME type, size and file signature under RFC 2397.

Why Base64 is not encryption and what the 33.3 percent overhead costs

Three bytes become four characters, so the expansion factor is exactly 4/3. For n input bytes the padded length is four times the ceiling of n divided by three. A 10 MB file becomes roughly 13.3 MB of text. Base64 is fully reversible without a key, so it offers zero confidentiality. Basic authentication headers and JSON Web Token segments use it for transport safety, not secrecy. To see the same value in another radix, the number base converter shows binary, octal, decimal and hex side by side.

Base64 encoder mistakes that break the round trip

  • Treating output as a secret. Anyone can decode it. Never use Base64 to protect a password or token.
  • Skipping the UTF-8 step. Encoding a JavaScript string directly corrupts any non-ASCII character. A single emoji occupies four bytes.
  • Mixing alphabets. A plus or slash in a URL-safe context, or a hyphen in a standard context, produces an invalid-character error.
  • Removing padding incorrectly. Unpadded output is legal in many protocols, but the length must never be one more than a multiple of four.

Where this fits in a NimbusCalc workflow

Encoded fields usually land inside JSON, so the JSON formatter and validator is the natural next stop, and the guide to using a JSON formatter covers that step in detail. Before encoding, a regex tester and validator strips stray whitespace; the regex tester guide explains the flags that control it. Two guides from this batch use the same verification habit: the text diff checker guide compares two encoded strings token by token, and the IBAN validator guide proves a string is internally consistent with a checksum.

Base64 encoder questions, answered

Q. What is Base64 encoding used for? A. It converts binary bytes into 64 printable ASCII characters so data travels safely through text-only systems such as email headers, JSON documents and HTML attributes.

Q. Is Base64 encryption? A. No. It is a reversible encoding with no key, so it provides no confidentiality and must never protect passwords or secrets.

Q. Why does the equals sign appear at the end? A. It is padding. One equals sign means the final group held two bytes; two equals signs mean it held one byte.

Q. What is the difference between standard Base64 and Base64URL? A. Base64URL replaces plus with hyphen and slash with underscore and usually omits padding, so the result is safe inside URLs, cookies and file names.

Q. Is my data uploaded when I use this tool? A. No. All encoding and decoding runs locally in your browser with JavaScript, and nothing is sent to a server, stored or logged.