Punycode Converter
FreeConvert text between Unicode and Punycode (RFC 3492), the ASCII-only encoding used for internationalized domain names, with a full domain mode (dot-aware, xn-- prefix handled automatically) and a plain label mode, batch-converting multiple lines at once.
Runs entirely in your browser. Nothing is uploaded anywhere.
Recent Activity
Visible to everyone. Last 20 uses across all visitors, newest first.
Converted 1 line(s) (domain, to Unicode)
3 hours ago
Converted 1 line(s) (domain, to Punycode)
3 hours ago
Converted 1 line(s) (domain, to Punycode)
3 hours ago
Converted 1 line(s) (domain, to Unicode)
3 hours ago
Converted 1 line(s) (domain, to Unicode)
3 hours ago
Converted 1 line(s) (domain, to Punycode)
3 hours ago
Converted 1 line(s) (plain text label, to Punycode)
3 hours ago
Converted 2 line(s) (plain text label, to Punycode)
3 hours ago
Converted 2 line(s) (domain, to Unicode)
3 hours ago
Converted 2 line(s) (domain, to Punycode)
3 hours ago
Converted 2 line(s) (domain, to Punycode)
3 hours ago
What this tool does
This tool converts text between Unicode and Punycode, the ASCII-only encoding used for internationalized domain names. Paste one or more domains or words, pick a direction, and get an instant, line-by-line conversion, in either full domain mode (dot-aware, with the xn-- prefix handled automatically) or plain label mode for raw encoded or decoded strings.
How It Works
Punycode implements the Bootstring algorithm from RFC 3492: it separates the ASCII characters already in a string from the non-ASCII ones, writes the ASCII part first followed by a hyphen, then encodes the positions and code points of every non-ASCII character as a sequence of generalized variable-length integers using the letters a-z and digits 0-9. In domain mode, each dot-separated label is encoded or decoded independently and the xn-- prefix is added or stripped automatically, matching exactly how a real internationalized domain name is stored in the DNS versus how a browser displays it.
Problems it solves
- Finding the real ASCII (xn--) form of an internationalized domain to put into DNS records, email headers, or server configuration.
- Decoding a mysterious xn-- domain seen in a log file, certificate, or email back into readable Unicode.
- Converting a whole list of domains at once instead of one at a time.
- Checking the raw Punycode encoding of an individual word for debugging or learning purposes.
Frequently asked questions
›What is Punycode actually for?
Domain names can only officially contain ASCII letters, digits, and hyphens, but people need domains in every script and language. Punycode is the encoding (defined in RFC 3492) that represents any Unicode text as an ASCII string prefixed with xn--, so a domain like münchen.de becomes xn--mnchen-3ya.de under the hood while browsers still display the Unicode version to users.
›What is the difference between "Domain name" and "Plain text label" mode?
Domain name mode matches what actually happens on the internet: it splits on dots, leaves plain ASCII labels alone, and adds or removes the xn-- prefix only on labels that need it, so a full hostname like café.example.com converts correctly label by label. Plain text label mode runs the raw Punycode algorithm on the exact string you give it with no dot-splitting and no xn-- prefix, useful if you already have a bare encoded label from another tool or an RFC 3492 test vector.
›Why does converting back to Unicode sometimes fail?
Punycode decoding only succeeds on a well-formed encoded string; a line that is not valid Punycode, or a domain mode line whose label does not actually start with xn--, cannot be decoded and that line is reported as an error while the rest of the input still converts normally.
›Can I convert more than one domain or word at a time?
Yes, put each domain or label on its own line; the output textarea mirrors the input line by line, so line 3 of the output is always the conversion of line 3 of the input.
›Is this the same algorithm real browsers use?
Yes, this tool uses the widely used punycode.js library (the modern successor to the Punycode implementation that shipped in Node.js itself for years), implementing the Bootstring algorithm from RFC 3492 exactly, the same specification every major browser follows when it shows a Unicode domain in the address bar.
Related Tools
Text
MySQL Syntax Validator
Validates MySQL syntax for one or more semicolon-separated statements, reporting the exact line and column of the first error found.
FreeText
Online HTML Editor
Edit HTML, CSS, and JavaScript in three panels with a live sandboxed preview that updates as you type, plus a one-click download as a standalone HTML file.
FreeText
Password Generator
Generate strong, random passwords right in your browser using a cryptographically secure generator, with a live strength meter, entropy calculation, and support for batches of several passwords at once.
FreeText
Line Counter
An advanced line counter that instantly analyzes your pasted text: duplicate/empty line detection, comment line filtering, regex-powered find & replace, sorting, and prefix/suffix insertion.
FreeText
List Randomizer
Shuffle any list, pick random winners for giveaways, and split entries into even groups, all in your browser with an unbiased Fisher-Yates shuffle.
FreeText
Acronym Generator
Turn a phrase into its acronym instantly, with a letter-by-letter breakdown and an optional minor-word-skipping mode.
FreeText
Add Line Breaks
Add line breaks after each delimiter, every N characters (word-wrapped or exact), or every N words, with a live line count.
FreeText
Add Prefix And Suffix
Add the same prefix and/or suffix text to every line of a list, right in your browser.
Comments (0)
Found this tool useful? Leave a comment, share a tip, or tell us how we can make it better.
No comments yet. Be the first to share your thoughts!