Skip to content

Encode / Decode

Base64, hex, URL, and HTML encoding and decoding.

7 modules

ModuleDescription
Base64 DecodeDecode Base64 encoded text
Hex DecodeDecode hexadecimal to text
URL DecodeDecode URL encoded text
Base64 EncodeEncode text to Base64
Hex EncodeEncode text to hexadecimal
HTML EncodeEncode text to HTML entities
URL EncodeURL encode text (percent encoding)

Modules

Base64 Decode

decode.base64

Decode Base64 encoded text

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-Base64 encoded text to decode
encodingstringNoutf-8Base64 encoded text to decode
url_safebooleanNoFalseCharacter encoding for output

Output:

FieldTypeDescription
resultstringInput is URL-safe Base64
originalstringDecoded string
validbooleanDecoded string

Hex Decode

decode.hex

Decode hexadecimal to text

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-Hexadecimal text to decode
encodingstringNoutf-8Hexadecimal text to decode

Output:

FieldTypeDescription
resultstringCharacter encoding for output
originalstringDecoded string
validbooleanDecoded string

URL Decode

decode.url

Decode URL encoded text

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-URL encoded text to decode
plus_spacesbooleanNoFalseURL encoded text to decode

Output:

FieldTypeDescription
resultstringTreat + as space (form decoding)
originalstringDecoded string

Base64 Encode

encode.base64

Encode text to Base64

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-Text to encode
encodingstringNoutf-8Text to encode
url_safebooleanNoFalseCharacter encoding

Output:

FieldTypeDescription
resultstringUse URL-safe Base64 encoding
originalstringBase64 encoded string
lengthnumberBase64 encoded string

Hex Encode

encode.hex

Encode text to hexadecimal

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-Text to encode to hex
encodingstringNoutf-8Text to encode to hex
uppercasebooleanNoFalseCharacter encoding
separatorstringNo-Use uppercase hex letters

Output:

FieldTypeDescription
resultstringSeparator between hex bytes
originalstringHex encoded string
byte_countnumberHex encoded string

HTML Encode

encode.html

Encode text to HTML entities

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-Text to encode as HTML entities
quotebooleanNoTrueText to encode as HTML entities

Output:

FieldTypeDescription
resultstringAlso encode quote characters
originalstringHTML encoded string

URL Encode

encode.url

URL encode text (percent encoding)

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-Text to URL encode
plus_spacesbooleanNoFalseText to URL encode
safestringNo-Use + instead of %20 for spaces (form encoding)

Output:

FieldTypeDescription
resultstringCharacters that should not be encoded
originalstringURL encoded string

Released under the Apache 2.0 License.