Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

Bootstrap5 Range Input

Bootstrap5 Range Input

To set up a range input, you can in input element. type="range" and use the .form-range class:

Range:

Example

<label for="customRange" class="form-label">

Custom range

label

<input type="range" class="form-range" id="customRange">

Try it »

Step

By default, the step is 1, which can be set through the step attribute:

Example

<input type="range" class="form-range" step="10">

Try it »

Maximum and minimum values

By default, the minimum value is 0 and the maximum value is 100, which can be set through the min (minimum) or max (maximum) attributes:

Example

<input type="range" class="form-range" min="0" max="4">

Try it »