Account

What new tool do you want?

Fun & Games

Random Color Generator

Generate random colors with HEX, RGB and HSL codes — any color, pastel, dark, vivid or grayscale — for design inspiration and games.

How to use

  1. 1Choose a style and how many colors.
  2. 2Press Generate and copy the codes you like.

Frequently asked questions

What's the difference between HEX and RGB?

They're the same color written two ways: #FF8800 is rgb(255, 136, 0). HSL describes hue, saturation and lightness.

How are pastel colors made?

Pastels are generated with high lightness (80–90%) and moderate saturation.

Can I build a palette from these?

Yes — pick a favorite and use a color palette generator to find matching shades.

The HSL ranges behind each style

Every color is generated in HSL (hue, saturation, lightness) space and then converted to hex and RGB for display. Hue is always a random 0–360° angle regardless of style, but saturation and lightness shift per style: Pastel uses 40–70% saturation with 80–90% lightness (light, soft and desaturated), Vivid uses 85–100% saturation with 45–55% lightness (intense and pure), Dark uses 30–80% saturation with just 12–28% lightness, and Grayscale sets saturation to a flat 0% with lightness randomized across the full 5–95% range.

Worked example: converting one pastel pick to hex

Say the random generator rolls hue 200°, saturation 55% and lightness 85% under the Pastel style. Running the standard HSL-to-RGB formula on those numbers works out to roughly RGB(196, 224, 238) — a soft, light blue — which converts to the hex code #C4E0EE. The tool shows all three formats side by side for every color (hex, rgb(), and the original hsl() values), so you can copy whichever format your design tool or CSS expects without doing the conversion yourself.

Why grayscale still produces variety

With saturation locked at 0%, hue technically has no visible effect — a hue of 0° and a hue of 300° at the same lightness render identically, since there's no color to rotate. All the variation in grayscale mode comes purely from the randomized lightness value, which is why the three RGB channels always come out equal to each other (e.g. rgb(140, 140, 140)) for every grayscale result, forming a true neutral gray rather than a tinted one.

Using the output beyond a single pick

A single generated color works as a quick starting point, but for an actual coordinated palette, picking one color you like here and feeding its hex code into a dedicated palette or color-harmony tool (to find complementary, triadic or analogous matches) will get more usable results than generating several independent random colors and hoping they look good together.

Five colors in the Any style are already listed

The count opens at 5 and the style at Any, and the rows appear without a click. Each row is a six-digit uppercase hex code, then rgb, then hsl, separated by wide spaces. The count box stops at 50. If I clear it, the batch falls back to those same five rather than to one. Grayscale rows keep the three rgb channels equal. Hue is a whole number of degrees, and the saturation and lightness in the hsl text are whole percentages. Copy all joins the rows with line breaks, which is the list I paste into a notes file. The button says Generate, and changing the style redraws the five, or however many I asked for, right away.

Related tools

More: Fun & Games