Punycode Converter — IDN Domains ↔ xn-- ASCII (RFC 3492)
Convert internationalized (IDN) domain names to and from their ASCII xn-- form. Follows RFC 3492 exactly — the same encoding your browser and DNS resolver use. 100% local.
Last updated:
CommentsFrequently Asked Questions
What is Punycode?
Punycode (RFC 3492) is the encoding that lets non-ASCII domain names (like café.com or 中国.cn) travel through DNS, which is ASCII-only. Browsers convert the Unicode form into its 'xn--…' Punycode form before doing a DNS lookup.
Why do I see xn-- in a URL bar sometimes?
Most modern browsers show the xn-- form when a domain mixes scripts (e.g. Latin + Cyrillic) that could be used for a homograph phishing attack. Displaying the raw ASCII form makes the deception visible.
Which characters are safe in a domain label?
IDNA 2008 restricts each label to a curated set of Unicode letters, digits, and hyphens. This tool encodes any input that syntactically fits Punycode; ICANN / registry policy on which strings are actually registerable is out of scope here.
Related Tools
Base64
Encode and decode Base64 strings online. Supports UTF-8 text and URL-safe Base64. All processing runs locally in your browser.
Base32
Encode and decode Base32 strings online (RFC 4648). Handles TOTP / Google Authenticator secrets, DNSSEC records, and other case-insensitive binary-to-text formats. 100% local.
Base58
Encode and decode Base58 strings online — the alphabet used by Bitcoin addresses, Solana public keys, IPFS CID v0, and Flickr short links. 100% local, no padding, human-safe.
Unicode Escape
Escape and unescape Unicode sequences online. Convert any text to \uXXXX / \u{XXXX} form, or reverse escape sequences back to readable text. Handles surrogate pairs and emoji. 100% local.
URL Encode/Decode
Percent-encode and decode URLs online. Handles query strings, path segments, and special characters correctly.
HTML Encode/Decode
Encode and decode HTML entities (&, <, >, ", numeric references). Useful for sanitizing user content or debugging escaped markup.