URL Encode and Decode: Free Online Tool

Use this url encode and decode tool to make text safe for links and query strings. Paste text to percent-encode spaces and symbols, or paste an encoded URL like %20 and %3D to decode it. It helps with tracking links and API testing.

URL Encoder / Decoder

Percent-encoding for links and query strings.

Component mode (the default) encodes every reserved character and is right for a single query value or path segment. Full URL mode leaves the characters that give a URL its structure (: / ? # = and others) and only encodes spaces, accents and other unsafe characters.
Everything runs in your browser. Nothing you enter or upload is sent to a server.

How to use the URL encoder and decoder

  1. Paste the text or URL to convert.
  2. Press Encode to make it URL-safe, or Decode to turn %20-style codes back into text.
  3. Tick Full URL mode to encode a whole link without breaking it, or Use + for spaces for HTML form data.
  4. If the result is a valid URL, its protocol, host, path and query parameters are listed below.

How it works

URLs may only contain a limited set of ASCII characters. Percent-encoding converts every other character to its UTF-8 bytes, each written as % and two hex digits, so a space becomes %20 and รฉ becomes %C3%A9. Decoding reverses it. The tool uses the browser’s standard encodeURIComponent, encodeURI and decodeURIComponent functions.

Example

"hello world & you" encodes to hello%20world%20%26%20you in component mode, and to hello+world+%26+you with + for spaces.

Frequently asked questions

What is URL encoding?

It is a way of writing characters that are not allowed in URLs, such as spaces or accents, as % followed by hex codes.

What is %20?

A space. %2F is a slash, %3F a question mark and %26 an ampersand.

Should spaces be %20 or +?

In URL paths use %20. In query strings sent by HTML forms, + is also used for spaces.

Why does decoding fail?

A % sign must be followed by two hex digits. A lone % in the text is not valid encoding.

See also: Base64 Encoder, JSON Formatter.

Encode or decode a URL

How to use it

  1. Paste your text or URL.
  2. Pick encode or decode.
  3. Read the result.
  4. Copy it.

More questions

Why are spaces %20?

URLs can't hold spaces, so they get encoded.

Should I encode the whole URL?

Usually you just encode the query values, not the whole URL.

Is my text uploaded?

No. Everything stays in your browser on your device.

Related tools: HTML Entity Encoder and Decoder, Base64 Encode & Decode, Slug Generator.

Four steps to URL encode or decode: paste text or a URL, pick full URL or component mode, choose %20 or plus for spaces, copy
How to URL encode and decode.
URL encoding example: price & tax=10% off becomes price%20%26%20tax%3D10%25%20off, or uses plus signs for spaces
Worked example from the tool code.