HTTP directives

proxy_pass_request_headers directive (HTTP)

Contexts: http, server, location. Default: on. Controls forwarding of original client request headers, not the explicit proxy-generated contract.

Formal Syntax & Structure

nginx syntaxnginx
proxy_pass_request_headers on | off;

Parameters & Attributes

NameTypeDescription
stateon | offForward original request fields when on; explicit proxy-generated fields are separate.

Working Example

Example Snippetnginx
proxy_pass_request_headers off;
Nginx Reference