Developer Toolkits Logo Developer Toolkits

Base64 Decode Text, Binary and Data URLs

Decode text or data URL images. Type or paste a Base64 ASCII string into the source text box or alternatively browse or drag and drop a file to Base64 decode online.

result image

About The Tool

The tool will convert a base64 string back to the original text or binary data. The decoding function is a JavaScript base64 decoder that does all decoding locally in the browser. Nothing is stored or transferred to the server.

The tool can also Base64 decode images from a data URL format. It will extract the image and display the result in the results box. A source file that contains Base64 text can be selected or dragged and dropped from the desktop and the contents will be loaded into the source box for decoding.

The tool was designed to be simple to use, safe and secure with 2048 bit SSL encryption, and completely free. If you find this tool or others that we provide helpful, please take a moment to share it with your friends and coworkers or follow us using the social links at the bottom of this page.

Decoding Text And Binary Data

The Base64 variant supported is the MIME content transfer encoding outline by RFC4648. A few other variants use different ASCII characters for the 62nd and 63rd in place of '+' and '/'. These variants are not supported. For more details on the inner workings of the Base64 encoding scheme see What Is Base64.

Upon successfully decoding of a source string, the results will be displayed in the results box. If the original data was binary, the results may not be readable text. When the results are saved to a file, the file will contain the original byte stream encoded by the source.

Decoding Images

The Base64 image decoder accepts data URLs from CSS or inline <img> tags from an HTML document following the RFC2397 specification. Please remove the <img> tag or the url() surrounding the data URL to ensure the tool can decode it correctly.

The data URL Format follows this pattern:


Here is an example data URL the tool will decode:


Common Uses Of Base64

In the early days of the Internet, ASCII was the standard encoding for text. It uses 7 bits to represent a character of text. It was able to represent the most common printable characters as well as a handful of control characters. A number of applications including SMTP base email systems were designed to work only with textual data. These systems are not "8 bit clean", in other words, characters that are not alphanumeric such as carriage returns and line feeds may get mangled. If these byte values are in an executable or image, then the resulting payload will have a different meaning downstream causing the image or executable to become corrupted. Base64 allows a system to represent binary data in an ASCII format, such as mail attachments, using only 64 characters without the risk of data corruption.

Today many more scenarios need to encode binary data use Base64. A few examples include:

Hashes and Checksums

They are one way functions that change a stream of bytes into a different fixed sized stream of bytes. A few common hashing functions include SHA and MD5. Converting the hash into Base64 makes it easier to compare the checksum hash for integrity.


Many encryption algorithms use secret keys that can be any sequence of bytes, not just text. It's often easier to store the keys in a config file or database in Base64. The same is true with the ciphertext output of the encryption algorithm.


x509 certificates, like the ones used to secure websites with SSL over https are often stored as Base64.

Unable decode your source. Please make sure it is Base64 text.
Drag And Drop supports single files only