Punycode Converter
Enter one domain label to encode to Punycode.
Result
How it is calculated
The tool encodes one domain label with the RFC 3492 bootstring algorithm. It first splits the text into Unicode code points. The ASCII characters are copied to the output in order, followed by a hyphen. Then each non-ASCII character is recorded as a number that says how far it is from the previous position, written in a variable-length base-36 code (letters a–z, digits 0–9). The whole result gets the prefix xn--. A label made only of ASCII is returned unchanged with no prefix. The tool also shows how many characters are ASCII and the total character count. It only encodes: it does not decode, does not lowercase letters and does not split a full domain at the dots.
Worked example
Take the label münchen. It has 7 characters, of which 6 are ASCII (m, n, c, h, e, n), so the output starts with mnchen followed by a hyphen. The single non-ASCII character is ü, code point 252. Its position and distance from 128 turn into the number 869, which is written in base 36 as the digits 3, y and a. The tool then adds the prefix and returns xn--mnchen-3ya. This is the ASCII form that DNS uses for the name, while browsers show it back as münchen.
Common mistakes
- Pasting a whole domain such as münchen.de. The dot is treated as a normal character of the label, so the result (xn--mnchen.de-q9a) is not a valid domain form; encode each label separately and join them with dots.
- Entering upper-case letters and expecting lower-case output. The tool does not normalise case, so MÜNCHEN gives xn--MNCHEN-psa, while the registered name is lower-case; type the label in lower case.
- Expecting the xn-- prefix for plain ASCII. A label like example is returned unchanged because it needs no encoding.
- Using the tool to decode an xn-- name back to Unicode. It only encodes.
About this calculator
Domain names were originally restricted to ASCII characters, which left no room for the world’s non-Latin scripts. Punycode, defined in RFC 3492, solves this with a “bootstring” algorithm that encodes any Unicode label — say, a domain name containing Turkish, Arabic or Chinese characters — into an ASCII-only string prefixed with xn--, which browsers and DNS servers then decode back to the original Unicode text.
This is the mechanism behind every internationalized domain name (IDN) you see redirect to an “xn--” address in your browser bar. This calculator encodes a single domain label to its Punycode form, a task that’s useful for domain registrars, web developers and DNS administrators working with non-English domain names and needing to verify or generate the ASCII form manually.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments (1)
Seeing the xn-- form is a useful lookalike check. The label bücher becomes xn--bcher-kva, which is what appears in DNS records and certificates, and a link whose raw form starts with xn-- deserves a closer look. The tool only encodes and does not decode, and it does not apply the registry rules for allowed characters. Which language or script are your domain names written in?