URL Encoder & Decoder
Percent-encode text for safe use in URLs and query strings, or decode %XX sequences back to readable text.
About This Tool & Technical Logic
URLs may only contain a limited ASCII set; everything else β spaces, accents, emoji, ampersands β must be percent-encoded as %XX byte sequences. Encoding a full URL vs. a single query value differs: structural characters like ? and & must survive in the former but be escaped in the latter.
Component mode (encodeURIComponent) escapes everything except unreserved characters, which is what you want for query parameter values. Full-URI mode preserves separators so you can paste a complete URL and clean up only its unsafe characters.
encodeURIComponent(s) for component mode; encodeURI(s) for full-URL mode; decodeURIComponent to reverse.
How to Use β Step by Step
- 1
Pick the mode and scope
Encoding a value that goes inside a URL? Component mode. Fixing up a whole URL? Keep structure mode.
- 2
Paste and convert
Spaces become %20 (never bare '+' β that's the legacy form-encoding convention, handled correctly here).
- 3
Copy the safe string
The result can be pasted into hrefs, API calls, or config files without fear of breakage.
Frequently Asked Questions
That's application/x-www-form-urlencoded (old form posts). Modern URLs use %20; decodeURIComponent handles both when '+' appears inside %2B-safe contexts.