base64decode

Base64 to Image

Paste a Base64 string or data:image URI to see the picture instantly and download it as PNG, JPG, GIF, WebP or SVG. Decoding happens in your browser.

0 characters
Decoded outputWaiting for input

      
    

Decoding runs entirely in your browser. Nothing you paste is uploaded.

How to convert Base64 to an image

  1. Paste the Base64 string into the box above. A full data URI such as data:image/png;base64,iVBOR... works, and so does the bare string without the prefix.
  2. The decoder reads the first bytes of the result and labels it: PNG image, JPEG image, GIF image, WebP image or SVG image. The Preview tab opens on its own and shows the picture.
  3. Click Download file to save it. The file gets the right extension, such as decoded.png or decoded.jpg, based on the bytes, not on a guess.

Nothing is uploaded. The image is rebuilt in your browser, so screenshots, scans and private photos stay on your device.

How to tell which image format a Base64 string holds

You can often recognise the format from the first few characters, because every image format starts with a fixed signature:

Base64 starts with Format First bytes
iVBORw0KGgo PNG 89 50 4E 47
/9j/ JPEG FF D8 FF
R0lGOD GIF 47 49 46 38
UklGR WebP (RIFF container) 52 49 46 46
PHN2Zy or PD94bWw SVG (text: <svg or <?xml) 3C 73 76 67

The data:image/... prefix in a data URI also names the type, but it can be wrong if someone typed it by hand. This tool trusts the bytes.

Where Base64 images come from

Why a Base64 image will not display

It is not an image. If the label says Text, JSON or Binary data, the string holds something else. Check the Text or Hex tab to see what it really is.

The string was cut off. Base64 images are long, and copying from logs or terminals often truncates them. The preview may show only the top part of the picture, or nothing. Copy the full value again.

Extra characters crept in. Quotes, a trailing comma from JSON or escaped \n sequences break the data. Remove them, or turn on Strict mode to see where the first bad character is.

Line breaks. Email and PEM-style Base64 is wrapped at 76 characters. That is fine: line breaks and spaces are ignored here.

Base64 image size

Base64 makes data about 33% larger: every 3 bytes become 4 characters. A 30 KB PNG becomes roughly 40 KB of text. After decoding, the info line under the result shows the real size in bytes, so you can see how big the image file will be.

Need the reverse, or a PDF instead? See Base64 to PDF or use the main Base64 decoder for any other data.

Last updated:

Base64 to image FAQ

Can I paste a data:image URI?

Yes. Paste the whole data URI including the data:image/...;base64, prefix, or just the part after the comma. The tool handles both.

Which image formats are supported?

PNG, JPEG, GIF, WebP and SVG are previewed in the browser. Any other format can still be decoded and saved with Download file.

Is my image uploaded?

No. The image is decoded in your browser and never sent to a server.

Why does the preview show a broken or partial image?

The string is probably incomplete or contains extra characters such as quotes or escaped line breaks. Copy the full value again and remove anything that is not part of the Base64.

How do I save the decoded image?

Click Download file after the preview appears. The file is saved with the extension that matches its real format.