What is URL encoding?
URLs can only contain a limited ASCII character set. Any character outside this set — spaces, accented letters, emoji, reserved delimiters used in a data position — must be percent-encoded: replaced with a % followed by two hex digits representing the UTF-8 byte. A space becomes %20, é becomes %C3%A9, and 🚀 becomes %F0%9F%9A%80.
Component vs full URI
Component mode (encodeURIComponent) escapes everything except unreserved letters, digits, and -_.!~*'(). Use it for a single query-string value, path segment, or form field — any place where the value itself must not contain delimiters. Full URI mode (encodeURI) preserves URL structural characters like : / ? # & = and is intended for an entire URL, not a piece of one. If in doubt, use Component mode.
Form-encoded spaces
HTML form submissions use the application/x-www-form-urlencoded media type, which encodes spaces as + instead of %20. When building a URL in code, stick to %20 — the + form is legal only inside query strings and form bodies. This tool offers a dedicated Form mode for the + variant.
