URL Encode
Encode text for safe use in URLs using percent-encoding.
$text
0 chars1 lines
$encoded[READY]
0 chars1 lines
Related Tools
FAQ
- What characters does URL encoding replace?
- URL encoding replaces characters that are not allowed in URLs, including spaces (→ %20), ampersands (→ %26), equals signs (→ %3D), question marks (→ %3F), and non-ASCII characters like accented letters and emoji.
- What is the difference between encodeURI and encodeURIComponent?
- encodeURI encodes a full URI but preserves characters like :, /, ?, and #. encodeURIComponent encodes everything except letters, digits, and - _ . ~, making it suitable for encoding individual query parameter values.
- Does this tool handle Unicode?
- Yes. The encoder handles Unicode characters by first converting them to UTF-8 bytes, then percent-encoding each byte. For example, the emoji 🚀 becomes %F0%9F%9A%80.
URL encoding (also called percent-encoding) replaces unsafe ASCII characters with a "%" followed by two hexadecimal digits. This tool encodes text using encodeURIComponent, making it safe for use in URL query parameters, path segments, and form data. It handles Unicode characters correctly by first encoding to UTF-8.