[GH-ISSUE #216] cant get domain forward to work though a web domain #189

Closed
opened 2026-02-26 06:31:18 +03:00 by kerem · 1 comment
Owner

Originally created by @strid3r21 on GitHub (Oct 24, 2019).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/216

so ive got a dns address working to foward to my nextcloud server. that works

but ive also got a normal domain web adress www.example.com that has a cname dns forwarded through it.

when i go to www.example.com all i get is the nginx proxy manager defualt site. it doesnt foward it through to the nextcloud server, even tho if i just use the dns address it works just fine.

example - nextcloudexample.ddns.net > netcloud server (WORKS)
but, www.nextcloudexample.com > netcloudexample.ddns.net > nextcloud server (does not work) only sees the proxy manager defult page.

i apologize if this is a simple issue. im new at this and cant figure it out.

Originally created by @strid3r21 on GitHub (Oct 24, 2019). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/216 so ive got a dns address working to foward to my nextcloud server. that works but ive also got a normal domain web adress www.example.com that has a cname dns forwarded through it. when i go to www.example.com all i get is the nginx proxy manager defualt site. it doesnt foward it through to the nextcloud server, even tho if i just use the dns address it works just fine. example - nextcloudexample.ddns.net > netcloud server (WORKS) but, www.nextcloudexample.com > netcloudexample.ddns.net > nextcloud server (does not work) only sees the proxy manager defult page. i apologize if this is a simple issue. im new at this and cant figure it out.
kerem closed this issue 2026-02-26 06:31:18 +03:00
Author
Owner

@chaptergy commented on GitHub (May 11, 2021):

Yes, NPM uses the Host header your browser sends to know where to send you request. So the Host header must contain the value nextcloudexample.ddns.net for this to work. But with a CNAME header the host still remains www.example.com and is not actually changed to nextcloudexample.ddns.net. So NPM receives a request for the host www.example.com, and does not know where to route this, since a host like this does not exist. It then sends you to the default site.

<!-- gh-comment-id:838927703 --> @chaptergy commented on GitHub (May 11, 2021): Yes, NPM uses the Host header your browser sends to know where to send you request. So the Host header must contain the value `nextcloudexample.ddns.net` for this to work. But with a CNAME header the host still remains `www.example.com` and is not actually changed to `nextcloudexample.ddns.net`. So NPM receives a request for the host `www.example.com`, and does not know where to route this, since a host like this does not exist. It then sends you to the default site.
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#189
No description provided.