01 / Encode
Spaces and symbols
Characters a URL cannot hold become % and two hex digits: a space is %20, é is %C3%A9.
Free tool
Paste an encoded URL to read it, or text to percent-encode it. Encode one part, like a query value, or a whole address, which keeps its slashes and leaves % codes that are already there alone, so nothing is encoded twice. A stray % never stops decoding, and text encoded twice is spotted. Any URL or query string is split into its parts, with every parameter decoded and ready to copy.
Need a custom tool, app or website? Contact us →A whole URL keeps / ? & = # and any % codes already there. One part encodes those too.
Auto decodes when the text has % codes in it, and encodes when it does not.
Encoded and decoded in your browser. Nothing is sent anywhere or saved. Only your settings are remembered on this device.
Percent encoding
01 / Encode
Characters a URL cannot hold become % and two hex digits: a space is %20, é is %C3%A9.
02 / Part or whole
A query value must encode & and =; a whole URL must keep them. Pick the one you mean.
03 / Read
Any full URL is broken into scheme, host, path and each query parameter, decoded.
Guide
URL encode and decode means swapping characters a web address cannot carry for a % sign and two hex digits, then turning them back. A space becomes %20, an ampersand becomes %26, and an accented letter like é becomes %C3%A9, which is its two UTF-8 bytes. This tool does both directions in your browser, lets you choose between encoding one part of a URL or a whole address, and splits any full URL into its scheme, host, path and query values so you can read it.
! ' ( ) * encoded.utm_source=news&page=2, is split too.Some characters have a job in a URL. The slash separates folders, ? starts the query string, & separates parameters, = joins a name to its value and # starts the fragment. Encoding a whole URL keeps those characters as they are, so the address still works. Encoding one part turns them into % codes, so they become plain text inside a value instead of breaking the URL apart.
Here is why it matters. Say you want a search link for the phrase red shoes & socks. If you encode the whole address https://example.com/search?q=red shoes & socks, the & is kept, and the site reads the query as q=red shoes plus a second, empty parameter called socks. The fix is to encode just the phrase with One part, which gives red%20shoes%20%26%20socks, and then paste that after q=. Now the & is part of the search term.
A simple rule: if you are building a URL from pieces, encode each value with One part and join them with the normal / ? & and = characters yourself. Use A whole URL only to clean up an address someone typed with spaces or accents in it.
A whole URL also leaves any % code that is already in the text alone. Paste https://example.com/a%20b/c d and only the second space is encoded, giving a%20b/c%20d. The browser's own encodeURI() would turn the first one into %2520.
| Character | Encoded | Kept by A whole URL? |
|---|---|---|
| space | %20 (or + in form style) | No, always encoded |
| & | %26 | Yes |
| = | %3D | Yes |
| ? | %3F | Yes |
| / | %2F | Yes |
| # | %23 | Yes |
| + | %2B | Yes |
| % | %25 | No, always encoded |
| " | %22 | No, always encoded |
| é | %C3%A9 | No, always encoded |
Letters, digits, the hyphen, underscore, full stop and tilde are never encoded. The asterisk, apostrophe, round brackets and exclamation mark are left alone too, as JavaScript does, unless you tick Strict RFC 3986, which encodes them as %2A %27 %28 %29 %21. Some signing schemes for APIs, such as OAuth 1.0, need the strict form.
%20 means a space everywhere in a URL. The + sign means a space only inside a query string sent the way an HTML form sends it, which is why some search pages show ?q=red+shoes. In a path, a + is just a plus sign. If you are not sure, leave the box unticked and use %20.
The same box changes decoding. With it ticked, every + is read as a space before the % codes are decoded. Leave it unticked when you decode a link where + is meant literally, like a phone number or C++.
%2520, a %20 was encoded a second time: the % became %25. After decoding, the tool notices that % codes are still there and shows Decode again above the result.100% or %G1, is kept as written, and the status line says where it is. The rest is still decoded.example.com/, or a query string. Plain text has no parts to show.If you write code, this tool uses the same functions your browser gives JavaScript. One part matches encodeURIComponent(). A whole URL is like encodeURI(), except that % codes already in the text are kept. Decoding gives the same result as decodeURIComponent(), without stopping at a stray %. In Python, urllib.parse.quote() and quote_plus() do the same jobs, the second one with + for spaces. In PHP, rawurlencode() gives %20 and urlencode() gives +. Testing a value here first is a quick way to see what your code should produce.
Working with tokens or API responses too? The Base64 decoder and the JWT decoder handle the other encodings you often find inside URLs, and the JSON formatter makes a decoded payload readable.
Questions
Replacing characters that are not allowed in a URL with a % and their byte value in hex, so the URL survives being sent.
%20 works everywhere. + means a space only in form-style query strings.
One part for a value you put into a query string; whole for an address with spaces or accents in it.
It is kept as written and the rest is decoded. The status line says where each stray % is, so you can fix it.
No. Everything happens in this tab and nothing is saved. Only your settings are remembered on this device.
RFC 3986 is the standard for URLs. It lets ! ' ( ) * appear as they are, but some systems, such as OAuth 1.0 signatures, want them encoded too. Tick the strict option to encode them.
It is a space. URLs cannot contain a real space, so it is written as % followed by 20, the hex value of the space character.
It is a space that was encoded twice. The first pass made %20, and the second pass turned the % into %25. Decode it, then press Decode again to get the space back.
Yes, to be safe. Browsers often show accented letters in the address bar, but when the URL is sent or pasted into code it should carry the encoded UTF-8 bytes, like %C3%A9 for é.
No. Anyone can decode it in a second. It only makes text safe to put in a URL, so never use it to hide a password or private data.