Skip to content
Related Articles

Related Articles

Improve Article

How do we take password input in HTML forms ?

  • Last Updated : 22 Jul, 2021

In this article, we learn how to we create a password input field in html, This can be done by using the <input> tag with type attribute which is set to value “password“.  It involves sensitive information about the data of the user. The text in the input password field will be change into bullets in the view of hiding from the third party. 


<input type="password">

Example Code:


<!DOCTYPE html>
         How do we take password input in HTML forms?
   <body style="text-align:center;">
      <h1 style="color:green;">
      <h2>How do we take password input in HTML forms? </h2>
         Email:<input type="email" id="myemail"><br>
         Password:<input type="password" id="mypasswd"



Attention reader! Don’t stop learning now. Get hold of all the important HTML concepts with the Web Design for Beginners | HTML  course.

My Personal Notes arrow_drop_up
Recommended Articles
Page :