XhCode Online Converter Tools

Url Decoder



Url Decoder

URL Decoder is a process where encoded URLs are converted back to their original readable format. When URL encoding is applied, certain characters are replaced with a "%" followed by two hexadecimal digits. URL decoding reverses this process by converting these percent-encoded values back to the characters they represent.

Why Use URL Decoding?
URL decoding is used when:

You need to retrieve the original data from a URL-encoded string.
You have received URL-encoded parameters in web applications, APIs, or query strings, and need to decode them for processing.
You want to convert percent-encoded characters (e.g., %20) back into their respective characters (e.g., a space).
Common Examples of URL Decoding:
Encoded string: Hello%20World%21
Decoded string: Hello World!
Encoded string: This%20is%20a%20test%21
Decoded string: This is a test!
URL Decoding Process:
URL Decoding involves:

Searching for patterns in the URL that start with a % symbol, followed by two hexadecimal digits (e.g., %20, %3A).
Replacing each encoded value with the corresponding character in the ASCII or Unicode character set.
Returning the resulting decoded string.
Common URL Encodings and their decoded equivalents:
Encoded Value Decoded Character
%20 Space
%21 !
%23 #
%24 $
%25 %
%26 &
%2B +
%3A :
%3D =
%40 @
How to Decode a URL:
Manually: You can decode by replacing each percent-encoded value with its corresponding character.
Programmatically: Many programming languages have built-in functions for URL decoding.
JavaScript: decodeURIComponent()
Python: urllib.parse.unquote()
PHP: urldecode()
Java: URLDecoder.decode()
Example of URL Decoding:
Encoded URL:

perl

https%3A%2F%2Fwww.example.com%2Fsearch%3Fq%3Dhello%2520world
Decoded URL:

perl

https://www.example.com/search?q=hello%20world

TOP