Color Palette Generator

Roll random, harmonious colour schemes — or pick a base colour and build a palette around it. Lock the colours you like, regenerate the rest, then export as CSS variables, JSON or a HEX list — free, instant, nothing uploaded.

Press Space to generate a new palette. Click a swatch to copy its HEX, or the lock to keep a colour while you reroll the rest.

Free, no sign-up Generated in your browser CSS, JSON & HEX export

Drag in the colour area or the hue bar, or type a HEX / RGB value, then build a five-colour scheme anchored to it. The toolbar Generate button keeps rolling fully random palettes.

How to Generate a Colour Palette

Three steps, all in your browser.

1

Generate a palette

Press the Space bar or click Generate to roll five harmonious colours from a random base hue — or pick a colour in the Base colour card and click Generate from this colour to build the scheme around it. Keep rolling until something catches your eye.

2

Lock what you like

Click the lock on any swatch to pin that colour. The next roll keeps the locked colours and only replaces the rest, so you can build a scheme one colour at a time.

3

Copy or export

Click a single swatch to copy its HEX, or export the whole palette as CSS variables, JSON or a HEX list. Need a strong credential next? Try the Password Generator.

Frequently Asked Questions

How does this color palette generator work?
Each time you generate, the tool picks a random base hue and a colour-harmony scheme — analogous, monochrome, triad, complementary or split-complementary — then derives five colours from it by varying hue, saturation and lightness in steps that keep the set balanced. Because the colours are built from a single harmony rule rather than chosen at pure random, the palette tends to look coherent rather than clashing. Everything is computed in your browser with the Web Crypto random number generator. Press the Space bar or click Generate to roll a fresh palette, and lock any swatch you want to keep before rolling again.
Can I create a palette from a specific colour or HEX code?
Yes. Open the Base colour card, then drag in the colour area, move the hue bar, or type a HEX or RGB value to choose any colour. Click Generate from this colour and the tool builds a five-colour harmonious scheme anchored to that colour, with the colour you picked included as one of the swatches. Press Generate from this colour again to roll different harmonies around the same base, and use the toolbar Generate button at any time to go back to fully random palettes. It is the quickest way to build a scheme around a brand colour or a shade you already have.
What do the CSS, JSON and HEX export options give me?
Copy CSS gives you a ready-to-paste :root block with the five colours as custom properties (--color-1 through --color-5), which you can reference with var(--color-1). Copy JSON gives an array of the five HEX strings, handy for design tokens or scripts. Copy HEX gives a plain comma-separated list for quickly pasting into a design app, spreadsheet or message. You can also click any single swatch to copy just that one colour.
How do I keep a colour I like while changing the others?
Click the lock icon on any swatch and that colour is pinned. The next time you generate, every locked swatch stays exactly as it is while the unlocked ones are replaced with fresh colours. This lets you build a palette incrementally: keep the one or two colours that work, reroll the rest until the whole set feels right, then lock everything and export. Click the lock again to release a colour. Locks are visual only and reset when you reload the page, since nothing is saved.
What makes a good colour palette?
A useful palette usually has a clear structure: one or two dominant colours, a contrasting accent, and a couple of supporting tones that bridge them. Harmony helps — colours that sit in a deliberate relationship on the colour wheel read as intentional. Equally important is a spread of lightness so you have dark tones for text, mid tones for surfaces and light tones for backgrounds. The schemes this generator cycles through are designed around these ideas, which is why locking the tones you need and rerolling the rest is an effective workflow.
Are the colours truly random or based on colour theory?
Both. The starting point — the base hue and which harmony scheme is used — is chosen at random using the browser's cryptographic random number generator, so no two sessions are alike. But the five colours are not independent random values: they are generated from that base using established colour-theory relationships (analogous, monochrome, triadic, complementary and split-complementary), with controlled steps in saturation and lightness. The result is randomness within structure: every palette is different, yet each one follows a recognisable harmony.
Is anything uploaded, tracked or saved?
No. The generator is fully client-side: the palettes are calculated in your browser and never sent to a server, and nothing about the colours you generate is logged or stored. There is no account and no sign-up. When you copy a colour or an export, it goes to your system clipboard so you can paste it wherever you need. Reloading or closing the tab clears the current palette and any locks. Because there are no network calls, the tool keeps working offline once the page has loaded.