[GH-ISSUE #4767] 🐞 Bug: Editing Proxy Host from IP to Hostname Does Not Update Nginx Configuration #3008

Open
opened 2026-02-26 07:37:33 +03:00 by kerem · 1 comment
Owner

Originally created by @heyvoon on GitHub (Sep 15, 2025).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/4767

Checklist

  • Have you pulled and found the error with jc21/nginx-proxy-manager:latest docker image?
    • Yes
  • Are you sure you're not using someone else's docker image?
    • Yes
  • Have you searched for similar issues (both open and closed)?
    • Yes (I found related issues about proxy hosts not updating correctly, but none specifically describing this workflow bug).

Describe the bug
When editing an existing Proxy Host to change the "Forward Hostname / IP" field from an IP address to a new domain name (to convert it from a forward proxy to a reverse proxy), the change does not take effect. The Nginx configuration file is not updated correctly, and requests continue to be forwarded to the old IP address. The only reliable workaround is to delete the proxy host entry and create a new one.

Nginx Proxy Manager Version
v2.12.6

To Reproduce
Steps to reproduce the behavior:

  1. Create a Proxy Host that forwards to an IP address (e.g., 192.168.1.100:8080).
  2. Confirm it works correctly by accessing the domain; it shows the application at that IP.
  3. Edit the existing Proxy Host.
  4. Change the "Forward Hostname / IP" field from the IP address to a new domain name (e.g., my-internal-service.local).
  5. Save the changes. The UI confirms the host was updated successfully.
  6. Access the domain again. The page still shows the application from the old IP address (192.168.1.100:8080), not the new domain name (my-internal-service.local).
  7. Check the generated Nginx configuration file; it may still contain the old IP.

Expected behavior
After saving the changes, the Nginx configuration should be regenerated to forward traffic to the new domain name specified in the "Forward Hostname / IP" field. The change should be immediate and effective after a configuration reload.

Screenshots
(Not applicable for this text-based report, but could show the edit form and the resulting incorrect config file)

Operating System

  • Hardware: Raspberry Pi 4
  • OS: PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
  • Environment: Docker

Additional context

  • Docker Version: 24.0.5, build 24.0.5-0ubuntu1~22.04.1
  • This is a significant usability issue when managing many hosts, as it forces a time-consuming delete-and-recreate process and risks misconfiguration.
  • The problem appears to be that the backend service does not correctly trigger a rewrite of the Nginx configuration for the specific host when this particular field is changed from an IP to a hostname.
  • Restarting the NPM container or the Nginx process itself does not resolve the issue; only deletion and recreation of the host works.
Originally created by @heyvoon on GitHub (Sep 15, 2025). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/4767 <!-- Are you in the right place? - If you are looking for support on how to get your upstream server forwarding, please consider asking the community on Reddit. - If you are writing code changes to contribute and need to ask about the internals of the software, Gitter is the best place to ask. - If you think you found a bug with NPM (not Nginx, or your upstream server or MySql) then you are in the *right place.* --> **Checklist** - Have you pulled and found the error with `jc21/nginx-proxy-manager:latest` docker image? - **Yes** - Are you sure you're not using someone else's docker image? - **Yes** - Have you searched for similar issues (both open and closed)? - **Yes** (I found related issues about proxy hosts not updating correctly, but none specifically describing this workflow bug). **Describe the bug** When editing an existing Proxy Host to change the "Forward Hostname / IP" field from an IP address to a new domain name (to convert it from a forward proxy to a reverse proxy), the change does not take effect. The Nginx configuration file is not updated correctly, and requests continue to be forwarded to the old IP address. The only reliable workaround is to delete the proxy host entry and create a new one. **Nginx Proxy Manager Version** v2.12.6 **To Reproduce** Steps to reproduce the behavior: 1. Create a Proxy Host that forwards to an IP address (e.g., `192.168.1.100:8080`). 2. Confirm it works correctly by accessing the domain; it shows the application at that IP. 3. Edit the existing Proxy Host. 4. Change the "Forward Hostname / IP" field from the IP address to a new domain name (e.g., `my-internal-service.local`). 5. Save the changes. The UI confirms the host was updated successfully. 6. Access the domain again. The page still shows the application from the old IP address (`192.168.1.100:8080`), not the new domain name (`my-internal-service.local`). 7. Check the generated Nginx configuration file; it may still contain the old IP. **Expected behavior** After saving the changes, the Nginx configuration should be regenerated to forward traffic to the new domain name specified in the "Forward Hostname / IP" field. The change should be immediate and effective after a configuration reload. **Screenshots** *(Not applicable for this text-based report, but could show the edit form and the resulting incorrect config file)* **Operating System** - **Hardware:** Raspberry Pi 4 - **OS:** `PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"` - **Environment:** Docker **Additional context** - **Docker Version:** 24.0.5, build 24.0.5-0ubuntu1~22.04.1 - This is a significant usability issue when managing many hosts, as it forces a time-consuming delete-and-recreate process and risks misconfiguration. - The problem appears to be that the backend service does not correctly trigger a rewrite of the Nginx configuration for the specific host when this particular field is changed from an IP to a hostname. - Restarting the NPM container or the Nginx process itself does not resolve the issue; only deletion and recreation of the host works.
Author
Owner

@Araflologo commented on GitHub (Nov 23, 2025):

I have the same problem if you create a Proxy host using a hostname it will not create any configs.

If i use either the docker hostname or .local / .lan it does not work. Full domains still work

<!-- gh-comment-id:3568184356 --> @Araflologo commented on GitHub (Nov 23, 2025): I have the same problem if you create a Proxy host using a hostname it will not create any configs. If i use either the docker hostname or .local / .lan it does not work. Full domains still work
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#3008
No description provided.