Encode text or data to Base64 and decode Base64 strings back to readable text. A fast developer utility for API payloads, tokens and data URIs.
Dropping a small icon straight into a stylesheet, stuffing a certificate into an environment variable, or moving a binary blob through a JSON field all need the same trick: express arbitrary bytes using 64 printable characters. The Base64 Encoder and Decoder does that conversion both ways with a single toggle between them.
Text goes through a UTF-8 encoder before the encoding runs, and the bytes come back through a UTF-8 decoder afterwards. That ordering is what lets a Japanese product name or a Polish surname survive the round trip, where the older technique of treating each character as a byte would corrupt anything above the Latin-1 range.
Decoding strips all whitespace before parsing, so a certificate copied with its line breaks intact needs no cleanup first. Failures are reported rather than guessed at, and no request is made in either direction.
Paste {"env":"staging","retries":3}into Plain Text Input. The Base64 Output pane returns eyJlbnYiOiJzdGFnaW5nIiwicmV0cmllcyI6M30=, which is safe to assign in a shell or a deployment manifest without worrying about quoting the braces and the colon. The single trailing =marks the last group as holding 2 bytes rather than 3: the source is 29 bytes long, and 29 leaves a remainder of 2 when divided by 3.
+ and / as its last 2 characters. The URL-safe variant defined by RFC 4648 swaps them for - and _, and a string in that form will not decode here until you substitute them back.= characters were stripped, which some APIs do deliberately, returns Invalid Base64 string. Make sure the input is valid Base64. Restoring the padding to a multiple of 4 characters fixes it.-----BEGIN and -----END lines are not whitespace and must go first.Encoding failed. message is effectively unreachable. If you see it, the input contains an unpaired surrogate, which usually means a broken copy and paste of an emoji.