Home / Developer tools / Base64 to text

Base64 to Text Converter

Decode Base64 into readable text and choose the charset used when the data was encoded. Switch the view to see the same bytes as hex, binary or decimal numbers.

Try:

Everything runs in your browser. Your data is not sent to our server.

Decoding Base64 to text correctly

Base64 only carries bytes. To turn the bytes into text, you must know which charset was used when the text was encoded. Most of the time it is UTF-8, and the tool tries that first. If the bytes are not valid UTF-8 you get a warning, and you can choose another charset:

CharsetWhen to use it
UTF-8The default for the web, JSON, APIs, files created on Linux and macOS.
UTF-16 (little endian)Windows APIs, PowerShell -EncodedCommand, some .NET and Java data. You can recognise it by zero bytes between letters.
Latin-1 (ISO-8859-1)Old Western European systems and databases. One byte per character.
ASCIIPlain English text. Bytes above 127 are flagged.

Why text looks wrong: mojibake

If café appears as café, UTF-8 bytes were read as Latin-1. If you see caf followed by a replacement character (a black diamond with a question mark), Latin-1 bytes were read as UTF-8. If you see letters separated by blank symbols, the data is UTF-16. Change the charset until the text is right.

Views of the same bytes

  • Text: the characters, using the chosen charset.
  • Hex: every byte as two hex digits, such as 48 65 6C 6C 6F.
  • Binary: every byte as 8 bits, such as 01001000.
  • Decimal: every byte as a number from 0 to 255.

A hex dump of the first 256 bytes is always shown under the result, with offsets and an ASCII column. It is the quickest way to see whether the data is text, a file header (for example 89 50 4E 47 for PNG) or something else.

Example

Y2Fmw6k=

decodes with UTF-8 to café (bytes 63 61 66 C3 A9), but with Latin-1 to café.

Input rules

The same as in the Base64 decoder: spaces and line breaks are ignored, padding may be missing, the URL-safe alphabet is accepted and a data: prefix is removed. Tick Ignore invalid characters to skip anything else.

If the data is a file and not text, use the Base64 decoder to download it, or Base64 to image to see a picture. See also text to Base64 and What is Base64?

Frequently asked questions

How do I convert Base64 to text?

Paste the Base64. The text is shown at once, decoded as UTF-8. Choose another charset if it looks wrong.

Why do I see strange characters like é?

UTF-8 bytes were shown with a Latin-1 reading, or the other way round. Choose the charset that matches how the text was written.

What does a replacement character mean?

The bytes are not valid in the chosen charset. The data may be binary, or in another charset.

Can I see the bytes?

Yes. Switch the view to hex, binary or decimal, and check the hex dump below the result.