URL Encode
URL-encode or decode Japanese text and symbols. Switch between component and whole-URL modes.
About this tool
URLs allow only certain characters β text like Japanese, spaces, and symbols such as &, ?, and # cannot go in as-is. URL encoding converts these into the %XX form (percent-encoding); decoding turns %XX back into the original characters. This tool does both directions in your browser and never sends your input anywhere.
When do you need it?
- Putting a value into a query string (e.g. a search term containing & or =).
- Handling URLs that contain non-ASCII text (sharing links, specifying a redirect target).
- Building form submission data.
Forget to encode, and a & or = inside a value can be mistaken for a parameter separator and reach the server in an unintended shape.
encodeURI vs. encodeURIComponent
These two are often confused in code. encodeURI targets a "whole URL" and leaves separators like : / ? & = intact. encodeURIComponent targets "a single value (a parameter's contents)" and encodes separators too. To insert a query value, use encodeURIComponent by default. Running encodeURI over the whole thing can leave a & inside a value unencoded, colliding with the separators.
Double-encoding and the space trap
- Double-encoding β encoding an already-encoded string turns % into %25, producing a doubled state like "%2520". Check whether the source is already encoded before converting.
- Spaces β in the path portion a space is %20, while older form submission (application/x-www-form-urlencoded) may use +. The handling differs by context.
How to use
- Choose "Encode" and type text to convert it to a URL-encoded string.
- Switch between parameter mode (escapes delimiters) and whole-URL mode.
- Choose "Decode" to turn %XX sequences back into the original text.
FAQ
What is the difference between encodeURI and encodeURIComponent?
encodeURI targets a whole URL and keeps delimiters like : / ? &, while encodeURIComponent targets a query value and escapes those delimiters too. Use the latter for parameter values.
Is my input sent anywhere?
No. Encoding and decoding happen entirely in your browser; your input is never sent to a server.
Does a space become %20 or +?
In percent-encoding a space is %20. The + form represents a space specifically in application/x-www-form-urlencoded (form submission); it depends on context.
How is non-English text converted?
It is turned into UTF-8 bytes, each shown as %XX. For example "γ" becomes %E3%81%82.
What happens if I re-encode an already-encoded string?
The % itself becomes %25, producing double-encoding. Check whether your input is raw or already encoded before converting.
When would I use this?
When including non-English text or symbols in search queries or tracking parameters, or when restoring a broken URL parameter into human-readable form.