MateenLabs No ads · Runs in your browser
Free Developer Tool

URL Encoder and Decoder

Paste text and turn it into something safe to put in a web address, or paste an encoded address and read it again. Choose whether you are encoding one part of a URL, a whole URL or a form value, and the result updates as you type. Accents, non-Latin scripts and emoji come back exactly as they went in.

When a percent sequence is broken the tool tells you where, in plain words, instead of failing. It also warns when the text looks encoded twice, a common cause of links that show %2520 where a space should be. A second box takes a full address apart into scheme, host, path, query and fragment and lists every query parameter, decoded, each with its own copy button.

Free Forever No Login No File Uploads Browser Processing
0 characters

0 characters
Type or paste text to encode or decode it.

Take a web address apart

What percent-encoding does

A web address can only carry a small set of plain characters. Everything else, such as a space, an ampersand inside a value or the letter é, is written as a percent sign followed by two hexadecimal digits for each byte of its UTF-8 form. So a space becomes %20 and é becomes %C3%A9. This is called percent-encoding or URL encoding, and it is defined in RFC 3986.

Which characters must be encoded depends on where they sit. In "component" mode the tool uses the same rules as the JavaScript function encodeURIComponent: it encodes every character that has a special meaning in a URL, including / ? & = # and +, so the text is safe as a single query value or path piece. In "full URL" mode it follows encodeURI and leaves those structural characters alone, so an address keeps its shape while spaces and non-ASCII letters are encoded. In "form" mode it follows the style used by HTML forms, where a space is written as + instead of %20.

Decoding reverses this. A decoder must be strict, because a stray percent sign or bytes that are not valid UTF-8 cannot be turned into text. This tool reports the character position of the first problem so you can find it in a long query string. It runs entirely in your browser, so tokens, session ids or private links that you paste are not sent anywhere.

  • Encode and decode in three modes: component, full URL and form style (space as +).
  • Plain-language errors with the position of a malformed % sequence.
  • A warning when text looks encoded twice, such as %2520.
  • A parser that splits an address into scheme, host, port, path, query and fragment.
  • A decoded table of every query parameter with a copy button on each value.
  • Unicode and emoji round-trip, with large pastes handled in slices that you can cancel.

How to use the URL Encoder / Decoder

  1. Paste your text or link into the input box.
  2. Choose Encode or Decode, then the mode that fits where the text will be used.
  3. Read the result, and copy it or press Use result as input to work on it further.
  4. To inspect a link, paste it into the address box lower down and read the parts and parameters.

Is it private?

Yes. Everything is done by your browser. The text and links you paste are not uploaded, not stored and not sent to any service.

Read our tools privacy policy →

Frequently asked questions

What is the difference between component and full URL mode?

Component mode encodes almost everything, including / ? & = and #, so the result is safe as one piece such as a query value. Full URL mode leaves those characters alone because they give an address its structure, and encodes only what cannot appear in an address, such as spaces and non-ASCII letters. If you encode a whole address in component mode, the colons and slashes are encoded too and the link stops working.

Why does a space sometimes become + and sometimes %20?

Both are used. %20 is the general percent-encoding of a space and works anywhere in a URL. The + form comes from HTML form submissions (application/x-www-form-urlencoded) and is only understood in query strings. When you decode, choose form mode if the text came from a form or a query string that uses +.

What does double encoding mean and how do I fix it?

It happens when text that is already encoded is encoded again, so %20 becomes %2520 (the percent sign itself turns into %25). The tool warns when it sees %25 followed by two hex digits. Decode once to get the original encoded text, and decode a second time to read it. To avoid it, encode each value only once, as late as possible.

Why does decoding say my text is not valid?

Decoding fails when a percent sign is not followed by two hexadecimal digits, when an encoded character is cut off, or when the bytes are not valid UTF-8, for example text that was encoded in an older encoding. The message gives the position of the first problem. Fix or remove that sequence and the rest will decode.

Are emoji and non-English text supported?

Yes. Text is converted to UTF-8 before encoding, so emoji, accents and scripts such as Arabic, Hindi or Chinese round-trip exactly. A broken half of an emoji (a lone surrogate) cannot be encoded, and the tool tells you where it is.

Is my text sent anywhere?

No. Encoding, decoding and parsing all run in your browser. Nothing is uploaded and nothing is stored, so private links and tokens stay on your device.

Related tools