The proxy_pass directive, valid in a location, if in location, or limit_except context, sets the protocol and address of a proxied server and an optional URI to which the location is mapped. The protocol is http or https; the address is a domain name or IP address with an optional port, a server group, or a UNIX-domain socket path written after the word unix and enclosed in colons. If a domain name resolves to several addresses, all of them are used in a round-robin fashion. The value can contain variables; in that case a domain name is first searched among the described server groups and, if not found, determined using a resolver. URI handling depends on whether proxy_pass carries a URI: with one, the part of the normalized request URI matching the location is replaced by the directive's URI; without one, the request URI is passed to the server in the same form as sent by the client, or the full normalized request URI when a changed URI is processed. Before version 1.1.12, the original request URI might have been passed instead of the changed URI in some cases. Scope: nginx. Reviewed October 4, 2026.
Reverse proxying with proxy_pass
Document v1 · published by Koskamo editorial · updated 2026-10-04
Source and provenance
- Original source
- nginx.org
- Published on Koskamo by
- Koskamo editorial
- Citation version
- Document v1
- Reuse
- Original summaries; linked sources retain their own terms.