URL Encode & Decode

Percent-encode text for links and query strings, or decode it back.

Runs in your browser
Text or encoded URL
Drop file to load it
EmptySaved locally
Result
Ready
Matches HTML form submissions and many query strings.
More options (1)
Try an example:

How to use the URL Encode & Decode

  1. Paste the text, URL or encoded string into the left panel.
  2. Choose Encode or Decode, and whether you are working with one value or a whole URL.
  3. Turn on "+ for spaces" when dealing with HTML form data.
  4. Copy the result. Enable line-by-line mode to process a list of values at once.

Examples

About this tool

URLs can only contain a limited set of characters. Spaces, accented letters, emoji and symbols like &, ? or # must be written as percent-escapes such as %20 or %C3%A9 so that browsers and servers read them correctly. This tool converts text to that form and back, using UTF-8 just like modern browsers do.

The two modes match the JavaScript functions developers already know. "A value" behaves like encodeURIComponent and escapes everything that has a special meaning in a URL, which is what you want for a single query parameter or path segment. "A whole URL" behaves like encodeURI and leaves the structure characters (: / ? & = #) alone, so a complete address stays clickable.

Tip: if you are building a query string by hand, encode each value separately in value mode, then join them with & and =. Encoding the entire string at once would also escape the separators and break it.

This tool runs entirely in your browser. What you type or open is never sent to a server.

Frequently asked questions

Does this tool send my URLs anywhere?

No. All encoding and decoding happens locally in your browser. Nothing is logged or uploaded, so it is fine for internal links or URLs containing tokens.

Should spaces be %20 or +?

Both are common. %20 is correct everywhere in a URL. + means a space only inside query strings sent by HTML forms (application/x-www-form-urlencoded). If unsure, use %20.

Why does decoding fail with a "malformed" error?

A % sign must be followed by two hexadecimal digits, and the bytes must form valid UTF-8. A lone % or a truncated sequence like %E2%82 will fail. Encode literal percent signs as %25.

What is the difference between value and whole-URL mode?

Value mode escapes reserved characters like / ? & =, which is right for a single parameter. Whole-URL mode keeps them so the link still works, and only escapes spaces and non-ASCII characters.