How should this URL be encoded?
Paste one URL or many, or any text. Encode or decode it as a whole URL, as one component or as a form would send it, line by line or all at once, and see every part of a URL laid out, query parameters included. Greek domain names convert to and from Punycode below.
Greek domain names and Punycode
DNS holds a Greek name such as καφές.gr in an ASCII form that starts with xn--. Type names in Greek or in their xn-- form, one per line, and see both.
What it does
- Whole URL. Works like JavaScript's encodeURI: letters, digits, the characters - _ . ! ~ * ' ( ) and the ones that give a URL its shape (; / ? : @ & = + $ , #) stay as they are, and everything else is percent-encoded. Use it on a full address that has spaces or Greek letters in it.
- Component. Works like encodeURIComponent: only letters, digits and - _ . ! ~ * ' ( ) stay. Use it on one value that goes inside a URL, such as a UTM value or an address passed as a parameter.
- Form. The way a browser sends an HTML form, as the WHATWG URL Standard sets it out: a space becomes +, and only letters, digits and * - . _ stay. When decoding, + turns back into a space.
- The parts of a URL. The first full URL in the box is read with the same URL parser browsers use: scheme, host (in both forms when it is Greek), port, path, each query parameter decoded in a table, and the fragment.
- Punycode. Greek and other non-Latin domain names are converted as RFC 3492 and the WHATWG URL Standard describe, in both directions.
What it does not do
It does not open the URL. Everything happens in your browser, and nothing you paste is sent anywhere. To see where a link leads, use the redirect checker.
It does not guess which mode you need. The same text encodes differently in each mode. The box under the switches says what each one leaves alone.
It does not fix broken encoding. A % that is not followed by two hexadecimal digits, or bytes that are not valid UTF-8, are reported with their place, and that line is left as it was.
Questions
Should a space be %20 or +?
Both mean a space in the query of a URL sent by a form, and + only means a space there. In a path, or in any value you build yourself, %20 is the safe choice: use Component.
What does %2520 mean?
The text was encoded twice: %20 became %2520 when its % was encoded again as %25. The page says so when it sees it. Decode once more, then fix the tool that encodes it twice.
Can I use Greek letters in a URL?
Browsers show them, but they send the path and query percent-encoded and the domain in its xn-- form, as the WHATWG URL Standard sets out. That encoded form is plain ASCII, so it is the one to paste into tools that may not encode a link for you.
Why does καφές.gr end in a different xn-- name from καφεσ.gr?
The final ς and σ are different letters, and the WHATWG URL Standard keeps ς as it is, so the two are different domain names. Capital letters are made small first, and a capital Σ becomes σ.