Ajouter

Lorem ipsum

Lorem ipsum

Design

5 min

How to Create a Styled Range Input (Slider) in Webflow

Learn how to style a range input in Webflow with custom CSS and display the value in real time.

In this tutorial, Sandro, cofounder of the Gemeos Webflow agency, shows you how to style a range input (slider) in Webflow so you can fully customize it with CSS.

Example

Monthly budget 50 k€
0 k€ 100 k€

CSS pseudo-elementBrowserTargets
::-webkit-slider-thumbChrome, Safari, EdgeThe draggable thumb
::-webkit-slider-runnable-trackChrome, Safari, EdgeThe slider track
::-moz-range-thumbFirefoxThe draggable thumb
::-moz-range-trackFirefoxThe slider track

1. Add a range input in a Webflow embed

In an Embed, paste this HTML. Add the ID range-slider and the ID range-value on the Text Block that displays the value.

2. Style the slider with CSS

input[type="range"] {
-webkit-appearance: none;
width: 100%;
height: 4px;
border-radius: 4px;
background: #e0e0e0;
outline: none;
}
input[type="range"]::-webkit-slider-thumb {
-webkit-appearance: none;
width: 20px;
height: 20px;
border-radius: 50%;
background: #3b82f6;
cursor: pointer;
}
input[type="range"]::-moz-range-thumb {
width: 20px;
height: 20px;
border-radius: 50%;
background: #3b82f6;
cursor: pointer;
border: none;
}

3. Display the value in real time

const slider = document.getElementById('range-slider');
const output = document.getElementById('range-value');
slider.addEventListener('input', function() {
output.textContent = slider.value;
});

good to know

To color the left side of the slider (the selected value) differently from the right side, use a dynamic gradient via JavaScript: slider.style.background = 'linear-gradient(to right, #3b82f6 ' + slider.value + '%, #e0e0e0 ' + slider.value + '%)'; in the input listener.

Conclusion

A styled range input makes interactive forms better. Use cases:

  • Budget or price calculator
  • Numeric value filter for results
  • Satisfaction gauge in a form

Published on

You might be interested in these tutorials

Similar tutorials

SEO / GEO

5 min read

5 views

How to Set Up a Redirect in Webflow? (2026)

Updated on 19.12.2025 by Sandro DA SILVA

SEO / GEO

5 min read

5 views

Add structured data to your Webflow site?

Updated on 21.08.2025 by Sandro DA SILVA

No-code

5 min read

5 views

How to Obfuscate a Link in Webflow

Updated on 23.04.2025 by Sandro DA SILVA

Let’s f*****G GO !!

Ready to launch
Your business?

Alexandre

Max

Enora

Bryan

Cannelle

Tiphaine

You'll :heart: our collaboration...