---
title: "URL Encoder and Decoder with Query Parser | VulCode"
description: "Encode and decode URLs online: percent-encoding with encodeURIComponent, query parameters in a table and IDN domains as punycode. Nothing is uploaded."
url: "https://vulcode.com/en/tools/url-encoder-decoder"
lang: "en"
---

[Home](https://vulcode.com/en) [Resources](https://vulcode.com/en/resources) [Tools](https://vulcode.com/en/tools)

# URL encoder and decoder online

Encode and decode URLs online: percent-encoding with encodeURIComponent, query parameters in a table and IDN domains as punycode. Nothing is uploaded.

[Free quote](https://vulcode.com/en/quote) [Full pricing](https://vulcode.com/en/services/pricing)

Direction

Encode Decode

Method

Parameter value (encodeURIComponent) Whole URL (encodeURI) Form, space as + Strict RFC 3986

Method

Parameter value (decodeURIComponent) Whole URL (decodeURI) Form, + as a space

Text or URL to encode 85 characters

Type or paste some text.

## Encoded

99 characters

```
https://b%C3%BCcher.example/search?q=coffee%20and%20cake&city=Krak%C3%B3w&tag=new&tag=cheap#results
```

encodeURI writes the letters of a domain as %XX, while browsers and DNS use punycode. Take a URL with an IDN domain from the How a browser writes it line.

The result still has % sequences, so the text was most likely encoded twice.

Copy the result

Decode once more

## Every method at once

- Parameter value (encodeURIComponent) also encodes /? & = #
  Copy

- Whole URL (encodeURI) leaves /? & = # as they are
  Copy

- Form, space as + how an HTML form sends it
  Copy

- Strict RFC 3986 also encodes! ' ( ) *
  Copy

- How a browser writes it new URL().href, domain in punycode
  Copy

## URL parts

- Protocol
  Copy

- Domain
  Copy

- Port
  Copy

- Path decoded
  Copy

- Fragment after #
  Copy

## Query parameters

Copy as JSON

| Number | Key | Value |
| --- | --- | --- |

## IDN domain

- ASCII form (punycode) how DNS sees the domain
  Copy

- Form with native letters how people read the domain
  Copy

This domain cannot be converted to punycode. Check it for spaces or characters that are not allowed.

## How to use it in four steps

Step by step, with this page's example.

- Choose Encode or Decode. When you switch direction the result moves into the field, so checking both ways is easy.

- Pick a method. Parameter value is for what goes after the = sign, Whole URL is for a finished link.

- Paste the text or URL. You see the result of every method at once, with your pick highlighted.

- For a full URL, check its parts, the query parameters in the table and the punycode form of the domain.

What you enter

coffee & cake, method Parameter value

What you get

```
coffee%20%26%20cake
```

Without encoding, the & would split this value into two parameters.

## Questions

- **What is URL encoding?**: URL encoding (percent-encoding) replaces unsafe characters in a link with % and two hex digits, so a space becomes %20 and ü becomes %C3%BC. This tool encodes and decodes text four ways and splits a query string into parameters.
- **encodeURIComponent or encodeURI?**: encodeURIComponent for a single value, such as what you put after q=. It also encodes /? & = #, so the value cannot break the URL. encodeURI for a whole URL that already has those characters in place. A whole link run through encodeURIComponent starts with https%3A%2F%2F and stops working.
- **Is a space %20 or +?**: In a URL a space is %20. A plus means a space only in form data, the application/x-www-form-urlencoded format. That is why the Form decoding turns + into a space, while Parameter value leaves the plus alone.
- **Where do sequences like %C3%BC come from?**: They are UTF-8 bytes. The letter ü takes two bytes in UTF-8, C3 and BC, so it is written %C3%BC, and each byte in a URL is written as % and two hex digits.
- **What is punycode?**: A way to write a domain with native letters in plain ASCII, the only characters DNS understands. Such a domain starts with xn--, for example bücher.example becomes xn--bcher-kva.example. The browser usually shows the version with letters but sends the punycode.
- **What does the invalid UTF-8 error mean?**: The text was encoded in a charset other than UTF-8, often Windows-1252 or ISO-8859-1, where é is %E9. JavaScript functions expect UTF-8, so a URL like that has to be fixed in the system that produced it.
- **Does the text go to a server?**: No. Encoding, URL parsing and punycode all run in your browser with no network request, so you can paste a URL with a token or customer data in it.

## Related tools

The tool does one job. If the same thing should happen automatically in your bot, server or system, we build it.

- ### [Base64, JWT and hash](https://vulcode.com/en/tools/base64-jwt-and-hash)
  Encode and decode Base64 and get MD5, SHA-256 or SRI from text or a file. A bare JWT and URLs have their own tools.

- ### [JSON formatter and validator](https://vulcode.com/en/tools/json-formatter)
  Paste JSON and get it formatted, or the exact place of the error.

- ### [Meta tag generator with a Google preview](https://vulcode.com/en/tools/meta-tag-generator)
  A title and description with a Google result preview and their width in pixels, plus Open Graph, X, canonical and robots tags.

- ### [JWT decoder with expiry dates](https://vulcode.com/en/tools/jwt-decoder)
  The header and payload as JSON, exp, iat and nbf as dates with the time left, plus warnings. The signature is not verified.

- ### [Integrations and automation](https://vulcode.com/en/services/api-integrations)
  When links with parameters should be built and read automatically, in a store or payment integration for example.

## Tell us what you want to build.

A free quote comes back within an hour during working hours. You talk to the person who writes the code.

[Free quote](https://vulcode.com/en/quote) [Free consultation](https://vulcode.com/en/consultation)

- [hello@vulcode.com](mailto:hello@vulcode.com)

- [+48 576 043 920](tel:+48576043920)

- [discord.gg/vulcode](https://discord.gg/vulcode)
