Issue with using WWW in URL, Internal Server Error

Hi Everyone!

My website (mygermbusters.com) is not working with https://www.mygermbusters.com but it’s working with https://mygermbusters.com

My domain is: mygermbusters.com
My web server is (include version): nginx
My hosting provider, if applicable, is: digital ocean
I can login to a root shell on my machine (yes or no, or I don’t know): yes
Server OS: ubuntu.

Can anyone assist me to fix this issue?

Thank You,
Navdeep

1 Like

You simply need to add the www to the cert request
[so that it has both names]

You should also check that the site is properly handling both names via the same virtual host.
[presuming they will be providing the exact same content]

Tried these settings below but still not working:

server {

    listen 443 ssl;


    server_name
            mygermbusters.com www.mygermbusters.com
            ;

    root /home/www/mywebsite/;
    ssl on;
    ssl_certificate      <path>/<name>.pem;
    ssl_certificate_key  <path>/<name>.pem;

}

That (if it works) is only half of the solution.
You also need to get a cert with both names on it.

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.