Scroll to navigation

GUNICORN(1) User Commands GUNICORN(1)

NAME

gunicorn - HTTP/WSGI/ASGI server

DESCRIPTION

usage: gunicorn [OPTIONS] [APP_MODULE]

options:

show this help message and exit
show program's version number and exit
:ref:`The Gunicorn config file<configuration_file>`. [./gunicorn.conf.py]
The socket to bind. [['127.0.0.1:8000']]
The maximum number of pending connections. [2048]
The number of worker processes for handling requests. [1]
The type of workers to use. [sync]
The number of worker threads for handling requests. [1]
The maximum number of simultaneous clients. [1000]
The maximum number of requests a worker will process before restarting. [0]
The maximum jitter to add to the *max_requests* setting. [0]
Workers silent for more than this many seconds are killed and restarted. [30]
Timeout for graceful workers restart in seconds. [30]
The number of seconds to wait for requests on a KeepAlive connection. [2]
The maximum size of HTTP request line in bytes. [4094]
Limit the number of HTTP headers fields in a request. [100]
Limit the allowed size of an HTTP request header field. [8190]
Restart workers when code changes. [False]
The implementation that should be used to power :ref:`reload`. [auto]
Extends :ref:`reload` option to also watch and reload on additional files [[]]
Install a trace function that spews every line executed by the server. [False]
Check the configuration and exit. The exit status is 0 if the [False]
Print the configuration settings as fully resolved. Implies :ref:`check-config`. [False]
Load application code before the worker processes are forked. [False]
Disables the use of ``sendfile()``. [None]
Set the ``SO_REUSEPORT`` flag on the listening socket. [False]
Change directory to specified directory before loading apps. [/build/reproducible-path/gunicorn-25.1.0]
Daemonize the Gunicorn process. [False]
Set environment variables in the execution environment. [[]]
A filename to use for the PID file. [None]
A directory to use for the worker heartbeat temporary file. [None]
Switch worker processes to run as this user. [999]
Switch worker process to run as this group. [999]
A bit mask for the file mode on files written by Gunicorn. [0]
If true, set the worker process's group access list with all of the [False]
Front-end's IP addresses or networks from which allowed to handle [127.0.0.1,::1]
The Access log file to write to. [None]
Disable redirect access logs to syslog. [False]
The access log format. [%(h)s %(l)s %(u)s %(t)s "%(r)s" %(s)s %(b)s "%(f)s" "%(a)s"]
The Error log file to write to. [-]
The granularity of Error log outputs. [info]
Redirect stdout/stderr to specified file in :ref:`errorlog`. [False]
The logger you want to use to log events in Gunicorn. [gunicorn.glogging.Logger]
The log config file to use. [None]
The log config to read config from a JSON file [None]
Address to send syslog messages. [udp://localhost:514]
Send *Gunicorn* logs to syslog. [False]
Makes Gunicorn use the parameter as program-name in the syslog entries. [None]
Syslog facility name [user]
Enable stdio inheritance. [False]
The address of the StatsD server to log to. [None]
A comma-delimited list of datadog statsd (dogstatsd) tags to append to []
Prefix to use when emitting statsd metrics (a trailing ``.`` is added, []
Enable socket backlog metric (only supported on Linux). [False]
A base to use with setproctitle for process naming. [None]
A comma-separated list of directories to add to the Python path. [None]
Load a PasteDeploy config file. The argument may contain a ``#`` [None]
Enable PROXY protocol support. [off]
Front-end's IP addresses or networks from which allowed accept [127.0.0.1,::1]
The protocol for incoming connections. [http]
IPs allowed to send uWSGI protocol requests (comma separated). [127.0.0.1,::1]
SSL key file [None]
SSL certificate file [None]
SSL version to use (see stdlib ssl module's). [2]
Whether client certificate is required (see stdlib ssl module's) [0]
CA certificates file [None]
Suppress ragged EOFs (see stdlib ssl module's) [True]
Whether to perform SSL handshake on socket connect (see stdlib ssl module's) [False]
SSL Cipher suite to use, in the format of an OpenSSL cipher list. [None]
HTTP protocol versions to support (comma-separated, order = preference). [h1]
Maximum number of concurrent HTTP/2 streams per connection. [100]
Initial HTTP/2 flow control window size in bytes. [65535]
Maximum HTTP/2 frame payload size in bytes. [16384]
Maximum size of HTTP/2 header list in bytes (HPACK protection). [65536]
Set a PasteDeploy global config variable in ``key=value`` form. [[]]
Permit requests employing obsolete HTTP line folding mechanism [False]
Strip spaces present between the header name and the the ``:``. [False]
Permit HTTP methods not matching conventions, such as IANA registration guidelines [False]
Permit HTTP version not matching conventions of 2023 [False]
Transform received HTTP methods to uppercase [False]
A list containing upper-case header field names that the front-end proxy [SCRIPT_NAME,PATH_INFO]
Configure how header field names are mapped into environ [drop]
Event loop implementation for ASGI workers. [auto]
Control ASGI lifespan protocol handling. [auto]
Grace period (seconds) for ASGI apps to handle client disconnects. [3]
The root path for ASGI applications. []
Dirty applications to load in the dirty worker pool. [[]]
The number of dirty worker processes. [0]
Timeout for dirty task execution in seconds. [300]
The number of threads per dirty worker. [1]
Timeout for graceful dirty worker shutdown in seconds. [30]
Unix socket path for control interface. [gunicorn.ctl]
Permission mode for control socket. [384]
Disable control socket. [False]

SEE ALSO

The full documentation for gunicorn is maintained as a Texinfo manual. If the info and gunicorn programs are properly installed at your site, the command

info gunicorn

should give you access to the complete manual.

February 2026 gunicorn (version 25.1.0)