diff --git a/nginx/sites-available/www-redirect.conf b/nginx/sites-available/www-redirect.conf index f477b1d..d8dd4d8 100644 --- a/nginx/sites-available/www-redirect.conf +++ b/nginx/sites-available/www-redirect.conf @@ -6,7 +6,8 @@ server { # don't forget to tell on which port this server listens listen 80; # listen on the www host - server_name www.example.com + server_name www.example.com; + # and redirect to the non-www host (declared below) return 301 $scheme://example.com$request_uri; }