Base64 Encoder & Decoder
Encode text or files to Base64 — or decode Base64 strings back to text. Auto-detection, image preview, and file support. Runs entirely in your browser.
Input
Outputread-only
About this tool
A fast, privacy-first Base64 tool that works offline. Switch between Encode, Decode, and Auto Detect modes — the output updates instantly as you type. Use the File tab to convert any file to Base64, useful for embedding images in CSS data URLs or sending binary data over text-based APIs.
When decoded output contains an image, a live preview appears automatically. Your data never leaves your device.
How to use
Choose a mode
Select Encode to convert text to Base64, Decode to convert Base64 back to text, or Auto Detect to let the tool decide.
Enter text or upload a file
Type or paste content in the Text tab for string encoding. Switch to the File tab to upload any file type and convert it to Base64.
See the result
The output appears instantly as you type. If the decoded output is an image, a live preview is shown automatically.
Copy or Download
Click Copy to copy the result to clipboard, or Download to save the output as a file.
Related tools
Frequently asked questions
Common questions about Base64 encoding and decoding.
