SSL/TLSReverse ProxyCachingCopy Config

Generated nginx.conf

server {
    listen 80;
    server_name example.com;

    root /var/www/html;
    index index.html index.htm;

    location / {
        try_files $uri $uri/ =404;
    }

    gzip on;
    gzip_types text/plain text/css application/json application/javascript text/xml application/xml text/javascript image/svg+xml;
    gzip_min_length 1000;
}

Frequently Asked Questions

What is an nginx server block?
A server block (also called a virtual host) is a configuration section that defines how nginx handles requests for a specific domain or IP address.
Does this create a complete config?
This generates a server block that you paste into your nginx.conf or a site configuration file. It is not a complete standalone config.
Is SSL configuration included?
Yes. When you enable SSL, the tool generates proper HTTPS configuration with certificate paths and HTTP-to-HTTPS redirect.
Share:

Love this tool? Explore 999+ more

Free online tools for images, PDFs, text, code, and more. All running in your browser.

Explore All Tools