Firefox redirects localhost to HTTPS

So, here is my experience. I had the same issue.

At first : try in private mode. If you dont have the problem, do this :

When you open a new tab, you have to go to the Firefox configuration ("about:config") you check "I'll be careful I promise". Then in the search field you type autofill, you have to set browser.urlbar.autofill to false and if it still doesn't work you can delete the history, it should fix it. It worked for me.

I think the problem comes from the fact that I opened once localhost in https so the browser wants to do it every time.


This happened to me after I worked on a site that used https and then tried switching back to one that does not.

Unfortunately, the accepted answer did not work for me. What I needed to do was:

  1. Open the Firefox History (ctrl+h)
  2. Find the page (127.0.0.1:3000, in my case)
  3. Right-click it and choose the last option: "Forget About This Site"

If you use localhost - with our without port - to access your page, then you will notice that localhost does not show up in your history. This makes it impossible to access the "Forget About This Site" option.

Fear not! You can work around that issue.

  1. Visit your site using 127.0.0.1 instead of localhost. So, for example, localhost:3000 becomes 127.0.0.1:3000.
  2. Now open the Firefox History (ctrl+h)
  3. Find the page (127.0.0.1), right-click, and "Forget About This Site"
  4. Now, access localhost and you will find that it works again. This is because forgetting about 127.0.0.1 cleared data for both 127.0.0.1 as well as for localhost.

Tags:

Firefox

Https