Nginx Proxy Manager is a simple yet powerful reverse proxy solution with a beautiful web interface. No command-line expertise needed:
- Visual interface - Manage proxy hosts from an intuitive dashboard
- SSL/TLS automation - Let's Encrypt integration with automatic renewal
- Zero downtime - Add, modify, or remove proxy hosts on the fly
- Security features - Access lists, basic auth, and bot protection
- Load balancing - Distribute traffic across multiple backend servers
Perfect for routing traffic to multiple services, setting up a single entry point for your infrastructure, or hosting multiple applications on one server without port conflicts.
More details https://nginxproxymanager.com
Before you begin, ensure you have the following installed on your system:
- Docker (version 20.10+)
- Docker Compose (version 2.0+)
- Git (to clone repositories or download files)
- A Linux server (Ubuntu 20.04+ or CentOS 7+ recommended)
- Internet connection to download Docker images
- Domain name (optional, but recommended for SSL certificates)
docker --version
docker compose versionIf not installed, follow the official Docker installation guide.
git clone https://github.com/wmo-raf/nginx-proxy-manager.git
cd nginx-proxy-managerCreate subdirectories for data persistence:
mkdir -p data
mkdir -p letsencryptYour directory structure should look like this:
nginx-proxy-manager/
├── data/
├── letsencrypt/
├── docker-compose.yml
└── .env
Create a file named .env in your nginx-proxy-manager directory:
cp .env.sample .envAdd the following content:
NETWORK_NAME=
You can customize the network name to match your infrastructure.
Save the file (in nano: press Ctrl+O, then Enter, then Ctrl+X).
The configuration uses an external network. Create it with this command (use the NETWORK_NAME from your .env file):
docker network create nginx_networkOr if you changed NETWORK_NAME in your .env file, replace it accordingly:
docker network create your_custom_network_nameTo verify the network was created:
docker network lsImportant: If you're using this with other services (like SFTPGo), make sure to use the same network name so all services can communicate.
Set proper permissions for the data directories:
chmod 755 data
chmod 755 letsencryptNavigate to your project directory and start the service:
cd ~/nginx-proxy-manager
docker compose up -dThe -d flag runs containers in detached mode (background).
Monitor the startup process:
docker compose logs -fWait until you see messages indicating the service is running. Press Ctrl+C to exit the logs.
Check if the container is running:
docker compose psExpected output:
CONTAINER ID IMAGE STATUS
xxxxx jc21/nginx-proxy-manager:latest Up 2 minutes
Check the logs for any errors:
docker compose logs nginx_proxy_managerOpen your web browser and go to:
http://your-server-ip:81
Replace your-server-ip with your server's actual IP address.
Default Admin Credentials:
- Email:
admin@example.com - Password:
changeme
- Log in with default credentials
- Go to "Hosts" → "Proxy Hosts"
- Click "Add Proxy Host"
- Fill in:
- Domain Names: Your domain(s)
- Scheme: http or https
- Forward Hostname/IP: Your backend service IP/hostname
- Forward Port: Your backend service port
- Enable "Block Common Exploits" for security
- Go to "SSL" tab and select "Request a new SSL Certificate"
- Enter your email and accept Let's Encrypt terms
- Save
Your Nginx Proxy Manager setup uses these ports:
| Port | Service | Purpose |
|---|---|---|
| 80 | HTTP | Web traffic (auto-redirect to HTTPS) |
| 81 | Admin Interface | Web administration panel |
| 443 | HTTPS | Secure web traffic |
Ensure these ports are:
- Not blocked by firewall
- Open in your hosting provider's security groups
- Accessible from the internet
docker compose downdocker compose up -ddocker compose restartdocker compose logs -f nginx_proxy_managerdocker compose logs --tail=100 nginx_proxy_managerTo connect other services (like SFTPGo) to this Nginx Proxy Manager:
- Ensure both services use the same network (configured in
.envwithNETWORK_NAME) - In Nginx Proxy Manager, use the service container name as the hostname
- Example:
sftpgo:8080for SFTPGo web interface
- Example:
- Set the appropriate forward port
Issue: Cannot access admin interface (http://ip:81)
Solution:
- Check if container is running:
docker compose ps - Check firewall settings:
sudo ufw status - Allow port 81:
sudo ufw allow 81 - Check service logs:
docker compose logs nginx_proxy_manager
Solution:
- Check logs:
docker compose logs nginx_proxy_manager | grep letsencrypt - Ensure ports 80 and 443 are accessible from the internet
- Verify domain DNS is pointing to your server
- Check Let's Encrypt rate limits (50 certificates per domain per week)
Solution:
- Verify services are on the same network:
docker network inspect nginx_network - Use service container name, not localhost or 127.0.0.1
- Ensure backend service is running:
docker compose ps - Check backend service logs for errors
Solution:
- Verify backend service is running and healthy
- Check forward hostname/port configuration in proxy host
- Check backend service logs:
docker compose logs service_name - Ensure backend service is accessible on the network
Solution:
sudo chown -R 33:33 data
sudo chown -R 33:33 letsencrypt- Change default credentials immediately
- Use strong passwords (minimum 16 characters)
- Configure firewall to restrict access to admin port 81
- Enable SSL certificates for all proxy hosts
- Use strong SSL/TLS settings (A+ rating recommended)
- Enable Access Lists to restrict IPs if needed
- Enable HTTP/2 for better performance
- Keep Docker images updated:
docker compose pull docker compose up -d
- Monitor logs regularly for suspicious activity
- Back up your configuration regularly
- Go to Proxy Host
- SSL tab → "Request a new SSL Certificate"
- Let's Encrypt handles automatic renewal
docker compose pull
docker compose up -ddocker system prune -adf -h
du -sh *If you're running multiple Docker Compose projects and want them to communicate:
- All projects must use the same
NETWORK_NAMEin their.env - Create network once:
docker network create shared_network - All services will be discoverable by container name
docker compose logs -f --tail=50 nginx_proxy_managerdocker compose logs nginx_proxy_manager > nginx_logs.txtdocker stats nginx_proxy_manager- Nginx Proxy Manager GitHub: https://github.com/NginxProxyManager/nginx-proxy-manager
- Docker Documentation: https://docs.docker.com/
- Let's Encrypt Documentation: https://letsencrypt.org/docs/
- Set up your first proxy host
- Configure SSL certificates
- Set up access lists for security
- Configure redirects if needed
- Monitor and maintain regularly
- Document all configurations