Color Palette Generator: Harmonies, HSL Math, and Export for Designers
Build complementary, monochromatic, analogous, triadic, or tetradic palettes from a single seed color. Use it for paint and décor mood boards, a brand pass, or front-end code. Copy hex codes and CSS variables, export a labeled PNG, spin harmonies on an interactive wheel, and peek at WCAG contrast. The whole thing runs offline in your browser.
What This Color Palette Generator Does
- Outputs you can ship:Click any swatch for a single hex. Copy all as CSS variables drops a ready-made :root block (--color-1 onward) into themes or components. Export as PNG saves a 1200 by 400 strip you can chuck into Slack, Notion, a binder, or your pocket at the paint store next to fan decks (still grab real chips under your lights; screens lie kindly). Nothing here phones home.
- Designed for iteration:Lock individual swatches when you like a specific tone but want to experiment elsewhere. Locked positions are preserved when you drag the wheel or change harmony. The main color wheel is your primary control for the seed color. Recent palettes lists snapshots you save with + Save current (stored in this browser only).
- Accessibility sense-check:Below the main grid, each color lists contrast ratios against white and black backgrounds with a simple AA pass or fail at the 4.5 to 1 threshold for normal text. That does not replace a full audit of your typography stack, but it surfaces obvious risks before you promote a shade to primary text or chrome.
How Harmony Math Works in HSL
- Complementary:Two hues parked opposite each other on the wheel. Loud contrast when you want accents that actually pop.
- Monochromatic:Same hue, different stops of tint or shade so walls, panels, and type can breathe without hopping hues.
- Analogous:Neighboring hues around your seed for cohesive, low-drama palettes.
- Triadic:Three hues spaced roughly 120 degrees apart. Feels energetic without sliding into chaos.
- Tetradic:Four hues forming a rectangle on the wheel. Nice when you want one hero color and a few loud friends.
How to Use Each Control
- + Save current:Happy with a row? Click + Save current under Recent palettes and it lands in the list. Saved rows stay in this browser’s storage on this machine; we never upload them.
- Swatch interactions:Hover to see a Copy hex hint. Click the swatch area to copy. The lock icon toggles preservation for that index. On small screens the swatch grid adapts so colors stay easy to tap.
- Exports recap:CSS variables arrive ready to paste into global theme files. PNG export draws flat rectangles with centered hex labels in high contrast text for quick stakeholder review. Because rendering uses the Canvas API only, exports remain deterministic for a given palette array.
Nearest Named Colors and Why They Are Approximate
Contrast Ratios and Responsible Color Choice
- When a favorite color fails:Do not discard it outright. Layer it behind glass overlays, pair it with off-white ink, or reserve it for illustrations while choosing a slightly darker variant from the same harmony row for text containers.
- Working with locked swatches:If a locked brand color fails contrast on your planned background, unlock adjacent swatches and regenerate analogous or monochromatic neighbors until one passes while staying on brief.
Workflow Ideas for Teams and Briefs
- Pair with conversion tools:After locking a palette, translate key colors into HSL or CMYK using a dedicated converter when print vendors require alternate spaces.
- Random inspiration:Surprise me is intentionally playful: it breaks creative block by forcing unfamiliar seeds and harmonies.
Rooms, Trim, and Paint Shopping (Not Just Web and CSS)
- Translate screen to store:Bring the PNG export or written hex list when you shop. Staff can often suggest in-stock lines near your direction; large shifts in undertone usually show up once you compare printed or phone screens to paper samples under daylight and lamps at home.
- Same palette, many materials:Once the relationships click, keep using that same hex row while you scroll upholstery, tile, or cabinets. Vendor names will change; the relationships you liked stay put.