Encode text to Base64 or decode Base64 strings. Supports Unicode and image encoding.
Runs in your browser
Upload an image to get its Base64 data URI for embedding in HTML/CSS.
Preview
Data URI
Base64 is a binary-to-text encoding scheme that converts binary data (images, files, arbitrary bytes) into a string of ASCII characters using 64 printable characters. It is widely used in web development, email systems, and APIs to safely transmit binary data over channels that only handle text.
Common use cases include encoding images for embedding directly into HTML or CSS using data URIs, encoding API credentials in HTTP Basic Authentication headers (Authorization: Basic dXNlcjpwYXNz), encoding JSON payloads in JWTs, and attaching binary files in email via MIME encoding.
Base64 increases data size by approximately 33%, so it is not suitable for large file transfers - use it for small payloads, tokens, and credentials. Pair it with the URL Encoder for URL-safe Base64 encoding.
Switch between Encode and Decode mode using the toggle. Paste your plain text or binary string into the input and the result appears instantly in the output panel. For image encoding, use the file picker to select an image and get the Base64 data URI output that you can paste directly into an img src attribute or CSS background-image.
Click Copy to copy the result to your clipboard. All processing happens in your browser - no data is sent to any server.