Skip to content
MyToolkit.pro

Code & Data

URL Encoder / Decoder

Paste text to percent-encode it, or paste encoded text containing percent escapes to decode it automatically.

Private by design: text is processed only in this browser.

Private by design: text is processed only in this browser.

Direction
What are you converting?

Encode text / Decode text

Result

Input bytes
0
Output bytes
0
Encoded fragments
0

How URL encoding works

Percent encoding replaces characters that are unsafe in a URL component. A percent sign triggers a decode attempt; malformed escapes are encoded as text.

How to URL encode or decode a value

  1. Paste your text or encoded string into Text or encoded URL value.
  2. Under Direction, pick "Encode" to turn characters into %XX escapes, or "Decode" to turn escapes back into readable text. The tool does not guess the direction from the input. It uses whichever option is selected.
  3. Under What are you converting?, choose "URL component" for a single value (a search term, a path segment, a parameter value) or "Full URL" for a complete address. "Query value" gives the same result as "URL component". It does not turn spaces into +.
  4. The result updates as you type or switch options. Convert runs the conversion again by hand.
  5. Check the counters (input bytes, output bytes, encoded fragments), then press Copy result.

In Full URL mode the result panel also splits the address into Host, Path, Query and Fragment, so you can see which part each escape belongs to. The split only appears for complete addresses that start with a scheme such as https://. For example.com/a it stays hidden.

Percent encoding examples

Non-ASCII characters are converted to UTF-8 first, and each byte becomes its own %XX escape. That is why é turns into two escapes and an emoji turns into four:

Encode, URL component
café & crème  →  caf%C3%A9%20%26%20cr%C3%A8me
😀            →  %F0%9F%98%80
50% off       →  50%25%20off

The mode you pick decides which characters are kept. Full URL keeps the characters that give a URL its structure (:, /, ?, &, =, #) and only escapes things like spaces and accented letters:

Encode, Full URL
https://example.com/search?q=café menu#top
→ https://example.com/search?q=caf%C3%A9%20menu#top

URL component escapes those same separators. Use it when the whole input is one value, for example a URL you want to pass as a parameter inside another URL:

Encode, URL component
https://example.com/a b?x=1&y=2
→ https%3A%2F%2Fexample.com%2Fa%20b%3Fx%3D1%26y%3D2

Decoding reverses this. With Full URL selected, escapes that stand for reserved characters stay as they are, so the URL keeps its structure:

Input Direction / mode Output
caf%C3%A9 Decode / URL component café
https://example.com/a%20path?q=caf%C3%A9 Decode / Full URL https://example.com/a path?q=café
%26%20 Decode / Full URL %26 (the & escape stays)
Hello%2520World Decode / URL component Hello%20World

The last row is a double-encoded value: %25 is the escape for % itself. Decode it a second time to get Hello World. Only repeat the decode while the result still looks encoded. A %25 left over after one pass may be a real percent sign: 50%2525%20off decodes to 50%25 off, which is correct if the original text was 50%25 off.

When you need percent encoding

  • Building a link by hand: if you put a search term like shoes & socks in ?q= without encoding it, the & splits it into two parameters. Encoding it as a component gives shoes%20%26%20socks.
  • Redirect and callback parameters: an OAuth redirect_uri, a returnTo value or a tracking link that carries another URL has to be encoded as a component. Otherwise the inner ? and & get mixed up with the outer query.
  • Reading logs and analytics: server logs and referrer reports often show paths like /produkt/kr%C3%B3l. Decoding gives the readable path /produkt/król.
  • REST path segments: an ID or file name that contains a slash, such as a/b, would add an extra path level. In URL component mode it becomes a%2Fb and stays one segment.

To break a whole query string into separate key/value pairs, use the Query String Parser. For tagged campaign links, the UTM Builder builds and encodes the parameters for you.

Edge cases and limits

  • Malformed escapes: a lone % or an incomplete sequence such as 100% or %E0%A4%A can't be decoded. You get the message "This percent-encoded value is incomplete or invalid." and an empty result. If the % is meant literally, encode the text instead.
  • Plus signs: + is treated as a literal plus in both directions and in every mode, including Query value. Encoding a+b c gives a%2Bb%20c, and decoding Jan+Kowalski leaves the + as it is. HTML forms send spaces as + (application/x-www-form-urlencoded), so replace + with a space before you decode form data.
  • Characters that stay unescaped: letters, digits and - _ . ! ~ * ' ( ) are never encoded, even in URL component mode, so it's (ok)! becomes it's%20(ok)!. Some strict systems want ', ( and ) escaped too.
  • Input size: the input box accepts up to 1,000,000 characters.
  • This is not Base64: if the string is made only of letters, digits, + and / (or - and _), and often ends in = or ==, you probably want the Base64 Encoder / Decoder.

The set of reserved and unreserved characters comes from RFC 3986.

Frequently asked questions

What does %20 mean in a URL?

%20 is the percent-encoded form of a space: 20 is the hexadecimal code of the space character. You'll sometimes see a + used for spaces instead, but only in form-encoded query strings.

Should I encode the whole URL or just the parameters?

Usually just the parameter values. Encode each value on its own as a URL component and then join them with = and &. Encoding the finished URL as one component turns https:// into https%3A%2F%2F, so it only works when that URL is going to be a parameter inside another link.

How can I tell if a URL is already encoded?

Look for %XX sequences such as %20 or %C3%A9. If you see %25 followed by two hex digits (for example %2520), the value has probably been encoded twice.

Is URL encoding a form of encryption?

No. Percent encoding only rewrites characters so that a URL can carry them, and anyone can reverse it. Don't use it to hide sensitive data in links.

All in Code & Data

Base64 Encoder / Decoder

Encode text to Base64 or decode Base64 to text instantly in your browser.

Code & Data In your browser

HTML Entity Encoder

Encode text to HTML entities or decode entities back to text in your browser. Escape <, >, &, quotes safely, or reverse named, decimal and hex entities. Nothing is uploaded.

Code & Data In your browser

Morse Code Translator

Translate text to Morse code and back in your browser. Choose the direction, get instant output with correct word spacing. Nothing is uploaded.

Code & Data In your browser

Caesar cipher (ROT13)

Encode or decode text with a Caesar cipher — each letter is rotated forward through the alphabet by a fixed amount. A shift of 13 is ROT13, its own inverse. Digits, spaces and punctuation are left as they are.

Code & Data In your browser

Query String Parser

Parse a URL query string in your browser. Paste a query string or a full URL and read every key=value pair as lines or JSON, with percent-decoding. Nothing is uploaded.

Code & Data In your browser

QR Code Generator

Generate a QR code from text or a URL, entirely in your browser. No upload, no external library, no tracking. Download as PNG.

Code & Data In your browser

What do you need?

Swipe up for the next one