URL Encoder & Decoder

Encode or decode URL components in your browser for query parameters, links and web development tasks.

Ad space — place a responsive AdSense unit here after approval.

URL Encoder & Decoder online

Percent-encode text for safe passage inside a URL — and decode percent-encoded text back — using the component encoding that query values and path segments require.

Quick answer: Encode a URL component before placing it in a query string, or decode an encoded component.

How to use this tool

  1. Paste the text or URL fragment into the input box.
  2. Click Encode to percent-encode it, or Decode to turn %XX sequences back into readable text.
  3. Copy the result from the result panel.

Common uses

Putting user input into a query string, encoding a search term with spaces and punctuation for a link, preparing redirect and callback parameters, and decoding the encoded URLs you find in logs, emails and analytics.

How it works

URLs reserve characters like ?, &, # and / as structure; when those characters are meant as data, they are written as %XX — a percent sign and the byte's hex value. This tool applies the component encoding (JavaScript's encodeURIComponent rules): everything except letters, digits and - _ . ! ~ * ' ( ) is encoded, so the output is safe to drop into any single component of a URL. Decoding reverses %XX sequences as UTF-8.

Worked example

Encode fish & chips? and you get fish%20%26%20chips%3F: space became %20, the structural & became %26 (where it can no longer split parameters), and ? became %3F. Decode %E4%B8%AD%E6%96%87 and you get 中文 — three bytes per character, because non-ASCII text is UTF-8 encoded byte by byte.

Privacy and browser processing

Encoding and decoding run in your browser with JavaScript — your text is never uploaded.

Frequently asked questions

Should spaces be %20 or +?

In a URL component, %20 is the safe form. The + means space only inside form-encoded query strings (application/x-www-form-urlencoded) — and there, a literal plus must itself be encoded as %2B. Mixing the two conventions is the classic cause of mangled search terms.

Why did my full URL get its :// encoded too?

Component encoding treats the whole input as one component, so : and / are encoded as well. To encode only a parameter value, paste just the value; to encode a whole URL's query, encode each value separately and assemble.

What happens decoding something that was never encoded?

Plain text passes through unchanged except where it contains % followed by hex digits, which will be interpreted as an escape. A lone % not followed by two hex digits makes the decoder report an error rather than guess.

Does it handle emoji and accented characters?

Yes — they are UTF-8 encoded byte by byte (an emoji is typically four %XX groups). Decoding reverses the process exactly, provided the bytes were UTF-8, which is the web's universal default.

Is my text uploaded?

No. Encoding and decoding run in your browser; nothing leaves the page — paste credentials-shaped strings with the usual care anyway.

Related tools

Ad space