Random Color Generator
Generate random colors in HEX, RGB, and HSL formats. Perfect for design inspiration.
About this calculator
Generate a set of random colours and get each one in HEX, RGB and HSL. Choose how many, press Generate and copy what you like.
Good for inspiration, placeholders and testing UI themes.
How to use it
- Set Count.
- Press Generate Colors.
- Click a swatch to copy.
How random colours are made
Each of red, green and blue is picked at random from 0 to 255, giving 16,777,216 possible colours. Fully random colours are often garish; for pleasant results lock saturation and lightness and randomise only the hue.
Worked example
Example rgb(55, 218, 149) is #37DA95.
Tips and common mistakes
- Regenerate until something clicks.
- Check contrast against text.
- Fix saturation for harmony.
- Save favourites as variables.
- Use for placeholder avatars.
Frequently asked questions
How many colours are possible?
16,777,216 in 24-bit colour.
Are the colours truly random?
They come from the browser's random number generator.
Can I copy the code?
Yes.
Why do some look ugly?
Random hues ignore harmony.
Which format should I use?
HEX in CSS, HSL when adjusting.
Is it free?
Yes.