URL encoder and decoder
LinkPercent-encode or decode a complete URL or one component. Choose component mode for a query value, path segment, or other individual piece of data.
URL mode or component mode
LinkEncode URL uses encodeURI(). It preserves characters that structure a complete URL, including :, /, ?, #, and &. Encode component uses encodeURIComponent() and encodes those separators when they are part of a value.
For example, component mode converts tea & cake to tea%20%26%20cake. If that value is used in ?q=, encoding the ampersand prevents it from being mistaken for the start of another parameter. Do not apply component mode to a complete URL because it will also encode its structural separators.
Percent encoding represents UTF-8 bytes as % followed by two hexadecimal digits. It is not limited to ASCII character codes. A space becomes %20; form encoding may instead use +, but this widget does not perform form encoding. Decoding malformed percent sequences produces an error.
Privacy and storage
LinkProcessing happens in your browser. The input and selected action are saved in localStorage. Clear them after handling sensitive URLs or tokens on a shared device.
Related tools
LinkFurther reading
Link- IETF: URI generic syntax
Widget made with staark