The reset Type

The Current State of HTML5 Forms

<input type=reset>
<input type=reset value="Clear Form">

Live Demo

Uncheck me
Click me
Type something in
Then reset the form

 


Firefox

Safari

Safari

Chrome

Opera

IE

Android

The Low Down

The reset input type creates a button that resets the form to the default values.

  • If the value attribute is present, the value of that attribute will be the text on the button. If not, the default wording on the reset button is “Reset”.
  • The reset button brings the form back to it’s initial, default state. It doesn’t necessarily clear the form: if the form was initially blank, it will be cleared. If, by default, any data was pre-filled, checkboxes checked, etc, the original values will be reset when the button is clicked.
  • If the user checked a radio button, the reset button is the only non-programmatic way of deselecting the same named radio button group.
  • The name attribute is not necessary as the name and value of the reset are NOT submitted along with the form.
  • While the form attribute is valid, since it resets the form, many attributes like autocompletedirname,formaction,formmethodformenctypeformnovalidateformtarget, and inputmode are not valid for the reset button.

Our Cookie Policy and Privacy Policy outline how we use cookies to help personalize content, tailor and measure our marketing, and improve your user experience. I agree to use of cookies for these purposes.