<button>...</button>

HTML4 HTML5

Creates a clickable button containing text or inner HTML elements (e.g., images, icons, bold text).

Both opening and closing tags are required.

Attributes:

type="..." - Button behavior: submit (default, submits form), reset (resets form), or button (for JS scripting).

disabled - Disables interaction with the button (unclickable).

name="..." / value="..." - Name and value submitted upon clicking the button within a form.

Example

Code:

<button type="button" style="background-color: #28a745; color: white; border: none; padding: 8px 16px; border-radius: 4px; cursor: pointer; font-size: 14px;"> <strong>Click here</strong> </button>

The browser will interpret this code as follows: