URL Encoder / Decoder

Type or paste, then choose to encode or decode.

Advertisement In-content responsive — ad slot

Encode and decode URLs safely

Paste text to percent-encode it for use in a link or query string, or paste an encoded URL to turn it back into readable text. The tool handles full Unicode, so spaces, symbols and non-English characters convert correctly in both directions — all in your browser, with nothing sent over the network.

Why URL encoding exists

URLs may only contain a limited set of characters. Anything outside that set — a space, an ampersand, a slash inside a value, an accented letter — has to be percent-encoded so it isn't mistaken for part of the URL's structure. A space becomes %20, an ampersand becomes %26, and so on. Decoding reverses the process.

Example: name=John Doe&city=São Paulo encodes to name%3DJohn%20Doe%26city%3DS%C3%A3o%20Paulo.

Encoding a value vs. a whole URL

This tool encodes components — individual values like a single query parameter — which escapes reserved characters such as &, = and ?. That's the right choice when you're building a query string one value at a time. If you paste an entire URL to encode, its structural characters will be escaped too, which is expected behavior for a component encoder.

Frequently asked questions

What is URL encoding?

URL encoding, or percent-encoding, replaces characters that are unsafe or reserved in a URL with a percent sign followed by their hex code — for example a space becomes %20. It lets arbitrary text travel safely inside a link or query string.

When do I need to encode a URL?

Whenever you put text into a query parameter or path that contains spaces, ampersands, question marks, slashes or non-English characters. Encoding stops those characters from being misread as part of the URL's structure.

What is the difference between encodeURI and encodeURIComponent?

encodeURIComponent encodes a single value like one query parameter, escaping reserved characters such as & and =. encodeURI is meant for a whole URL and leaves those structural characters intact. This tool encodes components, which is what you usually want.