HTML Input Types

The HTML input type is used to control the web-based forms to accept data from the user. Users can enter data using forms and these input types elements in HTML help to send data to the server and makes it easier for the browser to understand that the data is valid or not.

There are so many input types in HTML like HTML input email, date, button, etc.. let’s see the most common HTML input type attributes.

Common HTML form input types

  1. Text Field: It is used for one-line text input fields.
  2. Password: It is used for one-line Password input fields.
  3. Submit: Specifies a submit button to submit the form to the server.
  4. Reset: Reset all values in the form.
  5. Radio: Allows select one option.
  6. Checkbox: Allow selecting multiple options form.
  7. Button: A clickable button to perform Task.
  8. File: Defines to select the file from device storage.
  9. Image: Defines a graphical submit button. (form html upload file)

You can try all these examples on your PC, laptop or using an online HTML Editor.

Form Input Restrictions

  1. Disabled: disabled the input field.
  2. Max: maximum value for an input field.
  3. Maxlength: maximum number of characters for an input field.
  4. Min: minimum value for an input field.