How to Use the Punycode Converter
Choose Encode or Decode Mode
Select the conversion direction based on your needs. Punycode is a way to represent Unicode characters in ASCII-compatible format:
Example: When to Use Each Mode
Encode Example:
Input: münchen.de
Output: xn--mnchen-3ya.de
Decode Example:
Input: xn--caf-dma.fr
Output: café.fr
Enter Your Domain Names
Type or paste your domain names into the input area. The tool supports various international characters and formats used in global DNS systems:
Example: International Domain Names
Various examples of international domains you can convert:
münchen.de 日本語.jp кремль.ru пример.рф café.fr niño.es bücher.com
View and Use Converted Results
The output refreshes a moment after you stop typing, one result per input line:
Example: Conversion Results
See how international domains are converted to Punycode:
münchen.dexn--mnchen-3ya.de日本語.jpxn--wgv71a119e.jpпример.рфxn--e1afmkfd.xn--p1aiNote: The "xn--" prefix marks a label as Punycode. DNS only ever sees this form; browsers show the readable version in the address bar unless a name mixes scripts in a way that looks like a spoofing attempt.
Frequently Asked Questions
What is Punycode and why do I need it?
DNS only works with the letters a-z, the digits 0-9 and the hyphen. Punycode (RFC 3492) is the trick that lets a name like münchen.de or 日本語.jp live inside that limit: each label with other characters is rewritten as plain ASCII and given an xn-- prefix. You need the xn-- form whenever a tool talks to DNS directly, for example in zone files, server certificates, nginx or Apache config, firewall rules and many API fields.
How does Punycode encoding work?
The name is split at the dots and every label is handled on its own. Labels that are already plain ASCII stay as they are. In the others, the ASCII letters are kept at the front and the remaining characters are packed into a short code after the last hyphen, so münchen becomes xn--mnchen-3ya. Decoding runs the same steps backwards, and the page checks that a decoded label re-encodes to exactly the text you pasted.
Why does another converter give me a different result?
There are three rule sets around. This page follows UTS-46 the way current browsers do: letters are lowercased, ß and the Greek final ς are kept (faß.de becomes xn--fa-hia.de), and emoji are allowed. Older IDNA2003 tools, including Python's built-in "idna" codec, turn ß into ss and give fass.de instead. Strict IDNA2008 libraries refuse emoji and a few symbols completely. When one of those cases comes up, a note under the output tells you.
Can I paste URLs or e-mail addresses?
Yes. In a URL only the host name is converted; the scheme, user name, port, path, query and fragment stay exactly as typed. In an e-mail address only the part after the @ is converted. The mailbox name before the @ is never written in Punycode, so a non-ASCII name there needs a mail server that supports SMTPUTF8.
Why is a line marked as not converted?
The page flags names that DNS or a browser would refuse instead of passing them on: an empty label (two dots in a row), a label longer than 63 characters once encoded, a full name longer than 253 characters, spaces or characters such as < or ! that cannot appear in a host name, and xn-- labels that are not valid Punycode. The message names the line and the reason, the line is copied to the output unchanged, and every other line is still converted.
Is Punycode the same as URL encoding?
No. Punycode is only for the host name and keeps it readable as ASCII letters and digits. URL encoding, also called percent-encoding, is for the path and query string and writes each byte as % followed by two hex digits. A browser uses both in the same address: xn-- for the domain and %C3%BC style escapes for the rest.
Are my domain names sent anywhere?
No. The conversion runs in your browser, so the list you paste or upload is not sent to a server and nothing is kept. Reload the page and the editor starts empty.
The encoding itself is defined in RFC 3492, and the browser rules for mapping a name before it is encoded are in Unicode UTS #46. For the path and query part of a link, use the URL Encoder or the URL Decoder.
Related Tools
HTML Entity Encoder
Encode and decode HTML entities online, convert special characters to HTML entities and vice versa
HTML Entity Decoder
Decode HTML entities back to plain text online. Convert &lt;, &gt;, &amp; and other HTML entities to their original characters
Unicode Escape
Escape Unicode characters to \uXXXX notation for use in source code and JSON strings
Unicode Unescape
Convert \uXXXX Unicode escape sequences back to readable characters
ES5 to ES6+ Converter
Modernize ES5 code to ES6+ with arrow functions and modern syntax
CSS to JSX Converter
Convert CSS rules to React inline style objects