# Install pcre2 with Homebrew, apk, apt, dnf, Nix, pacman, zypper, scoop

Perl compatible regular expressions library with a new API. Version 10.47 via Homebrew; verified from local package data.

## Install

```sh
sudo av install brew:pcre2
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install pcre2
```

  Evidence: local Homebrew formula metadata

### Linux

- apk (92%):

```sh
sudo apk add libpcre2-16
```

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

- Debian apt (92%):

```sh
sudo apt install libpcre2-16-0
```

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

- dnf (92%):

```sh
sudo dnf install pcre2
```

  Evidence: Fedora Rawhide package metadata: pcre2 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#pcre2
```

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

- pacman (92%):

```sh
sudo pacman -S pcre2
```

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

- zypper (92%):

```sh
sudo zypper install libpcre2-16-0
```

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

### Windows

- Scoop (92%):

```sh
scoop install main/pcre2grep
```

  Evidence: Scoop official bucket manifest trees: bucket/pcre2grep.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:pcre2
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/pcre2>
- **Version:** 10.47
- **Source summary:** Perl compatible regular expressions library with a new API
- **Homepage:** <https://www.pcre.org/>
- **Repository:** <https://github.com/PCRE2Project/pcre2>
- **Upstream docs:** <https://www.pcre.org/current/doc/html>
- **License:** BSD-3-Clause
- **Source archive:** <https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.47/pcre2-10.47.tar.bz2>
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- pcre2-config (cli)
- pcre2grep (cli)
- pcre2test (cli)
- pcre2-config (alias)
- pcre2grep (alias)
- pcre2test (alias)

## Uses from macOS

- bzip2

## Install behavior

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

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 10.47
- Local data: ok
- Upstream repository: https://github.com/PCRE2Project/pcre2
- info: No package-manager update timestamp was available.
- info: No cached GitHub release or tag data was available.

## 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:** pcre2
- **Version Scheme:** 0
- **Revision:** 1
- **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 - libpcre2-16-0 - 10.46-1~deb13u1: normalized package name match | Debian stable package indexes: libpcre2-16-0 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | New Perl Compatible Regular Expression Library - 16 bit runtime files | https://github.com/PCRE2Project/pcre2
- Debian apt - libpcre2-32-0 - 10.46-1~deb13u1: normalized package name match | Debian stable package indexes: libpcre2-32-0 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | New Perl Compatible Regular Expression Library - 32 bit runtime files | https://github.com/PCRE2Project/pcre2
- Debian apt - libpcre2-8-0 - 10.46-1~deb13u1: normalized package name match | Debian stable package indexes: libpcre2-8-0 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | New Perl Compatible Regular Expression Library- 8 bit runtime files | https://github.com/PCRE2Project/pcre2
- Debian apt - libpcre2-dev - 10.46-1~deb13u1: normalized package name match | Debian stable package indexes: libpcre2-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | New Perl Compatible Regular Expression Library - development files | https://github.com/PCRE2Project/pcre2
- Debian apt - libpcre2-posix3 - 10.46-1~deb13u1: normalized package name match | Debian stable package indexes: libpcre2-posix3 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | New Perl Compatible Regular Expression Library - posix-compatible runtime files | https://github.com/PCRE2Project/pcre2
- Debian apt - pcre2-utils - 10.46-1~deb13u1: normalized package name match | Debian stable package indexes: pcre2-utils from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | New Perl Compatible Regular Expression Library - utilities | https://github.com/PCRE2Project/pcre2
- Nix - pcre2: normalized package name match | nixpkgs package indexes: pcre2 from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix
- Ubuntu apt - libpcre2-16-0 - 10.42-4ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libpcre2-16-0 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | New Perl Compatible Regular Expression Library - 16 bit runtime files | https://pcre.org/
- Ubuntu apt - libpcre2-32-0 - 10.42-4ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libpcre2-32-0 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | New Perl Compatible Regular Expression Library - 32 bit runtime files | https://pcre.org/
- Ubuntu apt - libpcre2-8-0 - 10.42-4ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libpcre2-8-0 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | New Perl Compatible Regular Expression Library- 8 bit runtime files | https://pcre.org/
- Ubuntu apt - libpcre2-dev - 10.42-4ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libpcre2-dev from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | New Perl Compatible Regular Expression Library - development files | https://pcre.org/
- Ubuntu apt - libpcre2-posix3 - 10.42-4ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libpcre2-posix3 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | New Perl Compatible Regular Expression Library - posix-compatible runtime files | https://pcre.org/
- Ubuntu apt - pcre2-utils - 10.42-4ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: pcre2-utils from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | New Perl Compatible Regular Expression Library - utilities | https://pcre.org/
- apk - libpcre2-16 - 10.47-r1: normalized package name match | Alpine Linux edge package indexes: libpcre2-16 from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | PCRE2 with 16 bit character support | https://pcre.org/
- apk - libpcre2-32 - 10.47-r1: normalized package name match | Alpine Linux edge package indexes: libpcre2-32 from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | PCRE2 with 32 bit character support | https://pcre.org/
- apk - pcre2 - 10.47-r1: normalized package name match | Alpine Linux edge package indexes: pcre2 from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Perl-compatible regular expression library | https://pcre.org/


## Related links

- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [aide](https://www.automicvault.com/pkg/brew/aide/) - Popular package that depends on this formula.
- [aircrack-ng](https://www.automicvault.com/pkg/brew/aircrack-ng/) - Popular package that depends on this formula.
- [amber](https://www.automicvault.com/pkg/brew/amber/) - Popular package that depends on this formula.
- [analog](https://www.automicvault.com/pkg/brew/analog/) - Popular package that depends on this formula.
- [apachetop](https://www.automicvault.com/pkg/brew/apachetop/) - Popular package that depends on this formula.
- [arturo](https://www.automicvault.com/pkg/brew/arturo/) - Popular package that depends on this formula.
- [bigloo](https://www.automicvault.com/pkg/brew/bigloo/) - Popular package that depends on this formula.
- [pcre](https://www.automicvault.com/pkg/brew/pcre/) - Package name indicates the same formula family.
- [onigmo](https://www.automicvault.com/pkg/brew/onigmo/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries, regular-expressions.
- [oniguruma](https://www.automicvault.com/pkg/brew/oniguruma/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries, regular-expressions.
- [cdk](https://www.automicvault.com/pkg/brew/cdk/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries.
- [expat](https://www.automicvault.com/pkg/brew/expat/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries.
- [fstrm](https://www.automicvault.com/pkg/brew/fstrm/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries.
- [libevent](https://www.automicvault.com/pkg/brew/libevent/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries.
- [libxml2](https://www.automicvault.com/pkg/brew/libxml2/) - Shares av.db curated category or tags: c-library, cli, developer-tools, libraries.

## Combined YAML source

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


## Sources

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