Developer

URL Encoder / Decoder

Safely encode or decode URL components in your browser.

Tool workspace
Loading URL Encoder / Decoder…

About URL Encoder / Decoder

URL Encoder / Decoder percent-encodes text for an individual URL component or decodes a percent-encoded value. It is useful when a query parameter or path segment contains spaces, punctuation or non-ASCII text that needs an unambiguous representation. Choose the direction and paste the value; the output updates automatically.

This tool uses component encoding, not whole-URL normalization. If you paste an entire URL into Encode URL component, structural characters such as slashes and colons will also be encoded. Usually you want to encode a parameter value before adding it to a URL, or decode one value taken from a URL. Copy the output only after checking how the receiving application expects the component to be represented.

How to use URL Encoder / Decoder

  1. Choose a direction

    Select Encode URL component or Decode URL component.

  2. Paste one value

    Enter text in Text or URL component, or use Encoded value in decode mode.

  3. Check the output

    Review the automatic result. Incomplete or malformed percent escapes produce an error.

  4. Copy or clear

    Select Copy output, or Clear to remove the entered value.

Example: A query parameter value

Encoding this text makes the spaces and ampersand part of the value rather than URL separators.

Input

hello world & more

Output

hello%20world%20%26%20more

How it works

Encode mode calls encodeURIComponent, which turns characters that are not safe in a URL component into percent escapes representing UTF-8 bytes. A space becomes %20 and an ampersand becomes %26, so it can remain inside a parameter value rather than acting as a separator between parameters. Some punctuation is allowed through unchanged by the browser function; this is the standard component-encoding behavior, not a custom alphabet.

Decode mode calls decodeURIComponent to reverse valid percent escapes. It reports an error if the escapes are incomplete or cannot be interpreted as valid encoded text. A plus sign is left as a literal +; this function does not apply the form-encoding convention that uses + for a space. Encoding an already encoded value can encode its percent signs again, so choose the direction that matches the current representation and avoid repeated transformations unless the surrounding format requires them.

When is this useful?

  • Prepare text for one query parameter.
  • Read a percent-encoded value from a log.
  • Check whether a URL component was encoded twice.

Things to know

  • Encoding an entire URL also encodes its structural separators.
  • Decode mode does not turn + into a space.
  • Encoding is not validation of a URL’s destination or safety.

Privacy & processing

The browser’s URI component functions transform the pasted value locally. The tool does not navigate to or request the URL you enter, and it does not submit the text to a ToolMyth processing API.

Frequently asked questions

Should I encode the entire URL?

Usually encode the individual value that will be placed in a query or path. This tool encodes structural characters in a complete URL too.

Why is + still + after decoding?

decodeURIComponent treats it literally. This tool does not perform form-style plus-to-space conversion.

Why does an encoded percent sign become %25?

A percent sign is itself encoded. Re-encoding a value such as %20 produces %2520, which indicates another encoding layer.

Does the tool open the URL?

No. It transforms text without requesting or visiting the address.