MyWebUtils

URL Encoder / Decoder

Encode text for safe URL transmission or decode percent-encoded URL components.

Use for query parameter values, path segments, or any single URL part.

Input

0 chars0 bytes

Output

0 chars0 bytes
Common encoded characters ▾
space%20 / +
!%21
"%22
#%23
$%24
%%25
&%26
'%27
(%28
)%29
+%2B
,%2C
/%2F
:%3A
;%3B
=%3D
?%3F
@%40
[%5B
]%5D
Understanding URL Encoding

What is URL Encoding (Percent-Encoding)?

URLs have a limited character set — only a specific subset of ASCII is allowed. Characters outside that set, and characters that already have a special meaning in URLs (like `&`, `?`, `=`, and `/`), need to be converted before they can be safely sent across the internet. That conversion process is called URL encoding or percent-encoding.

The way it works is simple: any unsafe character gets replaced by a `%` sign followed by two hex digits representing its ASCII value. A space, for example, becomes `%20`.

Why is it Necessary?

  • When you're passing data through a query string, values have to be encoded. If you search for "cats & dogs", the raw `&` would look like the start of a new parameter. Encoded, it becomes `?q=cats%20%26%20dogs` and the server reads it correctly.
  • Characters like `/`, `?`, `#`, and `&` are reserved — they mean something specific in a URL. When those characters appear as part of your actual data, encoding them ensures they're treated as literal text rather than structural markers.
  • Non-ASCII characters — accented letters, Chinese characters, Arabic script — aren't part of the URL character set at all. Percent-encoding is how they get represented so web servers can interpret them correctly.
  • When you receive an encoded URL, decoding it makes it human-readable again. That's just as useful as encoding, especially when you're trying to debug a gnarly URL with a dozen parameters.

How This Tool Helps

  • Encode takes any string and converts it into a percent-encoded format that's safe to use in a URL.
  • Decode takes a percent-encoded string and converts it back to something you can actually read.
  • It's faster than writing a one-liner in the browser console every time, and you don't have to look up which characters need escaping.

More Encoders / Decoders Tools