Data Format Encoder
Encode, decode, escape, and convert text between multiple data formats including Base64, URL encoding, HTML entities, JSON, hexadecimal, binary, ROT13, and Unicode.
Actions
encode-base64-encode
Encode plain text to Base64 format.
Required fields: text - the plain text to encode
Example:
{
"action": "encode-base64-encode",
"text": "Hello world!"
}
Returns the Base64-encoded string (e.g., SGVsbG8gd29ybGQh).
encode-base64-decode
Decode a Base64-encoded string back to plain text.
Required fields: text - the Base64-encoded string
Example:
{
"action": "encode-base64-decode",
"text": "SGVsbG8gd29ybGQh"
}
encode-url-encode
Percent-encode text for safe use in URLs.
Required fields: text - the text to URL-encode
Example:
{
"action": "encode-url-encode",
"text": "hello world & goodbye"
}
Returns hello%20world%20%26%20goodbye.
encode-url-decode
Decode a percent-encoded (URL-encoded) string back to plain text.
Required fields: text - the URL-encoded string
Example:
{
"action": "encode-url-decode",
"text": "hello%20world%20%26%20goodbye"
}
encode-html-entity-encode
Escape special HTML characters (e.g., <, >, &, ") into HTML entities.
Required fields: text - the text containing HTML characters
Example:
{
"action": "encode-html-entity-encode",
"text": "<div class=\"main\">Hello & welcome</div>"
}
Returns <div class="main">Hello & welcome</div>.
encode-html-entity-decode
Convert HTML entities back to their original characters.
Required fields: text - the HTML-entity-encoded string
Example:
{
"action": "encode-html-entity-decode",
"text": "<p>Hello & welcome</p>"
}
encode-escape-json
Escape special characters in text for safe embedding inside JSON strings (e.g., newlines, tabs, quotes).
Required fields: text - the text to JSON-escape
Example:
{
"action": "encode-escape-json",
"text": "Line 1\nLine 2\tTabbed \"quoted\""
}
Returns Line 1\\nLine 2\\tTabbed \\\"quoted\\\".
encode-unescape-json
Convert JSON-escaped sequences back to their original characters.
Required fields: text - the JSON-escaped string
Example:
{
"action": "encode-unescape-json",
"text": "Line 1\\nLine 2\\tTabbed \\\"quoted\\\""
}
encode-text-to-hex
Convert text to its hexadecimal byte representation.
Required fields: text - the plain text to convert
Example:
{
"action": "encode-text-to-hex",
"text": "Hello"
}
Returns 48656c6c6f.
encode-hex-to-text
Convert a hexadecimal string back to plain text. Spaces, colons, and hyphens between hex bytes are automatically removed.
Required fields: text - the hexadecimal string
Example:
{
"action": "encode-hex-to-text",
"text": "48 65 6c 6c 6f"
}
encode-text-to-binary
Convert text to its 8-bit binary representation (space-separated bytes).
Required fields: text - the plain text to convert
Example:
{
"action": "encode-text-to-binary",
"text": "Hi"
}
Returns 01001000 01101001.
encode-binary-to-text
Convert an 8-bit binary string back to plain text. The binary string length must be a multiple of 8 bits.
Required fields: text - the binary string (spaces between bytes are optional)
Example:
{
"action": "encode-binary-to-text",
"text": "01001000 01101001"
}
encode-rot13-encode
Apply the ROT13 substitution cipher to text. ROT13 is its own inverse -- apply it again to decode.
Required fields: text - the text to encode/decode
Example:
{
"action": "encode-rot13-encode",
"text": "Hello World"
}
Returns Uryyb Jbeyq. Applying ROT13 again to the result returns the original text.
encode-unicode-escape
Convert Unicode characters to their escape sequences (e.g., \uXXXX).
Required fields: text - the text containing Unicode characters
Example:
{
"action": "encode-unicode-escape",
"text": "Caf\u00e9 \u2603"
}
encode-unicode-unescape
Convert Unicode escape sequences back to their original characters.
Required fields: text - the string containing \uXXXX escape sequences
Example:
{
"action": "encode-unicode-unescape",
"text": "Caf\\u00e9 \\u2603"
}
Common Workflows
- Prepare text for a URL query parameter: Use
encode-url-encodeto safely encode user input before appending it to a URL. - Embed user content in HTML: Use
encode-html-entity-encodeto prevent XSS or rendering issues when inserting text into HTML. - Store or transmit binary data as text: Use
encode-base64-encodeto convert binary content to a text-safe format, andencode-base64-decodeto restore it. - Inspect raw byte values: Use
encode-text-to-hexorencode-text-to-binaryto see the byte-level representation of any string. - Simple text obfuscation: Use
encode-rot13-encodeto lightly obscure text (e.g., hiding spoilers). Apply it twice to get the original back.
Important Notes
- All actions require the
textfield exceptget_instructions. - Decoding actions will return an error if the input is not valid for the expected format (e.g., invalid Base64, non-hex characters, binary string not a multiple of 8 bits).
- Hex decoding automatically strips spaces, colons, and hyphens, so formats like
48:65:6c:6c:6for48-65-6c-6c-6fare accepted. - ROT13 only rotates ASCII letters; digits, punctuation, and non-ASCII characters pass through unchanged.
- All text processing uses UTF-8 encoding.







