All tools URL Encoder / Decoder ● Live Developer Tools

How URL Encoder / Decoder works

  1. Choose Component mode or Full URL mode depending on what you're encoding.
  2. Select Encode or Decode.
  3. Type or paste your text or URL into the input box.
  4. The output updates live as you type.
  5. Click copy to copy the result to your clipboard.
  • Encode a search term or special characters before adding it to a query string.
  • Decode a URL from server logs to read its query parameters in plain text.
  • Encode a redirect URL to safely pass it as a parameter to another URL.
  • Debug why a link with special characters isn't working by inspecting its encoded form.
  • Decode percent-encoded characters in a URL copied from an email or document.

Encoding and decoding happen locally using the browser's built-in encodeURIComponent/encodeURI functions. Nothing is sent to a server.

  • Form-encoding conventions like + for spaces (application/x-www-form-urlencoded) aren't replicated — only standard percent-encoding.
  • Malformed percent-encoded input will produce a decode error rather than a best-effort guess.
  • Does not validate whether the resulting string is a well-formed URL overall.

URL Encoder / Decoder

URL Encoder / Decoder supports both encodeURIComponent (for individual query parameter values) and encodeURI (for full URLs that preserve structural characters). Toggle between encode and decode mode for instant bidirectional conversion.

URL Encoder / Decoder Runs locally

encodeURIComponent — encodes all special chars including : / ? # & =

Input

Output

Guide

How to use

  1. Choose Component mode or Full URL mode depending on what you're encoding.

  2. Select Encode or Decode.

  3. Type or paste your text or URL into the input box.

  4. The output updates live as you type.

  5. Click copy to copy the result to your clipboard.

Scenarios

Use cases

  • Encode a search term or special characters before adding it to a query string.

  • Decode a URL from server logs to read its query parameters in plain text.

  • Encode a redirect URL to safely pass it as a parameter to another URL.

  • Debug why a link with special characters isn't working by inspecting its encoded form.

  • Decode percent-encoded characters in a URL copied from an email or document.

Good to know

Limitations & Privacy

Private by design

Encoding and decoding happen locally using the browser's built-in encodeURIComponent/encodeURI functions. Nothing is sent to a server.

  • Form-encoding conventions like + for spaces (application/x-www-form-urlencoded) aren't replicated — only standard percent-encoding.

  • Malformed percent-encoded input will produce a decode error rather than a best-effort guess.

  • Does not validate whether the resulting string is a well-formed URL overall.

FAQ

Frequently asked questions

What is the difference between Component and Full URL mode?

Component mode (encodeURIComponent) encodes all special characters including :, /, ?, #, &, and = — safe for embedding a value inside a query parameter. Full URL mode (encodeURI) preserves URL structure characters so the result remains a navigable URL.

What is percent encoding?

Percent encoding replaces unsafe or reserved ASCII characters with a % followed by two hexadecimal digits representing the character's byte value, as required by the URL specification.

When should I use Component mode vs Full URL mode?

Use Component mode when encoding a single value that will be placed inside a query string (e.g. a search term). Use Full URL mode when you have a complete URL and want to encode special characters in it without breaking its structure.

Why are spaces encoded as %20 instead of +?

encodeURIComponent and encodeURI both produce %20 for spaces, which is the standard percent-encoding. The + character for spaces is specific to the application/x-www-form-urlencoded format used in form submissions, not general URL encoding.

Can I decode a URL that contains a mix of encoded and unencoded characters?

Yes. decodeURIComponent and decodeURI handle percent-encoded sequences and leave already-unencoded characters unchanged.

What happens if I try to decode invalid percent-encoding?

If the input contains a malformed percent-encoded sequence (e.g. a stray % not followed by two hex digits), decoding will fail with an error rather than producing incorrect output.

Does this handle Unicode characters like emoji or accented letters?

Yes. encodeURIComponent and encodeURI correctly percent-encode multi-byte UTF-8 characters, including emoji and accented letters.