About the URL Encode and Decode
Paste text and choose encode or decode. Encoding is needed when a value inside a URL contains spaces, symbols or non-English characters that would otherwise break the link.
This tool encodes a single value, as encodeURIComponent does. Do not encode a whole URL, or the slashes and colons will be escaped too.
How to Use the URL Encode and Decode
- Choose encode or decode.
- Paste your text.
- Copy the result.
Formula and Method
Percent encoding
byte → % + two hex digits
Non-ASCII characters are encoded as UTF-8 bytes first.
Worked Example
Encoding a query value
Input: a b&c=d
- Space → %20
- & → %26
- = → %3D
Result: a%20b%26c%3Dd
Frequently Asked Questions
Why is a space %20 and sometimes +?
Form submissions use + for spaces. Elsewhere in a URL it is %20.
Which characters are safe?
A–Z, a–z, 0–9 and - _ . ~
What is percent-encoding?
The official name, defined in RFC 3986.
Related Calculators
Sources and Further Reading
Accuracy and Scope
Results follow the formulas and scales stated on each page. Institutions, vehicles and circuits differ, so check against your own rules and equipment. See our full disclaimer.