I logged into Mozilla's Bugzilla. I noticed Firefox did not save my password.
How do I manually add my username and password to Firefox's Saved Password list?
If you're a developer with 3 minutes to spare, this is how to do it without installing another add-on.
On the login page, Inspect Element the username and password fields and take note of their name
(or id
, if no name
is given) attributes. For example on Khan Academy, that would be identifier
for the username and password
for the password.
Inspect Element somewhere on the page. Find a small div or so, that's easiest.
Right click the element in your inspector and choose Edit As HTML
.
Add the following HTML:
<form method=post>
<input name=identifier>
<input type=password name=password>
<input type=submit>
</form>
Replace the names (identifier
and password
) with the names from step #1. Note that you should not replace type=password
, only the name=password
field!
Enter your credentials on the page in this form and hit submit. Firefox will now prompt you to save the credentials. The website will probably burp up an error or ignore the request or something, but we don't care about that.
Why does this work? Some sites deliberately do something funny to prevent you saving the password (the browser's remember password feature is often seen as insecure); other sites just have a funny form mangled beyond recognition for Firefox. Adding this simple form makes Firefox detect it and when you enter your credentials, it will prompt you to save them.
Now on the login page, as long as the fields actually have name
attributes at all I guess (and it probably needs to be wrapped in a <form>
too, I don't know), Firefox will typically recognize the fields and be able to fill them for you.
Alternatively, it might simply be that the website has autocomplete=off
set on the field. You can remove this as follows:
form
element is highlighted, look for the attribute that says autocomplete='off'
(You may have to scroll up and look for the form
element in the Inspector
tab)off
to on
name
attribute but only an id
, you can just copy those - works like a charm!
Commented
May 16, 2018 at 19:03
form
to which the login inputs belong and submit it. E.g. you can click on an input field with the inspector, and do $0.form.submit()
($0
being the last thing you inspected). This should get FF to prompt you to save the password.
Since Firefox 70.0 this is now a built-in feature in the password manager (Firefox Lockwise). To access it navigate to the saved password list or type about:logins
in the address bar; At the bottom left corner click the Create New Login.
PS: Solution to my specific problem - App Store Connect not saving my credentials - I put https://appleid.apple.com
as the website address when adding a new login.
To simplify the advice by the top poster, the reason the feature doesn't work on some websites, whilst working on others, is due to the non-standard and/or malicious code used by enterprise websites like Hertz.com.
In the case of Hertz.com, I was able to make Firefox save the password by doing the Inspect Element on the Login button, and then doing the Edit As HTML trick, and changing the type
of button
from button
to submit
; without this trick, even the Remember Password bookmarklet wouldn't work:
-<button type="button" class="primary gblFloatLeft" id="loginBtn">
+<button type="submit" class="primary gblFloatLeft" id="loginBtn">
Login
</button>
In short, doing Inspect Element and then Edit As HTML to fix all the malicious and non-compliant HTML works wonders!
I know this question is old, but I figured I'd throw in my solution anyway.
Since Firefox sometimes fights me on certain websites, the solution I've developed is using another browser such as Chrome and saving the username/password there. Then you can import the login information for the specific website from that other browser.
After you've saved the password in the other browser, you can do the import by following these steps:
*These steps are valid for Firefox version: 62.0.2. I imagine it's similar for other versions, but can't say for sure.
when I need to add password to Firefox I use FEBE Add-on to extract my passords to Json file edit it an re import the file again. i hop that help.
I'm author of Save my Password addon for Firefox that solves this problem.
It creates dummy input fields on the page where you enter (or update) your credentials and when you click the "Save my Password!" button, Firefox will ask you to save (or update) your password for the page.
https://addons.mozilla.org/en-US/firefox/addon/save-my-password/
You are all creating a lot more work for yourselves than seems necessary.
Create a CSV file.
You can do this with an ordinary text editor: or go into Firefox Options, Security, Passwords, and export your current passwords into a CSV file instead of the default XML file.
Edit this file with a text editor (or spreadsheet).
The beginning of the file should look like this:
# Generated by Password Exporter; Export format 1.1; Encrypted: false
"hostname","username","password","formSubmitURL","httpRealm","usernameField","passwordField"
Edit one of the existing entries to change the data to match the entry you want to add, such as:
"http://192.168.0.1","admin","modempassword","","","login","password"
The last two entries will probably have to match the field names already on the web page as previously described. I semi-guessed "login" and "password" when I tried this.
Go back into Firefox Options Security and import the CSV file.
You now have a new entry in your password manager. No fiddling around with Add-ons (many of which won't work with the current ESL releases) or adding and possibly messing up HTML. If you make a mistake in the CSV file the worst that can happen is that Firefox won't import it and you'll have to edit it and fix the mistake.
The top answer works but there's no need to create a fake form in most cases. Just inspect the login button and change it's type from "button" to to "submit". Enter your password and hit the button, it will prompt you to save but probably not log you in as it's expecting a vanilla button. Refresh the page to undo your changes, enter your email and voila, it should autofill your password.
More simple solution worked for me. No need to add new form. I just added <input type=submit>
to original login form and another button appeared. First I pressed new button and FF save password dialog appeared. Second I pressed original button and logged in.
The best idea is not to depend on the browser's caching of the passwords, since the mechanism will surely change over time, and there will always be a problem when moving from one computer to another or when using more than one computer.
It is much safer and easier to use a specialized product that will keep your passwords safe and available on all computers and for all browsers and programs.
The best one I have found is LastPass, where the passwords and the contents of all the fields in their containing forms are encrypted and saved on their servers. The encryption is done on your side and using your master password for protection, so the LastPass website has no idea of what is stored on their own servers.
LastPass integrates with the browser to remember passwords and all the other fields that you have entered into the form, as sometimes more than just the password is required (for example the email or user-name). You may also manually enter this data for websites or programs into the LastPass repository.
The power of this concept was proven when the LastPass website was hacked. The results were rather minor for the users, as the most that the hackers managed to get were the password hints, as the encrypted passwords themselves were useless to them without the master password.
Another product is the open-source KeePass, which is also very popular among users.