---
id: "nginx-limit-req"
type: "component"
kind: "rate-limiter"
provider: "default"
category: "edge"
docs: "https://nginx.org/en/docs/http/ngx_http_limit_req_module.html"
url: "https://localhost:3000/catalogue/components/nginx-limit-req"
---

# NGINX limit_req

NGINX leaky-bucket request rate limiting module.

| | |
|---|---|
| Provider | [default](https://localhost:3000/catalogue?provider=default) |
| Kind | [Rate limiter](https://localhost:3000/catalogue/kinds/rate-limiter) |
| Category | Edge |
| Official docs | [https://nginx.org/en/docs/http/ngx_http_limit_req_module.html](https://nginx.org/en/docs/http/ngx_http_limit_req_module.html) |

## Properties

| property | type | values | required | kind default | this component |
|---|---|---|---|---|---|
| `algorithm` | enum | `token-bucket`, `leaky-bucket`, `sliding-window`, `fixed-window`, `adaptive` | no | "token-bucket" | **"leaky-bucket"** |
| `atomicOps` (advanced) | boolean | — | no | true | inherited |
| `burst` | integer | — | no | 0 | inherited |
| `distributed` | boolean | — | no | false | **false** |
| `failMode` | enum | `open`, `closed` | no | "open" | inherited |
| `managed` | boolean | — | no | false | inherited |
| `placement` | enum | `edge`, `gateway`, `sidecar`, `in-process` | no | "gateway" | **"gateway"** |
| `scope` | enum | `global`, `user`, `ip`, `api-key`, `concurrency` | no | "user" | **"ip"** |

Bold values are the ones this component pins.

## Rules that apply · 0

No rule selects this kind or its category.

## Other products of the same kind · 6

- [Cloudflare Rate Limiting](https://localhost:3000/catalogue/components/cloudflare-rate-limiting.md) `cloudflare-rate-limiting` — cloudflare
- [Cloudflare Waiting Room](https://localhost:3000/catalogue/components/cloudflare-waiting-room.md) `cloudflare-waiting-room` — cloudflare
- [Envoy rate limit service](https://localhost:3000/catalogue/components/envoy-ratelimit.md) `envoy-ratelimit` — default
- [In-process rate limiter](https://localhost:3000/catalogue/components/in-process-limiter.md) `in-process-limiter` — default
- [Generic rate limiter](https://localhost:3000/catalogue/components/rate-limiter.md) `rate-limiter` — default
- [Redis rate limiter](https://localhost:3000/catalogue/components/redis-rate-limiter.md) `redis-rate-limiter` — default

## Use it in a design

```yaml
nodes:
  - { id: "nginx-limit-req", component: "nginx-limit-req" }
```

## Source (`component` YAML, verbatim)

```yaml
# yaml-language-server: $schema=../../schema/component.schema.json
# NGINX limit_req: leaky-bucket per key (typically client IP), shared memory per instance, no burst unless configured.
schemaVersion: "1"
type: "component"
id: "nginx-limit-req"
kind: "rate-limiter"
provider: "default"
docs: "https://nginx.org/en/docs/http/ngx_http_limit_req_module.html"
defaults:
  algorithm: "leaky-bucket"
  scope: "ip"
  placement: "gateway"
  distributed: false
properties:
  burst:
    type: "integer"
    default: 0
```

Human page: https://localhost:3000/catalogue/components/nginx-limit-req
