33
Views
5
Comments
How to hide input type password value attribute in the inspect element

Is there a way to hide the input password value in the inspect elements?

Appreciate your help


2024-12-02 13-16-47
Vipin Yadav

Hi @Ruzzel John Bisnar,

Unfortunately, no. If the user has access to browser tools, they can inspect the DOM.

Thanks,

Vipin Yadav 

2024-09-12 02-43-38
Deepsagar Dubey

Hi @Ruzzel John Bisnar 

Who do you want to hide it from? Yourself? 

You can't. It's an input field. The value property of an input field is going to be visible through the inspect element option of the dev tools. 

Thanks
Deep

UserImage.jpg
Ruzzel John Bisnar

I noticed it on the other web app made in OutSystems that the value attribute is not showing even if the input type = password is not empty


I just want to add this feature for security purposes especially for those uses the auto-fill


2024-09-12 02-43-38
Deepsagar Dubey

Hi @Ruzzel John Bisnar 

Okay, I did some workaround in reactive login screen on browser, and found below scenarios  -

1. Inside Form - if you use input fields inside form it'll show you the value attribute in web browser inspect element.

2. Outside form - if you use input fields outside form it'll not show you the value attribute in web browser inspect element. 

You can try to implement in code, if it'll help you.

But to be honest removing form tag is not a solution because it'll lead security concern such as CSRF token and default form validation mechanism. 

Thanks
Deep

2021-11-12 04-59-31
Manikandan Sambasivam

Hi,

It's not possible to hide the password from being visible in browser inspection tools. Could you please share your use case?

  1. If you need to display the password in a form, consider showing it in an encrypted format.

  2. If you need to validate the password, capture the user input and perform the validation on the server side. 

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.