URL Encoder & Decoder

Type in either box and the other updates instantly. Handles broken % sequences, double encoding and legacy Shift_JIS URLs.

Features

  • Two linked boxes, Text and Encoded: type in either one and the other updates instantly
  • Three modes: Component (encodeURIComponent), Full URL (encodeURI) and Form (spaces as +), plus an option to encode only non-ASCII characters
  • Never fails on broken input such as %E3%81, %ZZ or a lone %: decodes what it can and shows where and why the rest is broken
  • Detects double encoding (%2520) and decodes it again with one click
  • Encodes and decodes legacy Shift_JIS, EUC-JP and GBK URLs as well as UTF-8
  • Breaks a URL into scheme, host, path and query, shows Punycode for international domains, and rebuilds the URL as you edit the query table

Use cases

Reading analytics URLs

Find out what a search term like caf%C3%A9 actually says.

Building API requests

Encode a query value exactly like encodeURIComponent before pasting it into code.

Garbled legacy URLs

Switch to Shift_JIS or GBK to read old Japanese or Chinese URLs.

Cleaning up links

Inspect a long URL's query in a table, remove tracking parameters and rebuild it.

Privacy

Text and URLs are converted only in your browser and are never sent anywhere. Only your mode and encoding settings are kept on this device (browser storage) for next time; what you type is not saved.

FAQ

Why are URLs percent-encoded?

Only letters, digits and a few symbols are allowed in a URL. Other characters are converted to UTF-8 bytes, and each byte is written as % followed by two hex digits. For example, é is the two bytes C3 A9, so it becomes %C3%A9.

What is the difference between Component and Full URL?

Component (encodeURIComponent) also encodes & = / ? #, so use it for a value that goes inside a URL, such as a query value. Full URL (encodeURI) keeps those separators, so use it to encode a whole URL. If a value contains &, Full URL cannot tell it apart from a separator.

Should a space be %20 or +?

Both exist. HTML forms (application/x-www-form-urlencoded) write spaces as +, while everywhere else uses %20. When decoding, + means a space only in form data. If in doubt, %20 is the safe choice.

Why do I get garbled text (mojibake) when decoding?

Older Japanese sites often encoded URLs in Shift_JIS or EUC-JP, and older Chinese sites in GBK, instead of UTF-8. Decoding those bytes as UTF-8 fails or produces garbage. Switch the character encoding to read them; parts that are not valid UTF-8 are listed with their position.

What does %2520 mean?

It is double-encoded. Encoding the space %20 a second time turns % into %25, giving %2520. The tool points this out, and Decode again restores the original.

Is anything I enter sent to a server?

No. All conversion happens in your browser, so URLs containing tokens never leave your device.

Related tools

Mode

For a query value or part of a path. Also encodes & = / ? # (same as encodeURIComponent).

Old Japanese and Chinese sites may use Shift_JIS, EUC-JP or GBK. If the result looks garbled, try another encoding.

Encoded characters

    No characters need encoding.

    Everything runs in this browser. The text and URLs you enter are never sent anywhere.

    Bytes of the selected character

    Shows the character at the cursor in the Text box.

    Enter some text to see the bytes of each character here.

    URL breakdown

    Enter a URL to see its scheme, host, path, query and fragment.