Search code examples
c#.netidn

How to convert IDN to ASCII?


What is the best way to convert an internationalized domain name to its ASCII-form?

I want to convert Bücher.ch into xn--bcher-kva.ch by using some sort of (free) .net code.


Solution

  • Have a look at the GNU IDN Library - Libidn. The introduction says that C# libraries are available.