Richscripts

URL encode and decode

Make text safe to put in a link, or turn an encoded link like caf%C3%A9%20menu back into café menu.

Private: everything happens in your browser. Nothing you type or choose is uploaded.

Direction

How to use it

  1. Choose Encode or Decode.
  2. For one value (such as a search term) keep "Query value"; for a complete link choose "Whole URL".
  3. Copy the result.

Questions and answers

What is the difference between the two modes?

"Query value" encodes every reserved character, including / ? & and =, which is right for one parameter value. "Whole URL" keeps the characters that give a URL its structure.

When should spaces become +?

HTML forms send spaces as + in the query string. Most other places, including paths, use %20. When decoding, tick "Spaces as +" if the URL came from a form.

What does "broken % sequence" mean?

A % must be followed by two hex digits that form valid UTF-8. A lone % or a cut-off sequence cannot be decoded.

Encoding tools