Turn hue, saturation and lightness into a hex code — useful when a colour was picked by feel and now has to go into a stylesheet or a design file.
This is the direction you need after picking a colour by adjusting sliders: the result has to be written down somewhere that only understands hex. The conversion is exact in the sense that it round trips, but the hex code is quantised to whole channels, so very small changes in saturation may not move it at all.
f(n) = L − a · max(−1, min(k − 3, 9 − k, 1)) where k = (n + H/30) mod 12, a = S · min(L, 1 − L)
The specification defines the conversion as one function evaluated three times, at offsets 0, 8 and 4, which yields red, green and blue in turn. Each result is then scaled to 0..255 and written in hex.
A number that disagrees with its source is a defect, not a rounding preference.
What did you enter, what did the tool show, and what did you expect instead? If you have a source that disagrees with ours, a link to it is the most useful thing you can send.
Opens your mail app with the page and tool already filled in.
Convert a hex colour into hue, saturation and lightness — the form that makes a colour easy to lighten, darken or desaturate by hand.
Convert hue, saturation and lightness into the red, green and blue channels a screen actually uses.
Convert a hex colour to its red, green and blue channels, including the shorthand and alpha forms defined by the CSS specification.