Online toolTools

URL Encode & Decode

A free online URL encoder and decoder that converts as you type: enter text or an address to percent-encode it, or paste %XX text to decode it. It supports encodeURIComponent and encodeURI modes and + for spaces, keeps your last 10 entries in the browser and never sends your input to a server.

Options

0 chars · 0 bytes

0 chars · 0 bytes

No button to press: it converts as you type. Type in either box and the other one follows.

Recent history

    No history yet. It fills up automatically as you type.

    The last 10 entries are kept only in this browser (localStorage) and never sent to a server. Click one to load it again.

    What is URL encoding (percent-encoding)?

    A URL may only contain letters, digits and a few symbols as they are. Anything else, such as spaces, non-ASCII letters, &, = or ?, is converted to UTF-8 bytes and each byte is written as %XX. This is called URL encoding or percent-encoding. For example, é becomes %C3%A9 and a space becomes %20.

    Use the encodeURIComponent mode for one query-string value, since it also escapes & and =. Use the encodeURI mode for a complete address, since it keeps separators such as : / ? & = intact.

    Everything runs in your browser. The URLs and values you type are not sent to a server.

    Frequently asked questions

    What is the difference between encodeURI and encodeURIComponent?

    encodeURI is meant for a whole address, so it leaves separators such as : / ? # & = alone. encodeURIComponent is meant for a single query value, so it escapes those separators as well. For building a parameter value, encodeURIComponent is the safe choice.

    Should a space be %20 or +?

    Both exist. URL paths and plain percent-encoding use %20, while HTML forms sent as application/x-www-form-urlencoded use +. Turn on the 'Spaces as +' option to encode and decode the form style.

    Why does one non-English character turn into several %XX groups?

    Because the character is first converted to UTF-8, where it takes two to four bytes, and every byte is written as its own %XX group. Decoding restores the original character.

    Is the URL I enter sent to a server?

    No. Encoding and decoding happen in JavaScript in your browser.

    Type to search

    ↑↓ moveEnter openEsc close