local site is automatically on https on chrome

2019-08-18 01:42发布

问题:

I had an update on my computer ( ubuntu) and now my host that i had in local is not working anymore : This site can’t be reached www.site.dev refused to connect. Try:

Checking the connection Checking the proxy and the firewall ERR_CONNECTION_REFUSED

This same url works on firefox and postman for my api so I am a bit lost!

回答1:

Forcing HTTPS is a new feature of chrome. More on it here.

Apparently, it cannot be disabled. One workaround is changing your .dev domain to .test, .local or similar.



回答2:

I just saw this post and I have my explanation.
https://ma.ttias.be/chrome-force-dev-domains-https-via-preloaded-hsts/

Chrome is now redirecting all .dev to https... so I have to change my extension of local website or use another browser.

For those ones that have same issue, don't use chrome or rename your vhost and host file to another extension because .dev won't work chrome in http.