New! My 44-page ebook "CSS in 44 minutes" is out! 😃

Get it now →

# button

Defines a clickable button.

Example: Copy

<button>
  Submit form
</button>

name

Defines the unique identifier for that button within the form. It allows the server to access each button's value when submitted.

"submit_button"

The name value must be unique within the context of a <form> container.

It can only contain alphanumeric characters a-z A-Z 0-9 and some special characters like - _… but no space.

value

The value sent to the server when submitting the form.

"primary"

The server will receive the value primary.

type

Defines the button type.

"submit"

The button sends the form data to the server.

"reset"

The button resets the form.

disabled

Disables the button.

No value required.

autofocus

Sets focus on the element when the web page loads.

No value required.