URL Encode/Decode
EncodingEncode or decode URL components and full URLs
All processing happens locally in your browser — your data never leaves your machine.
Loading tool...
Examples
Encode Query Parameter
Input
hello world & goodbyeOutput
hello%20world%20%26%20goodbyeEncode Special Characters
Input
https://example.com/path?q=hello world&lang=enOutput
https%3A%2F%2Fexample.com%2Fpath%3Fq%3Dhello%20world%26lang%3DenDecode URL
Input
hello%20world%20%26%20goodbyeOutput
hello world & goodbyeFrequently Asked Questions
- What's the difference between encodeURI and encodeURIComponent?
- encodeURI encodes a full URI, leaving characters like :, /, ?, and # intact. encodeURIComponent encodes everything, making it suitable for encoding individual query parameter values.
- When should I URL-encode data?
- URL encoding is needed when passing special characters in query parameters, form data, or any part of a URL that might contain reserved characters like &, =, or spaces.