URL Encoder / Decoder

Encode and decode URLs and URI components. Supports full URL and component encoding modes.

Mode

Input
Output

      

About the URL Encoder / Decoder

The URL Encoder / Decoder converts special characters in URLs and query strings to their percent-encoded equivalents using JavaScript's native encodeURIComponent or encodeURI functions, and reverses the process instantly. It runs entirely client-side, making it a fast and private tool for frontend developers, QA engineers, and anyone building or debugging web requests. Choose between component mode for encoding individual query parameters and full URL mode for encoding complete addresses.

Common use cases

Frequently Asked Questions

What is the difference between encodeURIComponent and encodeURI?

encodeURIComponent encodes every character that is not an unreserved letter, digit, or one of - _ . ! ~ * ' ( ), making it the correct choice for encoding individual query string parameters or path segments. encodeURI preserves characters that have structural meaning in a full URL - such as :// / ? & = # - so it should only be used when encoding a complete URL that already has its structure intact. Using the wrong mode is a common source of double-encoding bugs.

Is my URL data private when using this tool?

All encoding and decoding is performed entirely in your browser using JavaScript's native encodeURIComponent, encodeURI, and decodeURIComponent functions. The URL or query string you paste never leaves your device - no network request is made, no server-side processing occurs, and nothing is logged or stored. This is particularly important when testing URLs that contain API keys, access tokens, or personal user data.

Why do spaces become %20 and not + signs?

This tool uses percent-encoding (RFC 3986), in which a space is represented as %20. The + notation for spaces is part of the older application/x-www-form-urlencoded format used in HTML form submissions, where a + is interpreted as a space by form parsers. Modern REST APIs, OAuth flows, and browser address bars all follow RFC 3986, so %20 is the universally correct and unambiguous representation for a space in a URL.

What characters are NOT encoded by URL encoding?

In encodeURIComponent mode, the following 66 characters are left unencoded because they are defined as unreserved in RFC 3986: uppercase and lowercase A-Z, digits 0-9, and the four symbols - _ . ~. All other characters - including spaces, brackets, slashes, ampersands, equals signs, and non-ASCII Unicode - are percent-encoded as their UTF-8 byte sequences prefixed with %. In encodeURI mode, URL structural characters like :// ? & = # @ are additionally preserved.

Does URL encoding work with non-Latin characters and international domain names?

Yes. JavaScript's encodeURIComponent converts non-ASCII characters to their UTF-8 byte sequences and percent-encodes each byte, which is the standard approach specified in RFC 3986 and IRI (RFC 3987). For example, the Japanese character 日 becomes %E6%97%A5. International domain names (IDNs) such as Arabic or Chinese hostnames are handled separately through Punycode encoding at the DNS level, which is outside the scope of URI percent-encoding.