# Install libidn2 with Homebrew, apk, apt, dnf, MacPorts, Nix, pacman, zypper

International domain name library (IDNA2008, Punycode and TR46). Version 2.3.8 via Homebrew; verified 2026-06-22.

## Install

```sh
sudo av install brew:libidn2
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install libidn2
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install libidn2
```

  Evidence: MacPorts ports tree: mail/libidn2/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add idn2-utils
```

  Evidence: Alpine Linux edge package indexes: idn2-utils from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install idn2
```

  Evidence: Debian stable package indexes: idn2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install idn2
```

  Evidence: Fedora Rawhide package metadata: idn2 from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#libidn2
```

  Evidence: nixpkgs package indexes: libidn2 from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix

- pacman (92%):

```sh
sudo pacman -S libidn2
```

  Evidence: Arch Linux sync databases: libidn2 from https://geo.mirror.pkgbuild.com/core/os/x86_64/core.db.tar.gz

- zypper (92%):

```sh
sudo zypper install libidn2-0
```

  Evidence: openSUSE Tumbleweed package metadata: libidn2-0 from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst

## Package facts

- **Package key:** brew:libidn2
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/libidn2>
- **Version:** 2.3.8
- **Source summary:** International domain name library (IDNA2008, Punycode and TR46)
- **Homepage:** <https://www.gnu.org/software/libidn/#libidn2>
- **Repository:** <https://git.savannah.gnu.org/git/libidn/libidn2.git>
- **Upstream docs:** <https://www.gnu.org/software/libidn/libidn2/manual/libidn2.html>
- **License:** (GPL-2.0-or-later OR LGPL-3.0-or-later) AND (Unicode-TOU AND Unicode-DFS-2016) AND GPL-3.0-or-later AND LGPL-2.1-or-later AND FSFAP-no-warranty-disclaimer
- **Source archive:** <https://ftpmirror.gnu.org/gnu/libidn/libidn2-2.3.8.tar.gz>
- **Last updated:** 2026-06-22T14:05:18-07:00
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- idn2 (cli)
- idn2 (alias)

## Dependencies

- gettext
- libunistring

## Build dependencies

- pkgconf

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, arm64_ventura, sonoma, ventura, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 2.3.8
- Package-manager updated: 2026-06-22
- Local data: ok
- Upstream repository: https://www.gnu.org/software/libidn/#libidn2
- info: Release/tag comparison is only available for GitHub repositories.
## Project history and usage

GNU Libidn2 is the GNU successor to Libidn for IDNA2008 and Unicode TR46 internationalized-domain-name processing.

### Project history

The IETF IDNA2008 RFC series replaced the earlier IDNA2003 model, describing a revised protocol and definitions for internationalized domain names. Libidn2 was created to implement that newer standards family while retaining package-level continuity for GNU users.

The Libidn2 NEWS file records an initial 0.0 alpha release on 2011-03-09 for public API review, with IDNA2008 lookup mostly implemented. Release 0.2 on 2011-03-30 added the idn2 command-line tool and made lookup/register functions operational.

Release 0.12 on 2016-12-26 added TR46/UTS #46 support to the API and idn2 utility. Release 2.0.0 on 2017-03-29 changed the version numbering scheme and added to-ASCII and to-Unicode conversion functions corresponding to Libidn functions. Release 2.0.5 on 2018-05-18 switched the default library behavior to IDNA2008 as amended by non-transitional TR46.

### Adoption history

The GNU Libidn page explicitly calls Libidn2 the successor of GNU Libidn and notes that it provides IDNA2008, TR46, and a compatibility layer for GNU Libidn. That made it the practical migration path for distributions and network applications moving away from IDNA2003 behavior.

Libidn2 is package-visible because applications often need a shared, audited implementation of Unicode domain-name conversion rather than hand-rolling security-sensitive Punycode and normalization behavior.

### How it is used

