Skip to content
hateitall

URL Encoder

Make any text safe to put in a URL, choosing exactly which characters to escape for a query value, a whole URL or form data.

Processed locallyIn: Text, URLOut: Percent-encoded text

Loading tool…

How to use url encoder

  1. Type or paste the text or URL.

  2. Pick Component for one value, Whole URL to keep its structure, or Form data for + as space.

  3. Choose uppercase or lowercase hex.

  4. Copy the result, or switch to Decode to check it.

What this tool does

  • Matches encodeURIComponent, encodeURI and the application/x-www-form-urlencoded rules exactly.
  • Encodes non-ASCII text as UTF-8 bytes, so café becomes caf%C3%A9.
  • An Every byte mode escapes letters too, for testing decoders.
  • Warns about broken characters that cannot be encoded instead of producing bad output.

How the result is verified

Each result is decoded again with the matching rules (+ as space for form data) and compared with your input character for character before it is marked verified.

Frequently asked questions

Should I use Component or Whole URL?

Use Component for anything you insert into a URL, such as one search term or one path segment, because it also escapes / ? & and =. Use Whole URL only on a complete address whose slashes and question mark must keep their meaning.

Why is a space sometimes %20 and sometimes +?

In paths and in encodeURIComponent a space is %20. HTML forms and URLSearchParams send spaces as + in query strings. Both are decoded to a space by servers that expect them.

Is my data uploaded to a server?

No. Everything you drop, paste or type is processed by code running in this browser tab. You can check it yourself: open your browser's developer tools, watch the Network panel, and use the tool. No request carries your data.

Percent-encoded URLs and parameters back to readable text

Percent-encoded text · URL→ TextLight on device

Text or files to Base64, Base64url or a data URL, with UTF-8 support

Text · Any file→ Base64Light on device

Text to \u escapes, U+ code points and HTML references, and back

Text · Escaped text→ Escaped textLight on device