# www.example.org redirection server { listen 443 ssl http2; listen [::]:443 ssl http2; ssl_certificate /etc/letsencrypt/live/example.org/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/example.org/privkey.pem; ssl_trusted_certificate /etc/letsencrypt/live/example.org/chain.pem; server_name www.example.org; rewrite ^(.*) https://example.org$1 permanent; }