IDN Punycode Converter

Enter a domain name and pick a direction to convert to or from Punycode.

How it is calculated

A domain is split at the dots into labels, and each label is converted on its own. In the Unicode → ASCII direction a label containing non-ASCII characters is turned into Punycode and given the xn-- prefix, so only the ASCII letters, digits and hyphens that DNS accepts remain. Labels that are already plain ASCII are left as they are, and uppercase letters are lowercased by the standard IDNA (UTS 46) mapping. In the ASCII → Unicode direction every xn-- label is decoded back to its readable form. Punycode itself works by listing the plain ASCII characters first, then a hyphen, then encoded positions of the other characters. Input that cannot be converted gives no result. Type only the domain name; a pasted path such as /page is carried along unchanged and is not part of IDN processing.

Worked example

Take the domain münchen.de in the Unicode → ASCII direction. The label de is plain ASCII and stays. The label münchen contains ü, so it is encoded: the basic letters m, n, c, h, e, n form mnchen, then a hyphen, then the code 3ya that records ü and its position. With the prefix this gives xn--mnchen-3ya, so the full result is xn--mnchen-3ya.de. Running that string through the ASCII → Unicode direction returns münchen.de.

Try this example →

Common mistakes

  • Choosing the wrong direction. Pasting an xn-- domain with Unicode → ASCII selected leaves it unchanged, while pasting Unicode text with ASCII → Unicode selected also changes nothing useful.
  • Entering a whole URL with https:// and a path. Only the host name is converted, so enter just the domain.
  • Expecting the result to be registered or available. The tool only converts the spelling, and it does not look the domain up.
  • Assuming visually similar characters give the same domain. A Cyrillic letter that looks like a Latin one produces a different Punycode string, which is the basis of look-alike domains.

About this calculator

An internationalized domain name (IDN) lets domains use non-ASCII characters — accented Latin letters, Cyrillic, Arabic, Chinese and more — but the underlying Domain Name System only understands ASCII, so browsers and registries convert Unicode labels to and from ASCII using Punycode, an encoding defined in RFC 3492 and wrapped with the xn-- prefix under the ToASCII/ToUnicode rules of RFC 3490 (superseded by RFC 5891). For example, “münchen.de” becomes “xn--mnchen-3ya.de” in its ASCII-compatible form.

Domain registrars, browser address bars, and DNS resolvers rely on this conversion behind the scenes every time a non-Latin-script domain is registered or visited, and developers or domain buyers use converters like this one to check exactly what ASCII string a given Unicode domain resolves to (useful for spotting homograph look-alike domains) or to read a Punycode string back into its human-readable Unicode form.

Was this helpful?

You can pick up to 3 reactions.

Comments (1)

  • Editorial team

    This is a quick way to inspect a suspicious link. A domain written with a Cyrillic letter in place of the Latin a, for example in apple.com, converts to xn--pple-43d.com, while the genuine one stays plain ASCII. If the Unicode and ASCII forms look unrelated, or you see an unexpected xn-- label, treat the address with care. Have you run into a look-alike domain, and what gave it away?

Popular calculators

All Calculators