Input Range min Attribute
Definition and Usage
min
Set or return the value of the min attribute of the slider control.
The HTML min attribute specifies the minimum value of the slider control.
Tip:The min attribute is usually used with max attribute Used together to create a valid value range.
Tip:To set or return the value of the max attribute, use max attribute.
See also:
HTML Reference Manual:HTML <input> min Attribute
Example
Example 1
Get the minimum value allowed by the slider control:
var x = document.getElementById("myRange").min;
Example 2
Change the minimum value:
document.getElementById("myRange").min = "50";
Syntax
Return the min attribute:
rangeObject.min
Set the min attribute:
rangeObject.min = number
Attribute Value
Value | Description |
---|---|
number | Specifies the minimum value allowed for the slider control. |
Technical Details
Return Value: | A string value representing the minimum allowed value. |
---|
Browser Support
The numbers in the table indicate the first browser version that fully supports this attribute.
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
Support | 10.0 | Support | Support | Support |