Skip to content
Utilities2026-05-305 min read

Online Color Palette Generator: Scales, Harmonies, and CSS Export

What Is a Color Palette Generator

A color palette generator builds a usable color set from one seed color. Designers and developers use it for brand accents, UI themes, and chart series. On this site the Color Palette Generator stays in the browser: pick a base color, choose a scheme, then copy HEX values, CSS variables, or a Tailwind snippet.

Schemes the tool actually ships

SchemeWhat you getTypical use
Tint / shade scale11 steps (50–950), base at 500Tailwind-style brand ramps, button states
ComplementaryBase + hue +180°High contrast accents
AnalogousBase ±30°Calm UI neighborhoods
TriadicBase +120° / +240°Three-role UIs (primary / secondary / accent)
Split-complementaryBase +150° / +210°Contrast with less clash than pure complement
TetradicBase +90° / +180° / +270°Rich multi-hue systems (needs curation)

Monochromatic theory and the tint/shade scale are related but not identical: the scale mixes toward white/black in sRGB; a pure monochromatic wheel set only nudges hue. Use scale when you need a full light→dark ramp; use a harmony when you need related hues.

Why generate instead of hand-picking

  1. Brand: expand one logo hex into a usable ramp or accent set
  2. UI tokens: fill surface / accent roles quickly, then rename
  3. Charts: pick high-separation hues (triadic / tetradic) before tuning luminance
  4. Accessibility: generate candidates, then verify with a contrast checker
  5. Prototyping: swap schemes without opening a design file

How to use the ToolVault generator

  1. Pick a base color (color picker or HEX / CSS color string)
  2. Choose a scheme (scale or a wheel harmony)
  3. Generate — scale yields 11 steps; harmonies yield 2–4 named slots
  4. Click a swatch to copy HEX; or Copy CSS vars / Copy Tailwind snippet
  5. Spot-check text/background pairs in the contrast tool before locking tokens

There is no separate HSL slider panel: change the seed color and regenerate. For one-off format conversion (HEX ↔ RGB ↔ HSL with alpha), use the Color Converter.

Color theory that still matters

The color wheel

Harmonies are hue arithmetic on the wheel:

          Red (0°)
        /  \
   Magenta    Orange
    |          |
  Purple     Yellow
    |          |
   Blue     Yellow-Green
        \  /
        Green (120°)

HSL mental model

  • H: 0–360° (what harmony offsets)
  • S / L: kept from the seed when rotating hue — so a muted seed stays muted

Sketch formulas (illustrative)

const complementary = (hue) => (hue + 180) % 360;
const analogous = (hue) => [(hue - 30 + 360) % 360, hue, (hue + 30) % 360];
const triadic = (hue) => [hue, (hue + 120) % 360, (hue + 240) % 360];

The on-site implementation rotates in HSL via colorjs.io, then exports HEX / RGB / HSL strings per slot.

Export shapes that survive paste

CSS variables (what Copy CSS vars emits):

:root {
  --color-base: #3B82F6;
  --color-complement: #F69C3B;
}

Tailwind snippet (drop under theme.extend.colors):

brand: {
  'base': '#3B82F6',
  'complement': '#F69C3B',
},

Rename keys to semantic roles (surface, on-surface, accent) before shipping — raw base / triad-120 names are generation labels, not design language.

Generation strategies: four families

Harmony-based (wheel offsets — predictable, sometimes flat), perceptual-ramp (OKLCH/Lab interpolation — smooth scales for data viz), extraction (pull colors from an image — brand-faithful, source-dependent), and algorithmic (golden-ratio hue stepping — distinctive, uneven). This generator covers harmony + tint/shade ramp. Image extraction and OKLCH ramps live elsewhere in the design stack; do not expect one tool to own every family.

Contrast as a generation constraint

Generating first and checking contrast last fails the same way waterfall testing fails. Practical loop: generate → pick text/background candidates → verify ≥4.5:1 (AA) for body text. A second trap: scale steps that look distinct in the UI but cluster in luminance (five mid blues). Prefer a ramp that spans roughly light near-white through near-black before calling the palette “done.”

Dark mode is a second palette

Inverting a light theme (filter: invert) breaks shadows, brand hues, and images. A real dark set reassigns roles: near-black surfaces (not pure #000), body text around ~87% white, and slightly desaturated accents so they do not vibrate on dark. Keep tokens semantic (surface / on-surface / accent) so light and dark are two assignments of the same roles — not two unrelated HEX dumps.

Implementer's notes

  • Scale mode mixes the seed toward white/black in sRGB; step 500 is the unchanged seed.
  • Harmony modes keep the seed’s saturation and lightness while rotating hue — desaturated seeds stay quiet.
  • Invalid color strings yield an empty list (no crash); fix the seed and regenerate.
  • CSS / Tailwind export is copy-only — nothing is written to disk or sent to a server.

Exporting without painting yourself into a corner

Once a seed and harmony mode look right in the palette generator:

  1. Copy CSS variables or Tailwind-style scales into the design token file — not into scattered component styles
  2. Name roles (--color-accent) instead of freezing hex in JSX class strings
  3. Run body/background pairs through the contrast checker before calling the palette finished
  4. Generate the dark-mode assignment as a second pass (same roles, different values) — do not invert the light sheet

That sequence keeps the generator as a starting point, not as the long-term source of truth.

FAQ

How should I choose brand colors?

  1. Define the personality (calm, playful, technical)
  2. Lock 1–2 primaries from the logo
  3. Generate secondary / accent via complementary or split-complementary
  4. Verify WCAG AA contrast (4.5:1 for normal text)

How many colors belong in a product palette?

Usually 3–5 chromatic roles plus a neutral ramp. The “60-30-10” layout (primary / secondary / accent) still works for marketing surfaces; product UI often needs more neutrals than accents.

How do I keep accessibility honest?

  • Body text ≥ 4.5:1; large text (≥18px / 14px bold) ≥ 3:1
  • Do not encode meaning with color alone
  • Recheck after dark-mode reassignment — contrast is per pair, not per brand hex

From ToolVault. Related: Palette Generator, Color Converter, Contrast Checker. More tools on the homepage.