Inspect nginx configuration for deprecated TLS versions, a proxy that drops the client address, the add_header inheritance trap and unsafe uses of if.
Waiting for nginx configuration
Nothing is run and no origin is contacted.
The findings appear here
A deprecated TLS version, a proxy that drops the client address, an add_header in a location that discards every inherited header, and `if` where it is unsafe.
This reads the configuration as text. It does not run `nginx -t`, does not know nginx's directive table, and contacts nothing — so it cannot tell you that a directive is invalid in its context, that an upstream resolves, or that a certificate file exists. Run `nginx -t` before reloading.
Nginx Configuration Inspector runs entirely on your device — nothing is run, no origin is contacted and your configuration is never uploaded.
You’re on the Free plan. Compare plans
The finding that surprises people most is the add_header one. nginx does not merge add_header across levels: a location with any add_header of its own replaces the entire inherited set. Every header set at the server level — HSTS included — is silently absent inside that location, and the only way to notice is to check the response from that specific path.
That is the reason a site passes a security-header scan on `/` and fails on `/api`, and it is almost never the explanation anyone reaches for.
The proxy header checks look upward before complaining, because `proxy_set_header` at the server or http level is inherited. A tool that only reads the location block reports three false positives on a perfectly good configuration, which trains you to ignore it.
The trailing-slash difference is a note rather than a warning, because both forms are legitimate. With no path on `proxy_pass`, nginx passes the URI through unchanged; with a trailing slash it strips the location prefix. Which you want depends on the upstream, so flagging one as wrong would be wrong half the time.
It tokenises rather than matching lines, because a `#` inside a quoted string is not a comment, a `;` inside one does not terminate a directive, and a brace inside one does not open a block — so a Content-Security-Policy header breaks every line-based reader. Nothing is run: `nginx -t` knows the directive table and this does not.
Because nginx does not merge add_header across levels. Any location that sets a header of its own replaces the whole inherited set, so every server-level header vanishes inside it. You have to repeat them in that location. This reports it whenever both levels set one.
It depends on the upstream, which is why this is a note and not a warning. Without a path, nginx passes the full original URI through. With a trailing slash it strips the location prefix, so `/api/users` arrives as `/users`. Both are correct for different upstreams.
Because nginx's own documentation does. Only `return` and `rewrite ... last` behave predictably there; anything else can skip directives or crash. `try_files`, a `map`, or a separate location block usually expresses the same intent safely.
No. `nginx -t` knows every directive and which contexts it is valid in; this knows none of that, so it will accept a directive that does not exist. It finds problems of intent — dropped headers, dead TLS versions, the inheritance trap — that `nginx -t` passes without comment.