New install Nextcloud + Nginx = 404 cannot reach

Hey gang, was wondering if you could help out a newb. Ive been following a guide from Luke’s Smith website.

I got as far as setting up a website and it’s running great.

The part that I am having an issue is when I setup the “nextcloud” website under “/etc/nginx/sites-available/” then make a link to “/etc/nginx/sites-enabled/”.

When one or more sites are enabled in that folder I get the 404 error trying to reach “”. When it’s just the nextcloud link in “/etc/nginx/sites-enabled/” I am able to get to the nextcloud setup page using the

I believe the html for the nextcloud page may be the issue at hand. You can see what I used following this website:

Any input would be wonderful!

You need to understand how nginx determines which server/location block to use when processing a request.

This tutorial at digitalocean helped me a lot for similar problems like yours: