URL Encoder
Encode and decode URL components
What is URL encoding?
URL encoding (also called percent-encoding) converts characters that are not safe in URLs into a format that can be transmitted over the internet. Characters like spaces, ampersands, and non-ASCII text are converted to % followed by their hexadecimal code — for example, a space becomes %20.
URL decoding reverses this process, converting percent-encoded sequences back to their original characters. This tool handles both encoding and decoding, and supports both standard URL encoding and the encodeURIComponent variant used in web development.
How to use URL Encoder
Enter text to encode or decode
Paste or type your URL or text string into the input area.
Choose encode or decode
Select Encode to convert special characters to percent-encoded form, or Decode to convert percent-encoded sequences back to readable text.
Copy the output
The result appears instantly. Click Copy to copy it to your clipboard.
Frequently asked questions
What is the difference between URL encoding and encodeURIComponent?
Standard URL encoding preserves characters that have structural meaning in URLs (like /, ?, &, =). encodeURIComponent encodes all of these, making it suitable for encoding individual query parameter values where those characters would otherwise break the URL structure.
Why do URLs have %20 instead of spaces?
Spaces are not valid in URLs. The HTTP specification requires spaces to be percent-encoded as %20 (or + in query strings). This ensures the URL is transmitted correctly by all HTTP clients and servers.
What characters need to be URL encoded?
Any character outside the unreserved set (A-Z, a-z, 0-9, hyphen, underscore, period, tilde) must be percent-encoded in URLs. This includes spaces, accented characters, punctuation, and all Unicode characters.
Does my data get sent to a server?
No. URL encoding and decoding runs entirely in your browser. Your data is never transmitted anywhere.