Unicode to Punycode Converter
Encode Unicode text and internationalized domain names (IDNs) into Punycode (ACE-encoded), the ASCII-compatible format used by DNS.
Conversion Options
Disable this only if you're encoding a single string that isn't a domain name.
Recommended Settings
Pro Tips
- •Punycode labels always get the 'xn--' prefix so DNS resolvers and browsers know to decode them
- •Labels that are already plain ASCII are passed through unchanged, so you can safely paste a mixed domain like café.example.com
- •Enter multiple domains, one per line, to convert a whole list at once
- •Disable 'Treat as full domain' only when encoding a single Unicode string that isn't part of a hostname
- •This encoder implements the standard Punycode algorithm from RFC 3492, the same one browsers use for internationalized domains
Most Popular
Most users paste full domains with non-Latin characters and keep domain-splitting enabled
When to Use This Tool
Encode a domain name containing non-Latin characters, like münchen.de, into its ASCII-compatible Punycode form (xn--mnchen-3ya.de) for DNS registration or configuration.
Prepare Unicode hostnames for DNS zone files, web server configs, or certificate requests that require ASCII-only domain names.
Convert a desired non-Latin domain name into the Punycode form that registrars and WHOIS databases actually store.
Generate the ACE-encoded form of internationalized domains used in a multilingual site or app, for use in links, redirects, or configuration.
How It Works
Split the input into dot-separated labels (unless 'Treat as full domain' is disabled)
For each label containing non-ASCII characters, separate out the basic ASCII code points as the initial output, followed by a hyphen
Encode the remaining non-ASCII code points using the standard Punycode generalized variable-length integer algorithm (RFC 3492), inserting each one in the correct position
Prefix the encoded label with 'xn--' to mark it as Punycode, per the IDNA standard
Labels that are already pure ASCII are left unchanged
100% Private
Files never leave your device. All processing happens locally in your browser.
Lightning Fast
Powered by Pure JavaScript (RFC 3492 Punycode algorithm) for optimal performance on modern browsers.
Secure
No data collection, no tracking, no sign-up required.
Frequently Asked Questions
What is Punycode used for?
Punycode is a way to represent Unicode text using only the ASCII characters allowed in domain names. It's the basis of Internationalized Domain Names (IDNA), letting domains contain non-Latin scripts while remaining compatible with DNS infrastructure that only understands ASCII.
Why does the output start with xn--?
The xn-- prefix (an ASCII Compatible Encoding, or ACE, prefix) signals to DNS resolvers and browsers that the label that follows is Punycode-encoded and should be decoded back into Unicode text for display.
Can I encode a whole domain, not just one label?
Yes. With 'Treat as full domain' enabled, the input is split on dots and each label is encoded independently - so a domain like 例え.テスト encodes label by label into its full Punycode hostname.
What happens to labels that are already ASCII?
Any label that's already plain ASCII is passed through unchanged, so you can paste an entire mixed domain (like a Unicode subdomain under a plain .com) and only the non-ASCII parts will be encoded.
What if I paste something that's already Punycode?
If a label already starts with xn-- but also contains non-ASCII characters, the tool reports an error rather than double-encoding it, since that would produce an invalid result.