Base64 to Image
Decode a Base64 string or data URI back into an image, preview it and download it as a file. Free, instant and 100% in your browser.
π Runs entirely in your browser β nothing is uploadedTurn Base64 text back into an image
Base64 is a way of writing binary data as plain text, and it is how images end up inside JSON responses, HTML emails, CSS files, database fields and API payloads. This Base64 to image converter reverses the process: paste the text, and you get the original picture back, ready to preview and save as a normal file.
You can paste either a bare Base64 string or a complete data URI such as
data:image/png;base64,iVBORw0β¦. The tool strips the header, cleans up whitespace and
line breaks, accepts URL-safe characters and fixes missing padding before decoding the bytes locally.
Automatic format detection
Instead of trusting the declared MIME type, the decoder inspects the first bytes of the file to recognise PNG, JPEG, GIF, WebP, BMP, AVIF, ICO and SVG images. That means a string with no header, or one labelled with the wrong type, still produces a correctly named download. The status line shows the detected format, the pixel dimensions and the file size so you can quickly verify that the result is what you expected.
Private by design
Base64 strings often come from logs, API responses or databases and can contain sensitive pictures.
Everything here runs in your browser using atob and Blob URLs β the text you paste is
never sent to a server. If the string is not valid Base64, or decodes to something that is not an
image, you get a clear message instead of a broken download.
Troubleshooting
- Make sure you copied the whole string; a truncated value usually fails to decode or shows a half-drawn image.
- Remove surrounding quotes, JSON escapes such as
\nand anyurl(β¦)wrapper. - If the string decodes but is not an image, it may be a PDF or another file type β try a different tool.
- To go the other way, use the Image to Base64 tool.
How to use
- Paste the Base64Paste a Base64 string or a full data URI into the box.
- DecodeClick Decode image to see a preview with its type, dimensions and size.
- DownloadClick Download image to save the decoded file with the right extension.
Frequently asked questions
Which Base64 formats are accepted?
data:image/png;base64,β¦ URI. URL-safe Base64 and strings with line breaks or missing padding also work.How does the tool know the image type?
Is my Base64 text uploaded?
atob and Blob objects in your browser, so nothing leaves your device.