Skip to content
← Back

idn-punycode-converter

Network
Runs locally · Not uploaded

This tool runs entirely in your browser. Open DevTools → Network panel and search your input — it appears in no request.

Usage Guide

Internationalized domains (例子.测试) live in DNS as xn-- ASCII (punycode) while browsers display the Unicode form — two faces of one domain. This tool converts both ways: forward through the WHATWG URL IDNA implementation (identical to browser behavior), reverse per RFC 3492 label-by-label, batch multi-line. Its sharpest use case is security: phishing hides behind look-alike xn-- domains, and decoding a suspect URL settles it instantly.

1. Two directions, two implementations

  1. Unicode → xn--: delegated to the WHATWG URL parser (new URL) — the same IDNA implementation your browser runs, so behavior matches reality exactly; no IDNA tables to maintain.
  2. xn-- → Unicode: pure RFC 3492 bootstring decoding per label; one bad label never spoils the batch — failures are flagged per line.
  3. Batch: one domain per line; when mixing directions, check which tab you are on first.

2. The shortest anti-phishing path

Three steps for a suspicious link: forward-convert it — if pure ASCII decodes into a look-alike Unicode string (xn--pypal-4ve.com → рaypal with a Cyrillic р), it is homoglyph phishing; reverse-convert xn-- runs to expose hidden CJK domains; then diff the output against the official domain character by character (Cyrillic а ≠ Latin a — invisible to the eye, obvious in a decoded diff). Browsers show the Unicode form precisely to expose these spoofs — provided you know to decode.

Related Tools

Related Articles