Core directives

worker_processes directive

Sets the number of worker processes, or lets Nginx determine a count automatically. Context: main. Default: 1. Auto does not guarantee optimal performance. Partial snippet.

Formal Syntax & Structure

nginx syntaxnginx
worker_processes number | auto;

Parameters & Attributes

NameTypeDescription
number | autostringWorker count or auto

Working Example

Example Snippetnginx
worker_processes 1;
Nginx Reference