Zero Signup ToolsFree browser tools

Generator Tools

Random Color Generator

Generate random hex, RGB, HSL, and OKLCH colors in your browser. Pick a mood, lock favorites, and export the batch as CSS variables or JSON.

Random color generator

Generate

Full random across the entire sRGB cube. Tip: press the space bar to regenerate.

Mood
How many colors

Every color is sampled fresh in your browser using cryptographic random bytes. Nothing is uploaded.

How to use

  1. Choose a mood preset (Any, Pastel, Vivid, Dark, Light, Warm, Cool, Earthy, or Neon) to shape where the random sampling happens.
  2. Pick a batch size from 1 to 20 colors and press Generate, or just press the space bar.
  3. Click Lock on any swatch you want to keep across the next regeneration, then press Generate again to reroll only the unlocked positions.
  4. Copy individual values (hex, RGB, HSL, OKLCH) from each card, or use the export panel to grab the whole batch as plain text, CSS variables, or JSON.
  5. Use the history panel at the bottom to restore an earlier batch you generated.

About this tool

Random Color Generator rolls fresh random colors on demand and renders each one in four standard notations at once: hex (#aabbcc), CSS rgb(), CSS hsl(), and CSS Color 4 oklch(). Pick a batch size from one swatch up to twenty and choose a mood preset that constrains where the random sampling happens in color space: Any draws uniformly from the full sRGB cube, Pastel stays in low-saturation high-lightness territory, Vivid clamps to high saturation and balanced lightness, Dark and Light bias toward the extremes, Warm and Cool restrict hue to the red-orange-yellow or blue-green-purple arcs, Earthy produces muted clay and ochre tones, and Neon pushes near-maximum saturation. Every swatch shows its WCAG 2.x contrast ratio against both white and black backgrounds with an AA, AAA, or fail badge so you can immediately see which foreground text color a button or label needs. Lock any swatch to hold it across regenerations, then click Generate to roll only the unlocked positions: this is the standard pattern designers use to refine a palette one slot at a time. The current batch can be exported as plain text, a :root block of CSS custom properties, or a JSON array, and the last six batches are kept in a history panel so you can roll back to a palette you liked. Randomness comes from crypto.getRandomValues, the same browser API used for cryptographic random bytes, so the output is unbiased across runs. Press the space bar anywhere on the page to regenerate without reaching for the mouse. Everything runs locally; no colors leave your browser.

Free to use. Works in your browser. No signup, no login.

Related tools

You may also like

All tools
All toolsGenerator Tools