Back to Tools
URL Encode / Decode
About the URL Encode / Decode
Encode text so it is safe to use in a URL, or decode a percent-encoded URL back to readable text.
How to use the URL Encode / Decode
- Paste a URL or Parameter String.
- Press URL Encode or URL Decode.
- Copy the Result.
Formula and method
Unsafe characters are replaced with a percent sign and their hexadecimal value: a space becomes %20, & becomes %26 and / becomes %2F when encoded as a parameter.
Worked example
a b&c encodes to a%20b%26c.
When to use the URL Encode / Decode
- Making text safe to include in a web address or query string.
- Reading a percent-encoded URL from a log or an analytics report.
- Fixing broken links caused by spaces and special characters.
Common mistakes to avoid
- Encoding the whole URL, including the https:// and slashes. Encode only the parts that carry data, such as query values.
- Encoding twice, which turns %20 into %2520.
Tips
- Encode query parameter values, not the whole URL, or you will break the : and / separators.
- A plus sign can mean a space in query strings, so decode carefully.
Frequently Asked Questions
URLs may only contain a limited set of ASCII characters, so anything else must be percent-encoded.
A space is not allowed in a URL, so it is replaced by its hexadecimal code, %20. Some forms use + instead.