HTTP limit req directives

limit_req directive

http, server, location; default burst 0. Applies admission control; delay threshold available since 1.15.7.

Formal Syntax & Structure

nginx syntaxnginx
limit_req zone=name [burst=number] [nodelay | delay=number];

Parameters & Attributes

NameTypeDescription
zonezone=nameSelect a zone declared in http.
burstburst=numberMaximum excess requests tolerated before rejection; default zero.
delay_policynodelay | delay=numberChoose immediate handling of allowed excess or the excess threshold for delaying; mutually exclusive. Does not increase sustained rate.

Working Example

Example Snippetnginx
limit_req zone=search_rate burst=2 nodelay;
Nginx Reference