• Free forever
  • No sign-up
  • Private — runs in your browser

Base64 to Image / File

Paste Base64 or a data URI to preview it and download the original image or file.

Base64

How it works

The tool decodes the Base64 back into bytes and looks at the first few bytes — the file's “magic number” — to recognise its type: PNG files start with 89 50 4E 47, JPEGs with FF D8 FF, PDFs with %PDF. Images are previewed straight away, and Download file saves it with the right extension.

Where you'll find Base64 images

  • Data URIs in HTML, CSS or Markdown files.
  • API responses that return images or documents inside JSON.
  • Email source code, where attachments are Base64-encoded.
  • Canvas exports from canvas.toDataURL().

Related

← Back to the full Base64 & URL Encoder