Web Toolkit

URL Encoder / Decoder

Percent-encode and decode URLs, with component and full-URL modes.

URL encoding

Input0 chars
Output
Component mode escapes & = ? / #. Use it for a single query-parameter value.

Private by design. Everything runs locally in your browser. Your input is never uploaded, logged or stored on a server.

Frequently asked questions

What is URL encoding?

Also called percent-encoding, it replaces characters that are unsafe or reserved in a URL with a `%` followed by their hexadecimal byte values, so the URL parses unambiguously.

When should I use component mode instead of full URL mode?

Use component mode for a single value you are inserting into a query string or path segment. Use full URL mode when encoding an already-assembled URL that must keep its `?`, `&` and `/` structure.

Why did my encoded URL break?

Almost always double encoding: the string was already encoded and got encoded again, turning `%20` into `%2520`. Decode once before re-encoding.

Does it support non-ASCII characters?

Yes. Characters are encoded as their UTF-8 bytes, which is what modern browsers and servers expect.

About the URL Encoder / Decoder

URLs may only contain a restricted ASCII set, so anything else is percent-encoded: a % followed by the two hex digits of each UTF-8 byte. A space becomes %20, and becomes %E6%97%A5.

Choosing the right mode matters. Component mode (encodeURIComponent) escapes the reserved characters &, =, ?, / and # — that is what you want for a single query-parameter value, otherwise a value containing & silently splits into two parameters. Full URL mode (encodeURI) leaves those characters intact because they are structural, and only escapes spaces and non-ASCII.

Related tools