Here is how you can fix the problem of automatic redirecting of website to https in Firefox browser.
Step 1: Disable URL autofill feature of Firefox browser
- In the address bar in Firefox browser, type about:config and press Enter
- Choose 'Accept the Risk and Continue' in the warning page to continue
- Type "urlbar.autofill" in the filter box
- Find "browser.urlbar.autoFill", change from true to false (double click)
- Clear entire browser history and data
- Restart browser
Step 2: Disable Firefox extension
The Firefox extension like "HTTPS Everywhere" attempts for HTTPS connection to every website that you browse. You must uninstall any similar extension.
Step3: Verify HTTPS-Only Mode
- Go to Options menu in Firefox
- In Privacy & Security tab, you will find HTTPS-Only Mode at the end.
- Ensure "Don't enable HTTPS-Only Mode" is checked
Step 4: Remove Cache in SiteSecurityServiceState.txt file
- Exit Firefox
- Navigate to %AppData%\Roaming\Mozilla\Firefox\Profiles\52729jwc.default (a random folder name will appear for you)
- Open SiteSecurityServiceState.txt file in notepad
- Remove the line that contains your website name in it
Here is additional note for Linux users: You will find the file in /home/<USER>/.mozilla/firefox/profile.default/SiteSecurityServiceState.txt
Step 5: Applicable only if the website is hosted or managed by you
If you are hosting this website, HSTS might have been accidentally or by default enabled. You must verify your webserver settings and fix it.
For F5 Customers:
In my case, I was still experiencing 'https redirect' issue for a sub domain, even after I followed all the four steps. The problem is finally figured out with F5 HSTS configuration. Once I unchecked 'Include Subdomains' option under HTTP Profile, I never had this issue again.