Base64 Encoder / Decoder
Encode plain text to Base64 or decode Base64 back to text. Runs 100% in your browser.
URL-Safe Base64
Converts standard Base64 output to URL-safe format by replacing + with -
and / with _.
About Base64
Base64 is an encoding scheme that converts binary data into ASCII text. It is commonly used to embed images in HTML/CSS, pass data in JSON payloads, encode credentials in HTTP Basic Authentication, and transmit binary data over text-based protocols. Base64 encoded data is about 33% larger than the original.
How to Encode or Decode Base64
Select the Encode tab to convert plain text to Base64, or Decode to reverse the process.
Paste or type your text into the input field. The result updates automatically as you type.
Click Copy to copy the output to your clipboard.
Use the URL-Safe section below to convert standard Base64 to a format safe for use in URLs.
Common Use Cases
data:image/png;base64,...Frequently Asked Questions
What is Base64 encoding?
Base64 is an encoding scheme that converts binary data into a set of 64 ASCII characters (A–Z, a–z, 0–9, +, /). It is used to safely transmit binary data over systems that only handle text, such as email (MIME) or JSON APIs.
Why is Base64 output larger than the input?
Base64 encodes every 3 bytes of input into 4 ASCII characters, resulting in an output that is approximately 33% larger than the original. Padding characters (=) are added to make the total length a multiple of 4.
What is URL-safe Base64?
Standard Base64 uses + and / characters, which have special meanings in URLs. URL-safe Base64 replaces + with - and / with _, and omits the = padding, making it safe to use in URLs and filenames without percent-encoding.
Is Base64 a form of encryption?
No. Base64 is encoding, not encryption. It can be decoded by anyone without a key. Never use Base64 to "hide" sensitive data — use proper encryption (AES, RSA) for that purpose.