JM Base64 Kit is a local studio. Text, images, and Data URIs never leave this tab. Use the three modes in any order; only one panel is shown at a time.
Text encode and decode
The left pane is input and the right pane is output. Choose Standard Base64, JWT-safe Base64URL, URL percent-encoding, or hexadecimal, then Encode or Decode. Conversion updates as you type and uses the Web Encoding API, so Chinese, Japanese, Korean, and emoji round-trip cleanly. The older btoa / atob pair is not used here because it is limited to Latin-1 and can throw on ordinary UTF-8 text.
Swap input and output flips the two panes and the encode/decode direction so you can check a round trip. A 76-character MIME wrap is available only for standard Base64. Malformed Base64, Base64URL, hex, or percent strings show an inline error instead of a guessed result.
Image to Data URI
Drop a local PNG, JPEG, WebP, GIF, SVG, ICO, or AVIF, pick a file, or load the built-in sample SVG. The file is read with the browser File API and is not posted anywhere. You get a compact preview, the original byte count versus the Data URI byte count, and the exact bloat percentage.
Three copy buttons give you the raw Data URI, a CSS background-image rule, and an HTML image tag with width and height when the preview can measure them. Data URIs are larger than the source file — often about a third larger — because Base64 uses four characters for every three bytes, plus a short MIME prefix.
Restore and download
Paste raw Base64 or a full data:<mime>;base64,… URI. The studio decodes the bytes in this tab, then looks at magic bytes to name the type: PNG, JPEG, GIF, WebP, SVG, PDF, ZIP, UTF-8 text or JSON, or a generic binary file. Images and SVG can preview here; text and JSON show in a read-only pane.
Download writes the restored bytes to a local file with a matching extension. Nothing is uploaded and nothing is kept after you close the tab.
No. The file is read in this browser. The page does not post the bytes, the Data URI, or a filename to a server.
Why is the Data URI larger than the file?
Base64 encodes three bytes as four ASCII characters, so the payload grows by about 33.3 percent. The data: prefix adds a little more. The studio shows both byte counts and the exact percentage.