Encode & Hash

Base64 Encoder & Decoder

Encode text or files to Base64, or decode Base64 strings back to plain text. Supports standard and URL-safe Base64.

Free Client-Side No Sign-Up Nothing Stored
Input text or Base64 string
Output
Output appears here…

What This Tool Does

The Base64 Encoder & Decoder converts text and binary files to Base64 encoding and back. It supports both plain text encoding using the browser's native btoa() / atob() APIs, and file encoding via the FileReader API — all entirely in your browser without uploading anything to a server.

How to Use

To encode text: paste your text into the input and click Encode to Base64.
To decode: paste a Base64 string into the input and click Decode from Base64.
To encode a file: click Upload File to select any file — the Base64 output appears automatically.
Click Copy Output to copy the result to your clipboard.

Frequently Asked Questions

What is Base64 encoding?
Base64 is a binary-to-text encoding scheme that represents binary data using 64 printable ASCII characters (A-Z, a-z, 0-9, +, /). It is commonly used to embed binary data in text-based formats like JSON, XML, HTML, or email.
When would I use Base64 encoding?
Common uses include embedding images in CSS or HTML (data URIs), encoding attachments in email (MIME), passing binary data in JSON API payloads, storing binary data in databases that only support text, and encoding credentials in HTTP Basic Auth headers.
What is the difference between standard and URL-safe Base64?
Standard Base64 uses + and / characters which have special meaning in URLs. URL-safe Base64 replaces + with - and / with _ so the output can be used safely in URLs and filenames without encoding. Use the URL-Safe Base64 tool for those use cases.
Does Base64 encrypt my data?
No. Base64 is encoding, not encryption. It is trivially reversible and provides no security. Anyone with the Base64 string can decode it instantly. For security use a proper encryption algorithm.
Is my data sent to a server?
No. All encoding and decoding happens in your browser using JavaScript. Nothing is transmitted to our servers.
Can I encode files, not just text?
Yes — click the Upload File button to select any file. The tool will read it client-side and produce the Base64 representation. This works for images, PDFs, and any other binary file.