Firefox VIEW SOURCE shows login page

Apparently, this has always been an issue with Firefox's "view source". Here's a bug that was reported 13 years ago describing the process by which Firefox loads the page's source code by refreshing/re-requesting the whole page.

It is possible that an uncached version of the page is being downloaded, and thus, showing different results for the debugger and the source. It all depend's on how the login data is being handled (cookies, session variables, server variables, etc.)

Here's another Steckoverflow question on a related topic. I hope this can give you an idea on how to solve the issue you're having.


As of March 2021, FF 86 there is a workaround:

  1. Open the Web dev tools (F12)
  2. Go to the Network tab
  3. Refresh
  4. Select the row with the request of the page (usually the first)
  5. Right mouse button -> Copy -> Copy Response
  6. Paste in your favorite editor

You will see the unmodified source.


Slight modification to Ognyan's answer above, but you can't add pictures to a comment. Do what he says:

  • Open dev tools
  • Load page
  • Find the page load (should be the first request on the Network tab)
  • Click, then in the details section to the right click on the Response section

Now, instead of copying/pasting anything into an editor, look for the "raw" toggle button and switch it on. You'll see the raw source:

enter image description here