# Base64 Encoder & Decoder

> Encode text or files to Base64 and decode Base64 back to text, with UTF-8 and URL-safe options.

- Type: free browser tool
- Category: Developer tools
- Page: https://www.sandbase.ai/tools/developer/base64-encoder

## About

Encode text to Base64, decode Base64 to text, or turn a file into a Base64 string or data URL for an API request.

## How it works

1. **Step 1** Choose Encode or Decode.
2. **Step 2** Paste text, or pick a file to encode.
3. **Step 3** Turn on URL-safe output if the value goes into a URL or a JWT.

## FAQ

### Why do APIs ask for Base64?

JSON cannot carry raw bytes, so images and audio are often sent as Base64 strings. Many image and speech models on SandBase accept either a URL or a Base64 data URL.

### Does it handle emoji and Chinese text?

Yes. Text is encoded as UTF-8 before Base64, and decoded the same way.

### Is my file uploaded?

Everything runs in your browser. Nothing you paste or open is uploaded.
