# Install nginx

HTTP(S) server and reverse proxy, and IMAP/POP3 proxy server. Version 1.31.1 via Homebrew; verified 2026-05-22.

## Install

```sh
sudo av install brew:nginx
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install nginx
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install nginx
```

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

### Linux

- apk (92%):

```sh
sudo apk add nginx
```

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

- Debian apt (92%):

```sh
sudo apt install libnginx-mod-http-geoip
```

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

- dnf (92%):

```sh
sudo dnf install nginx
```

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

- Nix (92%):

```sh
nix profile install nixpkgs#nginx
```

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

- pacman (92%):

```sh
sudo pacman -S nginx
```

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

- zypper (92%):

```sh
sudo zypper install nginx
```

  Evidence: openSUSE Tumbleweed package metadata: nginx from https://download.opensuse.org/tumbleweed/repo/oss/repodata/155b97171d05e27afd950b6fe0d55513ff38f4597110664535bceedc680bbe6fd459f0733718dcc21dcf0efc7c8250fd1390c73d4790b42e62fb2c16a87242e5-primary.xml.zst

### Windows

- Chocolatey (92%):

```sh
choco install nginx
```

  Evidence: Chocolatey community package catalog: nginx from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='11','navfree'

- Scoop (92%):

```sh
scoop install main/nginx
```

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

- winget (92%):

```sh
winget install --id freenginx.nginx -e
```

  Evidence: Windows Package Manager source index: freenginx.nginx from https://cdn.winget.microsoft.com/cache/source.msix

## Package Facts

- **Package key:** brew:nginx
- **Package manager:** Homebrew
- **Package manager URL:** <https://formulae.brew.sh/formula/nginx>
- **Version:** 1.31.1
- **Source summary:** HTTP(S) server and reverse proxy, and IMAP/POP3 proxy server
- **Homepage:** <https://nginx.org/>
- **Repository:** <https://github.com/nginx/nginx>
- **Upstream docs:** <https://nginx.org/en/docs>
- **License:** BSD-2-Clause
- **Source archive:** <https://nginx.org/download/nginx-1.31.1.tar.gz>
- **Last updated:** 2026-05-22T20:58:53Z
- **Generated:** 2026-06-10T07:18:26+00:00

## Executables

- nginx (cli)
- nginx (alias)

## Dependencies

- openssl@3
- pcre2

## macOS Provided Libraries

- libxcrypt

## Install Behavior

- Post-install hook: defined
- Service: declared
- Caveats: Docroot is: $HOMEBREW_PREFIX/var/www The default port has been set in $HOMEBREW_PREFIX/etc/nginx/nginx.conf to 8080 so that nginx can run without sudo. nginx will load all files in $HOMEBREW_PREFIX/etc/nginx/servers/.
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-06-10
- Package-manager version: 1.31.1
- Package-manager updated: 2026-05-22
- Local data status: ok
- Upstream repository: https://nginx.org/
- info: Release/tag comparison is only available for GitHub repositories.

## セキュリティノート

formula declares a Homebrew service.

- **Geiger risk:** orange / medium
- formula declares a Homebrew service

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** nginx
- **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 - libnginx-mod-http-geoip - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-http-geoip from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GeoIP HTTP module for Nginx | https://nginx.org
- Debian apt - libnginx-mod-http-image-filter - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-http-image-filter from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | HTTP image filter module for Nginx | https://nginx.org
- Debian apt - libnginx-mod-http-perl - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-http-perl from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Perl module for Nginx | https://nginx.org
- Debian apt - libnginx-mod-http-xslt-filter - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-http-xslt-filter from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | XSLT Transformation module for Nginx | https://nginx.org
- Debian apt - libnginx-mod-mail - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-mail from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Mail module for Nginx | https://nginx.org
- Debian apt - libnginx-mod-stream - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-stream from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Stream module for Nginx | https://nginx.org
- Debian apt - libnginx-mod-stream-geoip - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: libnginx-mod-stream-geoip from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GeoIP Stream module for Nginx | https://nginx.org
- Debian apt - nginx - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | small, powerful, scalable web/proxy server | https://nginx.org
- Debian apt - nginx-common - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-common from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | small, powerful, scalable web/proxy server - common files | https://nginx.org
- Debian apt - nginx-core - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-core from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | nginx web/proxy server (standard version) | https://nginx.org
- Debian apt - nginx-dev - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | nginx web/proxy server - development headers | https://nginx.org
- Debian apt - nginx-doc - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | small, powerful, scalable web/proxy server - documentation | https://nginx.org
- Debian apt - nginx-extras - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-extras from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | nginx web/proxy server (extended version) | https://nginx.org
- Debian apt - nginx-full - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-full from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | nginx web/proxy server (standard version with 3rd parties) | https://nginx.org
- Debian apt - nginx-light - 1.26.3-3+deb13u4: normalized package name match | Debian stable package indexes: nginx-light from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | nginx web/proxy server (basic version) | https://nginx.org
- Nix - nginx: normalized package name match | nixpkgs package indexes: nginx from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix


## Related Links

- [Secret-risk packages](https://www.automicvault.com/ja/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/ja/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/ja/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [Web development packages](https://www.automicvault.com/ja/pkg/web-dev-tools/) - Matched web development metadata.
- [openssl@3](https://www.automicvault.com/ja/pkg/brew/openssl-3/) - Runtime dependency declared by Homebrew.
- [pcre2](https://www.automicvault.com/ja/pkg/brew/pcre2/) - Runtime dependency declared by Homebrew.
- [httpd](https://www.automicvault.com/ja/pkg/brew/httpd/) - Shares av.db curated category or tags: cli, http, networking, web-server.
- [caddy](https://www.automicvault.com/ja/pkg/brew/caddy/) - Shares av.db curated category or tags: cli, networking, reverse-proxy, web-server.
- [static-web-server](https://www.automicvault.com/ja/pkg/brew/static-web-server/) - Shares av.db curated category or tags: cli, http, networking, web-server.
- [ferron](https://www.automicvault.com/ja/pkg/brew/ferron/) - Shares av.db curated category or tags: cli, http, networking, web-server.
- [yaws](https://www.automicvault.com/ja/pkg/brew/yaws/) - Shares av.db curated category or tags: cli, http, networking, web-server.
- [h2o](https://www.automicvault.com/ja/pkg/brew/h2o/) - Shares av.db curated category or tags: cli, http, networking, web-server.
- [mighttpd2](https://www.automicvault.com/ja/pkg/brew/mighttpd2/) - Shares av.db curated category or tags: cli, networking, reverse-proxy, web-server.
- [lighttpd](https://www.automicvault.com/ja/pkg/brew/lighttpd/) - Shares av.db curated category or tags: cli, networking, web-server.
- [trafficserver](https://www.automicvault.com/ja/pkg/brew/trafficserver/) - Local metadata places this package in an adjacent workflow. Shared terms: cli, http, networking, openssl, openssl-3.

## 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
