Alabhya Jindal

<input type="color">

There is a native way to provide a way to choose colors on the web.

<input type='color'>

There is a change event which can be listened to provide real time updates as the user selects a color. One notable drawback is that the element behaves very differently across browsers.

Chrome’s picker looks great:

Firefox’s picker is weird. It first asks you to select a color from an arbitrary chosen list:

If you don’t like the colors here, then you can pick your own color by clicking the ‘Custom’ button: