The default value of the Host header nginx sends upstream is $proxy_host, which is the host and port from the proxy_pass directive, not the host the client requested. An application behind the proxy therefore sees Host values like backend or 127.0.0.1:3000.
The consequences are absolute redirects pointing at an internal name, generated links and canonical URLs with the wrong host, and virtual-host routing on the upstream selecting the wrong site. Frameworks that validate an allowed-hosts list reject the request outright.
Set proxy_set_header Host $host; in the location or server block. Use $host rather than $http_host, because $host falls back to the server name when the client sends no Host header and it strips the port. The related defaults worth setting at the same time are X-Forwarded-For, X-Forwarded-Proto $scheme, and X-Real-IP, none of which nginx adds on its own. Note that proxy_set_header directives are inherited from the enclosing block only if the current block defines none; defining a single one discards all inherited ones.