Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Nginx Config?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/adityaaatiwari-nginx-config-anvil)
---
name: nginx-config
description: Configure Nginx reverse proxies, upstream keepalives, TLS termination, timeouts, headers, and rate limits safely
---
<!-- Generated by `anvil plugin build` from catalog/. Edit the catalog, not this file. -->
# Nginx config
Use when editing Nginx server blocks, upstreams, or edge proxy configurations.
## Upstreams and timeouts
- Set explicit `proxy_connect_timeout`, `proxy_send_timeout`, and `proxy_read_timeout`; use `keepalive 32;` on `upstream` blocks paired with `proxy_http_version 1.1;` and `proxy_set_header Connection "";`.
- Always forward client context accurately: `Host`, `X-Real-IP`, `X-Forwarded-For`, and `X-Forwarded-Proto`.
- Bound uploads cleanly with `client_max_body_size` per location instead of loosening limits globally.
## Security and caching
- Include `add_header ... always;` when adding `Strict-Transport-Security`, `X-Content-Type-Options: nosniff`, and CSP (noting Nginx drops parent-level `add_header` inside blocks that declare any `add_header`).
- Disable `server_tokens off;` and never put `alias` inside a location lacking matching trailing slashes to avoid path traversal.
- Place `limit_req_zone` and `limit_req ... nodelay` on login and expensive API routes.
## Verify
Run `nginx -t` after every edit, reload with `nginx -s reload`, and test proxy headers and error codes via `curl -I`.