Text to URL — Free, in Your Browser
Every developer hits this eventually: a space in a search term, a & in a query parameter, a non-ASCII character in a redirect URL — and the link silently breaks.
URL Encoder & Decoder
Percent-encoding, both directions
Encode mode offers two flavors: percent (encodeURIComponent — spaces become %20, safe for path segments) and query (spaces become +, the query-string convention). Decode handles both, and shows a warning if the input is not valid percent-encoding.
Why convert Text to URL
Every developer hits this eventually: a space in a search term, a & in a query parameter, a non-ASCII character in a redirect URL — and the link silently breaks. URL encoding is the fix, and doing it in your browser means you are not pasting potentially sensitive query strings (session tokens, customer IDs) into an external form just to percent-encode them.
Paste the raw text and get the percent-encoded form: spaces become %20, symbols get their codes, and UTF-8 multibyte characters are encoded correctly as byte sequences — the form servers actually expect.
How to do it (3 steps)
- Paste the text or query string.
- The encoded output updates instantly.
- Copy it into your link, form action or code.
Technical note
This uses the same encoding rules as every browser (percent-encoding per RFC 3986 with UTF-8 byte expansion for non-ASCII). The practical trap it saves you: encoding an entire URL when you meant to encode only one parameter will mangle the :// and the slashes. Encode the *value*, paste it into the *position* — the tool encodes exactly what you give it, which is the right behaviour for both jobs.
The mistake worth avoiding
The common mistake is encoding at the wrong level of the URL. Encode the parameter value — the space in the search text, the ampersand in the filter — then place it in the query string. Never encode the entire URL, which turns the protocol slashes into percent codes and the link into a dead one. The same trap in the other direction: pasting an already-encoded value double-encodes it, and servers that decode only once leave you with literal percent-twenty in the result. If the output looks like double-escapes, you encoded something that was already encoded.
FAQ
- Is my text sent to a server? No — encoding is done in your browser, instantly.
- Why did my whole URL get mangled? You encoded the complete URL. Encode only the parameter value, then drop it back into the URL.
- Does it handle non-English characters? Yes — UTF-8 multibyte characters (devanagari, arabic, emoji) are encoded as their byte sequences, which is what servers expect.
- Should I use a plus sign or percent-twenty for spaces? Both work in query strings per the form-encoding convention, but percent-twenty is the safer default: every part of a URL understands it, and it is what the percent-encoding spec assigns to the space byte.
URL Encoder/Decoder — full tool →