Forms & Inputs
HTML <meter> Tag
The <meter> tag defines a scalar measurement within a known range, or a fractional value. This is also known as a gauge.
Definition and Usage
The <meter> tag defines a scalar measurement within a known range, or a fractional value. This is also known as a gauge.
Standard Syntax:
<meter>...</meter>Interactive ExampleRunnable
HTML <meter> Example
htmlLive code demonstration for the <meter> tag. Click "Try it Yourself" to edit and experiment in real time.
<div style="font-family: system-ui, sans-serif; padding: 16px; background: #ffffff; border-radius: 8px; border: 1px solid #e2e8f0; color: #0f172a;">
<label for="disk_c">Disk usage C:</label>
<meter id="disk_c" value="2"
min="0" max="10">2 out of 10</meter><br>
<label for="disk_d">Disk
usage D:</label>
<meter id="disk_d" value="0.6">60%</meter>
</div>Attributes for <meter>
6 Supported Attributes| Attribute | Values | Default | Description |
|---|---|---|---|
| form | form_id | none | Specifies which form the <meter> element belongs to |
| high | number | none | Specifies the range that is considered to be a high value |
| low | number | none | Specifies the range that is considered to be a low value |
| max | number | none | Specifies the maximum value of the range |
| min | number | none | Specifies the minimum value of the range. Default value is 0 |
| optimum | number | none | Specifies what value is the optimal value for the gauge |
Global Attributes
The <meter> tag also supports the standard global attributes in HTML, including class, id, style, title, hidden, and data-*.
Event Attributes
The <meter> tag supports event attributes in HTML, such as onclick, onmouseover, onfocus, and more.
Browser Compatibility
ChromeEdgeFirefoxSafariOpera
More Tags in Forms & Inputs
View All 123Tags →<button>The <button> tag defines a clickable button.<datalist>The <datalist> tag specifies a list of pre-defined options for an <input> element.<fieldset>The <fieldset> tag is used to group related elements in a form.<form>The <form> tag is used to create an HTML form for user input.<input>The <input> tag specifies an input field where the user can enter data.<label>The <label> tag defines a label for several elements: