Site is accessible by domain in all browsers but Chrome
Solution 1:
Your problem is because you are using a .dev
domain.
The entire .dev
top-level domain (TLD) is on the HSTS preload list and that means you must access it using HTTPS. According to your nginx config snippet, you are only providing HTTP bindings, not HTTPS.
In fact, I am surprised that you are able to access the domain using Firefox, since Firefox has been forcing .dev
to HTTPS since at least mid-2018. You might be using a very old version, in which case you should upgrade immediately.
The easiest way to get HTTPS support on your site is LetsEncrypt. Once you have that set up, your site should work in Chrome.
Solution 2:
Start by verifying that chrome is properly resolving the target site's hostname (FQDN) to the correct IP address, by looking at Chrome's dns cache a few seconds after you try opening the site in chrome. You can view the Chrome dns cache by opening chrome://net-internals/#dns in Chrome.
Depending on whether the FQDN is listed in Chrome's dns cache, and whether the IP is correct, will give you an idea what to do next.
If the FQDN is listed but incorrect, Chrome is getting the wrong IP from somewhere. If its not even listed, then Chrome is not resolving the IP address. Either way you will narrow down what is actually happening.
Some things to try with Chrome.
- Try in a private tab.
- Login to the same computer as a different user. If the behavior is the same, it's a system-wide setting, possibly the Chrome version. If it works as another user, it is a problem in your Chrome profile.
- Try temporarily setting up a fresh Chrome user profile to see if that fixes the issue. If it does it is one of your Chrome settings. You can google where you Chrome profile is located, which varies based on the operating system. All you have to do is move it out of the way while Chrome is closed, then when you re-open Chrome it will generate a new profile. Once you are done verifying, you can delete the new temporary profile, and restore the original. There is lots of information on how to do this, so Google it for screenshots/details if you need to.