Users call idn2 for command-line conversion and debugging, while applications link the library for IDNA lookup and registration conversions. The manual emphasizes correct locale and UTF-8 handling because feeding bytes in the wrong character set can produce errors or wrong output.

### Why package nerds care

Libidn2 is where DNS, Unicode versioning, security-sensitive string handling, and compatibility policy meet. Packagers care about it because changing from libidn to libidn2 can alter IDNA behavior, but staying on IDNA2003 can be wrong for software that expects IDNA2008/TR46.

It is also a good example of a successor package that is not just a new ABI: it represents a standards transition and a different view of what domain names should accept.

### Timeline

- 2010: RFC 5890 and related RFCs documented the IDNA2008 revision that superseded IDNA2003.
- 2011: Libidn2 0.0 alpha released for public API review.
- 2011: Libidn2 0.2 added the idn2 command-line tool.
- 2016: Libidn2 0.12 added TR46/UTS #46 support.
- 2017: Libidn2 2.0.0 changed version numbering and added Libidn-corresponding conversion APIs.
- 2018: Libidn2 2.0.5 made IDNA2008 plus non-transitional TR46 the default behavior.

### Related projects

- GNU Libidn is the predecessor and compatibility target.
- GNU libunistring is related through Unicode string support used by Libidn2 builds.
- RFC 5890, RFC 5891, and Unicode UTS #46 define the standards context around Libidn2.

### Sources

- <https://datatracker.ietf.org/doc/html/rfc5890>
- <https://datatracker.ietf.org/doc/html/rfc5891>
- <https://github.com/libidn/libidn2/blob/master/NEWS>
- <https://unicode.org/reports/tr46/>
- <https://www.gnu.org/software/libidn/>
- <https://www.gnu.org/software/libidn/libidn2/manual/libidn2.html>


## Security Notes

library-like package without higher-risk signals.

- **Geiger risk:** green / low
- library-like package without higher-risk signals

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** libidn2
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## Other Package-Manager Records

- Debian apt - idn2 - 2.3.8-2: normalized package name match | Debian stable package indexes: idn2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Internationalized domain names (IDNA2008/TR46) command line tool | https://www.gnu.org/software/libidn/#libidn2
- Debian apt - libidn2-0 - 2.3.8-2: normalized package name match | Debian stable package indexes: libidn2-0 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Internationalized domain names (IDNA2008/TR46) library | https://www.gnu.org/software/libidn/#libidn2
- Debian apt - libidn2-dev - 2.3.8-2: normalized package name match | Debian stable package indexes: libidn2-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Internationalized domain names (IDNA2008/TR46) development files | https://www.gnu.org/software/libidn/#libidn2
- Debian apt - libidn2-doc - 2.3.8-2: normalized package name match | Debian stable package indexes: libidn2-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Internationalized domain names (IDNA2008/TR46) documentation | https://www.gnu.org/software/libidn/#libidn2
- Nix - libidn2: normalized package name match | nixpkgs package indexes: libidn2 from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix
- Ubuntu apt - idn2 - 2.3.7-2build1: normalized package name match | Ubuntu 24.04 LTS package indexes: idn2 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Internationalized domain names (IDNA2008/TR46) command line tool | https://www.gnu.org/software/libidn/#libidn2
- Ubuntu apt - libidn2-0 - 2.3.7-2build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libidn2-0 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Internationalized domain names (IDNA2008/TR46) library | https://www.gnu.org/software/libidn/#libidn2
- Ubuntu apt - libidn2-dev - 2.3.7-2build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libidn2-dev from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Internationalized domain names (IDNA2008/TR46) development files | https://www.gnu.org/software/libidn/#libidn2
- Ubuntu apt - libidn2-doc - 2.3.7-2build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libidn2-doc from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Internationalized domain names (IDNA2008/TR46) documentation | https://www.gnu.org/software/libidn/#libidn2
- apk - idn2-utils - 2.3.8-r0: normalized package name match | Alpine Linux edge package indexes: idn2-utils from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Encode/Decode library for internationalized domain names (CLI utilities) | https://www.gnu.org/software/libidn#libidn2
- apk - libidn2 - 2.3.8-r0: normalized package name match | Alpine Linux edge package indexes: libidn2 from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Encode/Decode library for internationalized domain names | https://www.gnu.org/software/libidn#libidn2
- apk - libidn2-dev - 2.3.8-r0: normalized package name match | Alpine Linux edge package indexes: libidn2-dev from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Encode/Decode library for internationalized domain names (development files) | https://www.gnu.org/software/libidn#libidn2
- apk - libidn2-doc - 2.3.8-r0: normalized package name match | Alpine Linux edge package indexes: libidn2-doc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Encode/Decode library for internationalized domain names (documentation) | https://www.gnu.org/software/libidn#libidn2
- apk - libidn2-static - 2.3.8-r0: normalized package name match | Alpine Linux edge package indexes: libidn2-static from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Encode/Decode library for internationalized domain names (static library) | https://www.gnu.org/software/libidn#libidn2
- dnf - idn2 - 2.3.8-3.fc44: normalized package name match | Fedora Rawhide package metadata: idn2 from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | IDNA2008 internationalized domain names conversion tool | https://www.gnu.org/software/libidn/#libidn2
- dnf - libidn2 - 2.3.8-3.fc44: normalized package name match | Fedora Rawhide package metadata: libidn2 from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | Library to support IDNA2008 internationalized domain names | https://www.gnu.org/software/libidn/#libidn2


