URL Encoder & Decoder
Percent-encode or decode URLs, query strings, and path segments. Choose between encodeURI and encodeURIComponent. Runs in your browser.
How to use
- 1Pick a direction
Encode plain text → percent-encoded, or decode percent-encoded text back.
- 2Pick a mode
encodeURI for whole URLs. encodeURIComponent for query values, path segments, or form fields.
- 3Paste and read the result
Live update. Copy the result or share the URL.
Examples
hello world & friends
hello%20world%20%26%20friends
https://example.com/search?q=café latte
https://example.com/search?q=caf%C3%A9%20latte
user%40example.com%3F%22quoted%22
user@example.com?"quoted"
Frequently asked
encodeURI leaves URL syntax characters (: / ? # & = +) alone, so it is used to encode a whole URL. encodeURIComponent percent-encodes those too, so it is safe for query values, path segments, and form fields.
Use encodeURIComponent for anything you paste into a URL query, form field, or path segment. Use encodeURI only when you have an entire URL and just want to escape spaces or unicode.
The input contains a "%" not followed by two hex characters, which the JavaScript decoder cannot handle. Look for standalone % signs in your input.
Related tools
- Base64 Encode / DecodeEncode or decode Base64 text. UTF-8 safe by default. Optional URL-safe variant.
- SlugifyConvert titles into clean URL slugs. Handles Unicode, strips diacritics, and let
- Query String ↔ JSONConvert URL query strings to JSON and JSON back to a query string. Handles repea
- URL ParserBreak any URL into its protocol, host, port, path, query parameters, and hash. U
- Base32 Encoder / DecoderEncode any text to RFC 4648 Base32 (A-Z, 2-7) or decode Base32 back to text. UTF
- Data URI Encoder / DecoderEncode text or any file into a data: URI for inlining in HTML, CSS, or JSON. Dec