Skip to main content

URL Encoder / Decoder

Encode text into a URL-safe percent-encoded string, or decode a percent-encoded URL back to plain text. Supports component (encodeURIComponent), full-URI (encodeURI), and form-urlencoded (+ for space) schemes.

Input

Component encodes all reserved characters; Full URI preserves URL structure; Form uses + for spaces.

Output

Result
Was this helpful?

Guides

Encode any text into a URL-safe, percent-encoded string, or decode a percent-encoded URL back into readable text. URLs may only contain a limited set of characters, so anything else — spaces, ?, &, =, #, non-Latin letters, emoji — has to be represented as one or more %XX escape sequences. This tool converts in both directions, instantly and entirely in your browser.

How to use it

  1. Paste your text or URL into the Input Text box.
  2. Choose Encode to make text URL-safe, or Decode to turn %XX sequences back into plain text.
  3. Pick an Encoding Scheme to match how the value will be used (see below).
  4. The result appears immediately in the Result box, ready to copy or download.

Choosing an encoding scheme

Percent-encoding is not one-size-fits-all — the right scheme depends on where the value sits in a URL.

  • Component (encodeURIComponent) — the safest, most common choice. It escapes every reserved character, including ?, &, =, /, #, and space. Use it when encoding a single query-string value, a path segment, or any fragment that must not disturb the surrounding URL. Encoding hello world?a=1&b=2 yields hello%20world%3Fa%3D1%26b%3D2.
  • Full URI (encodeURI) — preserves the characters that give a URL its structure (: / ? & = #) and only escapes the rest, so a complete address stays intact. Use it to clean up an entire URL that contains spaces or accented characters. https://example.com/path?name=John Doe&age=30 becomes https://example.com/path?name=John%20Doe&age=30.
  • Form (application/x-www-form-urlencoded) — like Component, but encodes spaces as + instead of %20, matching how HTML forms submit data. hello world & friends becomes hello+world+%26+friends.

Decoding uses the matching reverse operation for each scheme, including converting + back to a space in Form mode.

What happens with invalid input?

Decoding requires well-formed %XX sequences. If the input contains a stray % or an invalid pair like %ZZ, the tool reports a clear error in the Result box instead of failing silently or producing garbage — check for a truncated or mistyped escape sequence.

Is my data private?

Yes. All encoding and decoding runs locally in your browser. Nothing you paste is uploaded, logged, or stored on a server.

Component vs. Full URI — which do I need?

If you are building or fixing a value that goes inside a URL (one query parameter, one path piece), use Component. If you already have a whole URL and just want to make it valid, use Full URI. When in doubt, Component is the more conservative option because it never leaves a reserved character unescaped.

urlencodedecodepercent-encodinguriurlencode

Love the tools? Lose the ads.

One payment clears every ad from your account, for good. No subscription, no tracking.