URL Encoder / Decoder Online
Convert special characters in a URL to percent-encoded sequences (%XX) and back. Encode query parameters or decode unreadable URLs. Free, no sign-up.
Examples
🔒 Your data never leaves your browser
100% secure
Your files are never shared
Ultra-fast
Processing in seconds
Privacy
Automatic deletion after 1h
How to encode and decode URLs
Paste your URL or text
Enter the URL or text you want to encode or decode in the input panel.
Choose your encoding
Click "Encode" for component encoding, "Full Encode" for full URL encoding, or "Decode" to decode a percent-encoded string. Toggle real-time mode for instant results.
Copy the result
The encoded or decoded result appears in the output panel. Click "Copy" to copy it, or "Swap" to use the output as the new input.
Why URL encoding exists
URLs can only contain a limited set of ASCII characters. RFC 3986 defines unreserved characters (A-Z, a-z, 0-9, -, _, ., ~) that can appear as-is in URLs. All other characters must be percent-encoded to avoid ambiguity.
Without encoding, characters like & and = would be confused with URL structure (query parameter separators). Spaces, non-ASCII characters, and special symbols must all be encoded to create valid URLs.
Reserved vs unreserved characters
Reserved characters (:, /, ?, #, [, ], @, !, $, &, ', (, ), *, +, ,, ;, =) have special meaning in URLs. They should only be encoded when used outside their reserved purpose — for instance, a / in a query parameter value must be encoded as %2F.
Unreserved characters (letters, digits, -, _, ., ~) never need encoding. Encoding them is valid but unnecessary and makes URLs longer.
encodeURI vs encodeURIComponent
Use encodeURI() when encoding a complete URL — it preserves ://, ?, #, & and other structural characters. Example: encodeURI('https://example.com/path?q=hello world') gives 'https://example.com/path?q=hello%20world'.
Use encodeURIComponent() when encoding a single parameter value — it encodes everything including & and =. Example: encodeURIComponent('price=10&tax=2') gives 'price%3D10%26tax%3D2'. This is what you need for form data and API parameters.
Common pitfalls
Double encoding is the most common mistake: encoding an already-encoded URL turns %20 into %2520. Always check if your input is already encoded before encoding it again.
The + sign is another source of confusion. In query strings (application/x-www-form-urlencoded), + means space. But in the path component of a URL, + is literal. decodeURIComponent does NOT decode + as space — you need to replace + with %20 first if dealing with form data.
URL Encoder / Decoder Online — Frequently asked questions
What is URL encoding?
URL encoding (percent-encoding) replaces special and non-ASCII characters with sequences starting with %. For example, a space becomes %20, "é" becomes %C3%A9. This is necessary because URLs can only contain certain ASCII characters.
What is the difference between encodeURI and encodeURIComponent?
encodeURI encodes a complete URL while preserving structural characters (://?#&=). encodeURIComponent encodes an individual component (parameter value) by encoding ALL special characters, including &, = and /. Use encodeURIComponent for parameter values and encodeURI for full URLs.
Why do spaces become %20 or +?
In the URL standard (RFC 3986), a space is encoded as %20. In HTML forms (application/x-www-form-urlencoded), a space becomes +. Both are common and most servers accept both.
Is my data sent to a server?
No. Encoding and decoding happen entirely in your browser.
Does the tool handle Unicode characters?
Yes. Unicode characters are first converted to UTF-8, then each byte is percent-encoded. For example, "日" (3 bytes in UTF-8) becomes %E6%97%A5.
When do I need to encode a URL?
You need to encode when passing data in URL parameters (e.g., search terms, filenames), when building URLs dynamically in your code, or when embedding URLs within other URLs (e.g., redirects).
Similar tools
JSON Formatter
Format, validate and minify JSON online
Base64 Encode/Decode
Encode and decode text and images in Base64
Unix Timestamp Converter
Convert Unix timestamps to readable dates
Regex Tester
Test regular expressions in real-time
QR Code Generator
Generate QR codes from URLs, text and more
Password Generator
Generate strong, secure passwords