nginx-proxy

Automated Nginx Reverse Proxy for Docker

  • Network Services
Automated Nginx Reverse Proxy for Docker

Platform availability

Available on 1 of 10 platforms

  • Unraid (not listed)
  • TrueNAS (not listed)
  • Umbrel (not listed)
  • ZimaOS (not listed)
  • Proxmox (not listed)
  • Helm (not listed)
  • Mac (not listed)
  • Windows (not listed)
  • Linux (not listed)
  • Any server

Health score?A 0-100 score computed nightly from four factors: maintained (40%: recent commits and steady activity), popular (25%: GitHub stars, log scale), easy to install (20%: platforms, install notes, setup guides, Docker image) and light to run (15%: minimum RAM, ARM support). When the source code has been checked, a fifth factor, security check (20%: automated scan for committed secrets, unsafe desktop-app settings, known-vulnerable dependencies and project hygiene; any serious finding caps it at 20), is added. Factors without data are left out and the rest are rescaled.

81/100 Excellent

Maintained
100last commit 3 days ago
Popular
8619,949 GitHub stars
Easy to install
251 install platform, install notes
Light to run
100134 MB minimum RAM
Security check
77no serious findings, CI, tests, OpenSSF Scorecard 4.9/10

Availability: platform listings confirmed today

GitHub stars
19,949
Open issues
335
Last commit
2026-11-30
Latest release
1.11.8
License
MIT
Activity
rising

Checked today - source: GitHub (nginx-proxy/nginx-proxy)

Resources & Compatibility

Minimum requirements: 134 MB RAM.

Checked today - source: Docker Hub image tags and published docs

First-install notes

  • Put config templates in /etc/nginx/templates Mount a folder of .template files at /etc/nginx/templates and pass settings as environment variables (like NGINX_MY_SERVER_NAME=example.com). At startup, nginx replaces the variables and writes the final config, so you can change settings per container without editing files by hand. source
  • Map a port so you can reach nginx Run with -p 8080:80 to publish nginx's internal port 80 to port 8080 on your machine. Without this mapping, the web server runs but nothing outside the container can connect to it. source
  • Optional: autotune worker count Set the environment variable NGINX_ENTRYPOINT_WORKER_PROCESSES_AUTOTUNE=true (any non-empty value) so nginx automatically matches its worker processes to the CPU limit you give the container, like --cpus 2. Skip it if you're fine with the default behavior. source
  • Getting started Run the nginx-proxy container (image nginxproxy/nginx-proxy on Docker Hub) alongside your other containers, then set a VIRTUAL_HOST environment variable on each container you want proxied. It watches Docker events, generates the reverse proxy configuration automatically via docker-gen, and reloads nginx when containers start or stop. source

Fetched today - each note links to its source

Alternatives (2)

  • Envoy - Envoy is an open-source cloud-native edge, middle, and service proxy for managing, routing, and securing traffic in microservice architectu…
  • Haproxy - HAProxy is a TCP proxy and a HTTP reverse proxy.

Checked today - source: AlternativeTo

Common questions

How do I get a container proxied by nginx-proxy?

Set the environment variable VIRTUAL_HOST=subdomain.yourdomain.com on the container you want proxied, and make sure DNS resolves that hostname to the host running nginx-proxy. The container must also expose the port to be proxied via EXPOSE or --expose.

Why can't nginx-proxy reach my other containers?

Proxied containers must share at least one Docker network with the nginx-proxy container. If no --net flag is used, nginx-proxy only attaches to the default bridge network and cannot connect to containers on other networks.

Can I include a port number in the VIRTUAL_HOST variable?

No, providing a port number in VIRTUAL_HOST is not supported. Use the virtual ports or custom external HTTP/HTTPS ports configuration options depending on what you want to achieve.

Which image variants are available?

There is a Debian-based image (nginxproxy/nginx-proxy) and an Alpine-based variant with the -alpine suffix. There is also a -dockergen variant meant for a separate-containers setup with the official nginx image.

How does nginx-proxy detect when containers start and stop?

It runs nginx together with docker-gen, which watches Docker events, generates reverse proxy configs automatically, and reloads nginx when containers are started or stopped.

Do I need to expose any volumes or ports for nginx-proxy to work?

Yes, publish port 80 and mount the Docker socket read-only, for example with --publish 80:80 and --volume /var/run/docker.sock:/tmp/docker.sock:ro.

Answers sourced from github.com

Community

Collected today - public community threads