## Related links

- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [Homebrew utility packages](https://www.automicvault.com/pkg/brew-utility-packages/) - Matched Homebrew package provider.
- [gettext](https://www.automicvault.com/pkg/brew/gettext/) - Runtime dependency declared by Homebrew.
- [pkgconf](https://www.automicvault.com/pkg/brew/pkgconf/) - Build dependency declared by Homebrew.
- [bind](https://www.automicvault.com/pkg/brew/bind/) - Popular package that depends on this formula.
- [felinks](https://www.automicvault.com/pkg/brew/felinks/) - Popular package that depends on this formula.
- [freediameter](https://www.automicvault.com/pkg/brew/freediameter/) - Popular package that depends on this formula.
- [getdns](https://www.automicvault.com/pkg/brew/getdns/) - Popular package that depends on this formula.
- [gnunet](https://www.automicvault.com/pkg/brew/gnunet/) - Popular package that depends on this formula.
- [gnutls](https://www.automicvault.com/pkg/brew/gnutls/) - Popular package that depends on this formula.
- [inetutils](https://www.automicvault.com/pkg/brew/inetutils/) - Popular package that depends on this formula.
- [libidn](https://www.automicvault.com/pkg/brew/libidn/) - Package name indicates the same formula family.
- [adns](https://www.automicvault.com/pkg/brew/adns/) - Shares av.db curated category or tags: cli, dns, library, networking.
- [c-ares](https://www.automicvault.com/pkg/brew/c-ares/) - Shares av.db curated category or tags: cli, dns, library, networking.
- [hesiod](https://www.automicvault.com/pkg/brew/hesiod/) - Shares av.db curated category or tags: cli, dns, library, networking.
- [aliddns](https://www.automicvault.com/pkg/brew/aliddns/) - Shares av.db curated category or tags: cli, dns, networking.
- [cdncheck](https://www.automicvault.com/pkg/brew/cdncheck/) - Shares av.db curated category or tags: cli, dns, networking.
- [checkdmarc](https://www.automicvault.com/pkg/brew/checkdmarc/) - Shares av.db curated category or tags: cli, dns, networking.
- [wget](https://www.automicvault.com/pkg/brew/wget/) - Local package facts share a topical domain. Shared terms: cli, gettext, gnu, libidn2, libunistring.

## Combined YAML source

View the package source record on GitHub. [combined/libidn2.yml](https://github.com/automic-vault/db/blob/main/combined/libidn2.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
