sqwartHome

Convert Base64 to Image

Paste Base64 text or a data URI, preview the image, and download it with the right file type.

  • Free
  • No upload
  • No watermark
  • No sign-up
How it works

How to convert Base64 to Image

  1. 1

    Paste the Base64 text or the whole data URI.

  2. 2

    Press Convert to image.

  3. 3

    Check the preview and detected format.

  4. 4

    Download the file.

In detail

What you can paste

  • A full data URI, such as data:image/png;base64,iVBORw0KGgo…
  • Raw Base64 with no prefix: the format is worked out from the decoded bytes.
  • URL-safe Base64 (with - and _ instead of + and /) and text broken over several lines are fixed automatically.
  • Missing = padding at the end is added for you.

Format detection

Rather than trusting the label in a data URI, the tool reads the first bytes of the decoded data, the file's signature, to tell PNG, JPG, GIF, WEBP, BMP, ICO, AVIF, HEIC, TIFF and SVG apart, and names the download accordingly. If the decoded data isn't an image it says so instead of saving a broken file.

Decoding happens in your browser, so API responses, database fields and email sources with private images are never sent anywhere.

Common sources of Base64 images

Developers meet Base64 images in JSON from APIs, in HTML email source, in CSS files, in browser developer tools and in exported chat or note data. Pasting the text here is the quickest way to see what the image is and save it as a normal file. The size of the decoded file is shown next to its format, which helps when you are checking why an API response or email is so large.

Exact bytes, nothing re-encoded

Base64 decoding is exact: the download is byte for byte the image that was encoded, with the same quality, size and metadata. Nothing is re-compressed or converted. If you need a different format afterwards, open the downloaded file in the image converter; to shrink it, use compress image.

FAQ

Questions, answered.

My string starts with data:image. Do I paste all of it?

Yes, paste the whole thing. Raw Base64 without the prefix works too.

It says the Base64 isn't valid.

Usually part of the string is missing. Make sure you copied it all, without surrounding quotes.

What format will the image be?

Whatever the data actually is. The tool detects it from the decoded bytes and names the file to match.

Can I convert an image to Base64?

Yes, with the image to Base64 tool.

Are my images uploaded anywhere?

No. The page does all the work inside your browser, so your pictures never leave your phone or computer. Once the page has loaded you can even turn off Wi-Fi and it keeps working.

Is it really free? Is there a limit?

Yes, it is free with no sign-up and no watermark. There is no daily limit or file cap, because your own device does the work rather than a paid server.

Keep going

More free image tools