html – Prevent Browser Autocomplete on Password


I have a lock screen that logs the user out due to inactivity, asking only for the password to login again. It turns out that this screen is useless if autocomplete is turned on, since anyone can use this pc and enter this user's account. I did a lot of research and saw that autocomplete="off" , for example, is already being ignored by browsers.

Does anyone know a working method to solve this problem? By JQuery, a plugin anything like that. Or is it really just the client disabling the password guard option?


Browsers probably only complete the first password field, try adding an invisible password field ( style="opacity: 0;position: absolute" ) and then insert into the code what you're actually going to use.

Scroll to Top