Advertisement

Punycode Encoder

Encode internationalized domain names like münchen.de into Punycode (xn--mnchen-3ya.de) or decode them back. Implements the RFC 3492 algorithm label by label.

Punycode

Domain to encode, or xn-- domain to decode.

Advertisement

How Punycode works

Punycode compresses Unicode characters into an ASCII string using a clever variable-length encoding defined in RFC 3492. Each domain label containing non-ASCII characters gets an xn-- prefix, so münchen.de becomes xn--mnchen-3ya.de. The DNS system only understands ASCII, which is why this translation exists.

Where you will see Punycode

Browsers show the xn-- form in the address bar for suspicious domains as a phishing defense, email systems use it for internationalized addresses, and SSL certificates list it in subject alternative names. Developers meet it when configuring DNS for non-ASCII brands.

Punycode Encoder FAQs

Does it convert whole domains or single labels?
Whole domains. The input is split on dots and each label with non-ASCII characters is encoded separately, so sub.münchen.de converts correctly label by label.
What characters trigger encoding?
Any character outside plain ASCII in a label triggers the xn-- encoding for that label. Pure ASCII labels like www pass through unchanged.
Can I decode an xn-- domain?
Yes, switch to Decode mode. Labels starting with xn-- are decoded back to Unicode, which is useful when inspecting a suspicious link or certificate entry.
Is this the same as URL percent-encoding?
No. Percent-encoding like %C3%BC is for URL paths, while Punycode is specifically for domain labels. They solve different problems and are not interchangeable.
Is my input uploaded?
No. Encoding and decoding run entirely in your browser, so domain names never leave your device.
Advertisement