URL Encoder/Decoder
Encode or decode a URL or query value - free, no signup.
/ and & -
use it for a single query value. Full URI leaves URL-structural
characters alone - use it for an entire address.
What this tool does
Type or paste your text, choose Encode or Decode, and pick a scope: Component escapes every special character including / and & (use it for one query parameter's value), while Full URI leaves URL-structural characters like :, / and ? alone (use it for an entire address). Picking the wrong scope is the most common URL-encoding mistake, so this tool makes the choice explicit instead of guessing.
Encodes text for safe use in a URL, or decodes a percent-encoded string back to readable text.
Offers both encodeURIComponent-equivalent (component) and encodeURI-equivalent (full URI) modes, since they escape different sets of characters and mixing them up breaks URLs.
Reports a malformed percent-encoding (like a stray % not followed by two hex digits) instead of failing silently.
Encodes spaces as %20, matching the URI percent-encoding standard rather than the + used by HTML form submissions - the two are not interchangeable.
Leaves a small set of characters unescaped in Component mode ( ! ~ * ' ( ) and the standard unreserved letters, digits, - _ . ), matching the JavaScript spec exactly rather than an approximation.
How to use it
- Paste or type your text.
- Choose Encode or Decode.
- Pick Component for a single query value, or Full URI for an entire address.
Why use this tool
Spaces, symbols and non-English letters must be percent-encoded to travel in a URL, and the right amount of encoding depends on whether you are encoding a value or a whole address.
Why we built it
We built the URL encoder and decoder to make the component-versus-full-URI choice explicit, the commonest URL-encoding mistake. Break a link into parts with the URL parser and build tracking links with the UTM builder.
If your task goes further, try the HTML Entity Encoder/Decoder, the Base64 Encoder/Decoder and the Regex Tester.
Who this tool is for
- Web developers building query strings
- SEO and marketing staff reading tracking URLs
- Anyone fixing a broken link with odd characters
When to use it
- Building query strings and links.
- Reading a percent-encoded URL.
- Debugging redirects and API calls.
- Preparing text for a URL parameter.
Component vs full URI: the mistake this avoids
Two different encoding functions exist because they answer two different questions.
Component encoding escapes everything that isn't a safe URL character - including /, &, ? and = - because a single value going into a query string must not accidentally introduce a new parameter or break the URL's structure. Full URI encoding is deliberately less aggressive: it leaves /, ?, & and : alone because those characters are meant to structure the URL, and escaping them would break a link rather than fix it.
Using component encoding on an entire URL turns https://example.com/path?a=1 into an unreadable, non-functional string, because it escapes the very characters that make it a URL. Using full-URI encoding on a single query value that itself contains an & or = can corrupt the query string. This tool makes the choice explicit rather than leaving you to guess which JavaScript function to reach for.
Why %20 and + both mean "space" - but aren't interchangeable
A second common mix-up, separate from the component-vs-full-URI one above.
This tool follows the URI percent-encoding standard, where a space becomes %20 - that's what encodeURIComponent and encodeURI both produce, and what you'll see in a path or a manually built query string. HTML forms use a different, older convention for their application/x-www-form-urlencoded body: a space becomes a literal + sign, and a literal + has to itself be escaped to %2B to avoid ambiguity. If you're debugging a query string that came from a submitted form and see + where you expected %20, that's why - it's a different encoding convention, not a bug in either tool.
What you give it, and what you get back
| Item | Details |
|---|---|
| Input | Text or a percent-encoded string. |
| Mode | Component or full URI. |
| Output | The encoded or decoded text. |
Issues you may run into
| What you see | Why it happens | What to do |
|---|---|---|
| Slashes are encoded when they should not be | Component mode encodes them. | Use full URI mode for whole URLs. |
| Decoding errors | A malformed % sequence. | Fix or remove the broken escape. |
| Plus signs | Forms use + for spaces; percent-encoding uses %20. | Check which your server expects. |
Assumptions and limitations
- This encodes and decodes text using the standard percent-encoding scheme; it doesn't validate that the result is a well-formed URL overall.
- Decoding a string that contains a malformed percent-escape sequence is reported as an error, not guessed at.
Frequently asked questions
How do I URL-encode text online for free?
Paste or type your text, select Encode, choose Component or Full URI depending on what you're encoding, and the result appears instantly.
What is the difference between Component and Full URI encoding?
Component encoding escapes everything including / and &, so it's right for a single value going into a query string. Full URI encoding leaves URL-structural characters like /, ?, & and : alone, so it's right for encoding an entire web address.
Why did encoding my whole URL break it?
You likely used component-style encoding, which escapes the slashes and colons that make a URL work. Switch to Full URI mode for an entire address.
What happens if I try to decode invalid input?
The tool reports it as a malformed percent-encoding rather than guessing at a result, since a silently wrong decode is worse than a clear error.
Is my text uploaded anywhere?
No. Encoding and decoding happen entirely in your browser - nothing is sent to a server, and closing the tab clears it.
Why do I see + instead of %20 for spaces in some URLs?
That's a different encoding convention used by HTML form submissions (application/x-www-form-urlencoded), not the URI standard this tool follows. Both mean "space", but they aren't interchangeable - a literal + in that format has to be escaped to %2B.
Does this tool use the browser's real encodeURIComponent function?
Yes - Component and Full URI modes call JavaScript's native encodeURIComponent/decodeURIComponent and encodeURI/decodeURI directly, so results match exactly what your browser or a Node.js backend would produce.