IDN Punycode Converter

Easily convert internationalized domain names (IDN) to Punycode and back. Our free tool helps you encode or decode Unicode domains for full DNS compatibility

IDN Unicode text:

Example: 京

ASCII Punycode string:

Example: xn--1lq

An IDN Punycode converter translates internationalized domain names (IDNs), domains with characters outside A–Z such as münchen.de or 例え.jp, into the ASCII form DNS actually uses, and back again. The ASCII form starts each converted label with xn--: münchen.de becomes xn--mnchen-3ya.de. Conversion happens in your browser.

How to convert a domain

  1. To get the ASCII form, enter the domain in IDN Unicode text and click Convert to ASCII Punycode.
  2. To read an xn-- domain, enter it in ASCII Punycode string and click Convert to IDN Unicode.

Each label (the parts between dots) is converted separately; labels that are already plain ASCII are left as they are. Letters are converted to lowercase first, because domain names are case-insensitive.

Why Punycode exists

DNS was designed for ASCII letters, digits and hyphens. Rather than change every DNS server, IDNs are stored as Punycode (defined in RFC 3492) and browsers convert them for display. You need the xn-- form when you:

  • create DNS records or server configuration (web server names, TLS certificates, mail settings) for an IDN;
  • look up an IDN with command-line tools or the DNS Lookup and WHOIS Lookup, which convert names automatically;
  • read logs, certificates or email headers, where IDNs appear in their xn-- form.

Punycode and phishing

Some characters from other scripts look identical to Latin letters, so a domain can imitate a well-known brand: Cyrillic а looks like Latin a. Converting a suspicious domain to Punycode exposes the trick, because an all-Latin domain has no xn-- labels. Browsers show the Punycode form in the address bar when they detect mixed scripts for the same reason.

Frequently asked questions

What does xn-- mean in a domain name?

It marks a label that contains Punycode, the ASCII encoding of a name with non-ASCII characters. Decode it here to see the original characters.

Is Punycode the same as URL encoding?

No. Punycode is used only for domain names. The path and query parts of a URL use percent-encoding instead, so a URL with non-ASCII characters can use both.

Can I register any Unicode domain?

Each registry decides which scripts and characters it accepts, and IDNA rules exclude symbols such as most emoji. A name that converts here may still be refused by the registry.