How to style the option of an html “select” element?

There are only a few style attributes that can be applied to an <option> element.

This is because this type of element is an example of a “replaced element”. They are OS-dependent and are not part of the HTML/browser. It cannot be styled via CSS.

There are replacement plug-ins/libraries that look like a <select> but are actually composed of regular HTML elements that CAN be styled.

Leave a Comment