About Base64 Decoder
Something handed you a block of letters, digits, plus signs and slashes: a value from a config file, the body of an email, a section of a token. Paste it here to see the text behind it. Line breaks and spaces are skipped, the - and _ of the URL-safe alphabet are understood, and a string that lost its trailing = signs still decodes.
When the result is not text at all, you get the raw bytes in hexadecimal and a note saying so, which is usually the sign that the string stands for a file or a key.
How it works
- To encode, your text is first turned into UTF-8 bytes, then every three bytes become four characters from the Base64 alphabet.
- To decode, whitespace is ignored, URL-safe characters are mapped back to the standard alphabet and padding is restored before the bytes are read as UTF-8 text.
- The swap button moves the result into the input and flips the direction, which makes round-trip checks quick.
Questions
Why does it say my string is not valid Base64?
It contains a character outside the alphabet, has = signs somewhere other than the end, or is one character short of a length any encoder could produce. The message names which, so check for text copied along with the string by accident.
Can it decode a string that has been wrapped over several lines?
Yes. Spaces, tabs and line breaks are removed before decoding, so the 64 or 76 character lines found in certificates and email source can be pasted as they are.
Can I turn text into Base64 here as well?
Yes. Switch Direction to Encode, or use the swap button to send the decoded result back the other way. This page simply opens with decoding selected.
Everything you enter here is processed in this browser tab. Nothing is uploaded, logged or shared. How privacy works here.