URL Encoder / Decoder

Encode or decode URL components. Convert special characters, spaces, and Unicode into percent-encoded format (and back).

What is URL Encoding?

URL encoding (also called percent-encoding) converts characters that are not allowed in URLs into a format that can be transmitted over the Internet. For example, spaces become %20and Chinese characters like “你好” become %E4%BD%A0%E5%A5%BD.

This is essential when you need to include special characters, non-ASCII text, or reserved characters (like &, ?, =) in a URL query string.

When to Use
  • Constructing API URLs with query parameters containing special characters
  • Decoding obfuscated or encoded URLs for debugging
  • Encoding search queries that contain non-English characters
  • Working with redirect URLs that contain dynamic parameters
Encoding Reference

Common characters and their percent-encoded forms:

Space      ->  %20
&          ->  %26
?          ->  %3F
=          ->  %3D
/          ->  %2F
#          ->  %23
%          ->  %25
你好       ->  %E4%BD%A0%E5%A5%BD

Example. The search query Hello world & friends encoded becomes Hello%20world%20%26%20friends.

URL Encode/Decode Tool
URL encoding and decoding tool, supports Chinese characters and special characters
Frequently Asked Questions

What is the difference between encodeURIComponent and encodeURI?

encodeURIComponent escapes almost everything, including /, ?, and &, making it the right choice for query parameter values. encodeURI leaves structural characters intact and is meant for full URLs.

Why does a space encode to %20 instead of +?

In query strings, + is a legacy way to represent a space (used by form submissions). Standard URL encoding uses %20 for a space everywhere.

Do I need to encode non-ASCII characters?

Modern browsers often handle Unicode directly, but many APIs and legacy systems expect percent-encoded UTF-8. Encoding is always the safe choice for maximum compatibility.

Can URL encoding be reversed automatically?

Yes. Decoding turns %XX sequences back into their original characters, so you can round-trip encoded URLs back to plain text for debugging.

Is my URL sent to a server?

No. Both encoding and decoding happen entirely in your browser, so you can safely process sensitive URLs and tokens without them leaving your device.

Common Mistakes
  • Encoding an entire URL instead of just the query values — this breaks the :// and / structure.
  • Using + for spaces in non-form contexts.
  • Double-encoding — encoding text that is already percent-encoded turns % into %25.
  • Decoding user input before validation, which can expose or mask unexpected characters.