Docs
Base64 Decoder
Decode Base64 back to text, handling URL-safe and whitespace.
Docs
Decode Base64 back to text, handling URL-safe and whitespace.
Decodes Base64 to text. Auto-detects URL-safe alphabet and strips whitespace.
POST /api/v1/tools/base64
Encode a string to Base64 or decode Base64 back to text. Supports URL-safe (RFC 4648 §5) and PEM-style line-wrap on encode.
Returns: The encoded or decoded Base64 string, plus the byte count of the input.
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
action |
string (encode|decode) | Yes | — | Whether to encode or decode. |
input |
string | Yes | — | The text to encode, or the Base64 string to decode. |
urlSafe |
boolean | No | false |
Produce (or accept) the URL-safe alphabet with - and _ instead of + and /. |
lineWrap |
boolean | No | false |
On encode, wrap output into lines of lineWrapWidth characters (PEM-style). |
lineWrapWidth |
number | No | 76 |
Line width when lineWrap is true. Default 76 (RFC 1421). |
curl -X POST https://data-migration-tools.com/api/v1/tools/base64 \
-H "Content-Type: application/json" \
-d '{"action":"encode","input":"hello world","urlSafe":true}'
See the full API reference for all examples and error codes.