URL Encoder & Decoder

Encode special characters for use in URLs, or decode percent-encoded strings back to readable text. The query-string builder below lets you assemble parameters visually.


Query String Builder

About URL Encoding

URL encoding (also called percent-encoding) replaces unsafe or reserved characters with a % followed by their hex code. For example, a space becomes %20, an ampersand becomes %26.

This tool uses JavaScript's encodeURIComponent() for encoding and decodeURIComponent() for decoding, which is the standard approach for encoding individual URL components.

FAQ

Should I encode the entire URL or just parts?

Typically you encode individual parameter values and path segments, not the entire URL. Encoding the whole URL would break the protocol, domain, and path separators.

What's the difference between encodeURI and encodeURIComponent?

This tool uses encodeURIComponent, which encodes everything except letters, digits, and a few safe characters. encodeURI leaves more characters unencoded (like /, :, ?) and is meant for encoding full URI strings.

Related Tools