What URL encoding is
Web addresses can only travel safely using a limited set of characters: unaccented letters, digits, and a handful of symbols. Whenever an address needs to carry a space, an accent, or a reserved symbol like & or ?, that character is swapped for a sequence that starts with % followed by two hexadecimal digits. This is called percent-encoding.
For instance, a space becomes %20 and the letter é becomes %C3%A9. This tool converts in both directions: it encodes plain text into a URL-safe form, and it decodes % sequences back into readable text. Everything happens inside your browser, with nothing sent to a server.
How to use the encoder
- Choose the Encode tab to go from plain text to URL form, or Decode for the reverse.
- Type or paste your text into the large box.
- In encode mode, pick the scope: a single component (for one parameter value) or a full URL (to fix a whole address without breaking its structure).
- The result appears instantly in the dark card below.
- Hit Copy to send it to your clipboard.
If decoding shows the “Invalid URL” message, the text contains a stray % or an incomplete sequence, such as %C3%A missing its last digit.
How percent-encoding works
Each unsafe character is represented by its bytes in the UTF-8 standard, and every byte is written as % plus its hexadecimal value. Ordinary English characters take a single byte, while accents and other symbols take two or more — which is why é produces two groups: %C3%A9.
Worked example
Let’s encode the text café & té as a component:
c,a,fare safe and stay the same.ébecomes%C3%A9.- the space becomes
%20. &becomes%26.- the space becomes
%20. tstays the same and the finalébecomes%C3%A9again.
Putting it all together gives caf%C3%A9%20%26%20t%C3%A9. Decoding that string returns exactly café & té.
Common character table
| Character | Becomes | Where it shows up |
|---|---|---|
| space | %20 | phrases with several words |
& | %26 | separates URL parameters |
? | %3F | starts the query string |
= | %3D | assigns a value to a parameter |
# | %23 | anchor within the page |
/ | %2F | path separator |
é | %C3%A9 | accented text |
ñ | %C3%B1 | Spanish words |
encodeURI versus encodeURIComponent
The difference is which symbols each one treats as “structure”. encodeURIComponent escapes almost everything, including /, ?, &, and =, because it assumes you handed it a single loose piece such as a parameter value. encodeURI leaves those separators alone because it assumes you gave it a complete address that must stay intact. Rule of thumb: use component for one data item and full URL for an already-assembled address.
Frequently asked questions
What does %20 mean in a URL?
%20 is simply an encoded space. The URL standard does not allow raw spaces, so browsers and servers replace them with %20. Whenever you see %20 in the address bar, read it as a space.
Why do accents look strange in URLs?
Because they are shown already encoded. An á is stored as the UTF-8 bytes C3 A1, and each one is written as %C3%A1. Nothing is broken — it is the safe way to carry accented characters, and decoding turns them back into normal letters.
When should I encode text?
Any time you place variable content inside a URL: a search parameter value, a file name with spaces, or something a user typed. Encoding keeps a stray & or ? from being mistaken for the structure of the address.
Is it safe? Is encoding the same as encryption?
It is not encryption. Percent-encoding is reversible by anyone and hides nothing — it only changes how characters are represented. Never rely on it to protect passwords or sensitive data; that requires real encryption.