URL Encode/Decode

Encode and decode URLs and query parameters.

Input
Output

How to Use

Enter a URL or text string in the input field and click Encode to percent-encode special characters, or paste an encoded URL and click Decode to restore the original text. The tool handles full URLs as well as individual query parameter values.

Common Use Cases

  • Encoding query parameters that contain special characters like &, =, or spaces
  • Decoding URLs from server logs or analytics tools to read the original values
  • Preparing redirect URLs with encoded callback parameters for OAuth flows
  • Fixing broken URLs in email campaigns where spaces were not properly encoded

Frequently Asked Questions

What characters get encoded?

Characters outside the unreserved set (A-Z, a-z, 0-9, -, _, ., ~) are percent-encoded. For example, a space becomes %20, an ampersand becomes %26, and a forward slash becomes %2F.

What is the difference between encodeURI and encodeURIComponent?

encodeURI encodes a full URL but leaves characters like :, /, and ? intact. encodeURIComponent encodes everything except unreserved characters, making it suitable for encoding individual parameter values.

Is URL encoding the same as HTML encoding?

No. URL encoding (percent-encoding) replaces characters with %XX hex codes for use in URLs. HTML encoding replaces characters with named or numeric entities (like &) for safe display in HTML documents.