URL Encode / Decode

About this tool

URL encoding, also called percent-encoding, replaces characters that have a special meaning in a URL — spaces, ampersands, question marks, and any non-ASCII text — with a percent sign followed by their byte value, so the URL stays valid and unambiguous. This tool encodes text into that safe form and decodes it back to readable characters. It encodes at the component level (like encodeURIComponent), which is what you want for a single query-parameter value: characters such as &, = and ? are escaped so they cannot break the surrounding URL. Everything runs in your browser. Unicode and emoji are fully supported — they are encoded as UTF-8 percent sequences and decoded back exactly.

How to use

  1. Type or paste your text or URL into the input box.
  2. Press Encode to percent-encode it, or Decode to turn %XX sequences back into characters.
  3. Copy the result into your link, API request, or code.

Common use cases

  • Building query strings with values that contain spaces or symbols
  • Debugging why an API request with special characters fails
  • Reading an encoded redirect or tracking URL
  • Passing non-ASCII text safely inside a link

Frequently asked questions

When should I URL-encode a string?

Whenever you put data into a URL — query parameters, paths or fragments — characters like spaces, &, ? and non-ASCII text must be percent-encoded.

What's the difference between encodeURI and encodeURIComponent?

encodeURIComponent escapes a single value including &, = and ?, while encodeURI keeps URL-structure characters intact. This tool encodes components.

Does it handle Unicode and emoji?

Yes. Non-ASCII characters are encoded as UTF-8 percent sequences and decoded back correctly.

Why do spaces sometimes become + instead of %20?

The + form comes from the older form-encoding format used in form bodies. In URL paths and queries the correct encoding for a space is %20, which is what this tool produces.

Will encoding twice cause problems?

Yes. Encoding an already-encoded string turns each % into %25, producing double-encoded text. Decode once first if you are not sure.