Base64 Encoder & Decoder

Encode text to Base64 or decode Base64 back to text

Input

Enter text to encode
0 characters

Options

URL-safe mode replaces + with - and / with _ for safe use in URLs.

Output

Base64 encoded result
0 characters
About This Tool

This is the general-purpose Base64 workspace — encode plain text into Base64 or decode a Base64 string back to text, switching direction with a single click. It's the right starting point when you're not sure yet which direction you need, or when you're going back and forth between the two while debugging. Prefer a dedicated page? The Base64 Encoder and Base64 Decoder pages default straight into one direction with focused, direction-specific guidance.

How to Use

Choose Encode or Decode using the tabs at the top. For Encode, paste plain text — the Base64 output appears as you type. For Decode, paste a Base64 string to recover the original text. Toggle 'URL-safe mode' when working with Base64 that appears in URLs, query strings, or filenames. Use Auto-detect to have the tool guess which direction your pasted input needs.

Common Use Cases

Switching mid-task

Encode a JSON payload to Base64 for an API request, then paste the API's Base64 response back in and switch to Decode to inspect it.

HTTP Basic Auth round-trip

Encode `username:password`, copy the header value, then decode it later to confirm the credentials.

JWT workflows

Encode a test payload to build a token manually, or decode an existing token's segments to inspect its claims.

Data URI workflows

Encode a small image to embed in CSS, or decode an existing data URI to extract the original bytes.

Limitations & Important Notes

Base64 is encoding, not encryption — anyone can decode it instantly, so never use it to protect secrets. It increases data size by about 33%, so it isn't suitable for large file transfers. All processing is client-side, so extremely large inputs are limited by your browser's available memory.