Color harmony is the reason some color combinations feel right and others make your eyes hurt. It is not subjective. There are measurable relationships between colors on the color wheel that produce pleasing combinations, and these relationships have been documented by artists and scientists for centuries.
For designers and developers who did not go to art school, color harmony rules provide a reliable system for choosing colors. You do not need an innate sense of color. You need to understand 4 to 5 basic schemes and how to apply them.
The practical benefit is speed. Instead of trying random color combinations until something works, you start with a scheme that is mathematically harmonious and fine-tune from there. What used to take an hour of experimentation takes 5 minutes with a Color Picker and knowledge of which scheme to use.
The Color Wheel and HSL
All color harmony schemes are based on relationships around the color wheel. Understanding the wheel requires thinking in HSL (Hue, Saturation, Lightness) rather than hex codes or RGB.
Hue (0 to 360 degrees): the position on the color wheel. 0 is red, 120 is green, 240 is blue. Knowing the hue degree lets you calculate harmonious colors mathematically.
Saturation (0 to 100%): how vivid the color is. 0% is gray. 100% is the purest version of that hue.
Lightness (0 to 100%): how bright the color is. 0% is black, 100% is white, 50% is the pure color.
The reason HSL matters for harmony: all the schemes involve rotating around the hue wheel while adjusting saturation and lightness. In hex or RGB, there is no intuitive way to find a complementary color. In HSL, the complement is always +180 degrees on the hue.
The Color Converter lets you convert between hex, RGB, and HSL instantly. Start with any color you like, get its HSL values, and use the hue degree to calculate your harmony scheme.
Complementary and Split-Complementary
Complementary: two colors opposite each other on the wheel (180 degrees apart). Red and green. Blue and orange. Purple and yellow.
Complementary schemes create maximum contrast. They are bold, energetic, and attention-grabbing. Use them for call-to-action buttons (orange button on blue background), warning states, and hero sections that need to pop.
The risk: complementary colors at full saturation can vibrate visually and feel harsh. Tone down one of the two colors by reducing its saturation or adjusting its lightness. Use the bold color for accents (10 to 20% of the design) and the toned-down version as a background or neutral.
Split-complementary: instead of the direct opposite, use the two colors adjacent to the complement. For blue (hue 240), the complement is orange (hue 60). The split complement uses red-orange (hue 30) and yellow-orange (hue 90).
Split-complementary gives you the contrast of a complementary scheme with more variety and less visual tension. It is easier to work with and harder to get wrong. This makes it an excellent default choice when you want a vibrant but balanced palette.
Experiment with split-complementary gradients using the CSS Gradient Generator. The two split colours create a natural warm-to-cool transition that works well as a background or hero section accent.

Analogous and Triadic Schemes
Analogous: three colors next to each other on the wheel (typically 30 degrees apart). Blue, blue-green, and green. Orange, red-orange, and red.
Analogous schemes feel natural and calming because they mimic how colors appear in nature (a sunset uses analogous warm tones, a forest uses analogous greens). They create cohesion without contrast.
The challenge: without contrast, analogous schemes can feel flat. Solve this by varying the saturation and lightness across the three colors. Make one color dominant (60% of the design), one secondary (30%), and one accent (10%).
Triadic: three colors evenly spaced on the wheel (120 degrees apart). Red, yellow, and blue is the classic triadic scheme.
Triadic schemes are vibrant and balanced. They provide more variety than complementary without the visual tension. Triadic works well for playful, energetic brands (think children's products, creative agencies, food brands).
The key to making triadic work: do not use all three colors at equal saturation. Let one color dominate and use the other two as accents. A design with three equally bold colors looks chaotic. A design with one bold color and two muted accents looks intentional.
Use the Color Picker to select your primary color, then calculate the triadic or analogous partners by adding or subtracting the appropriate degree values from the hue.
The 60-30-10 Rule in Practice
No matter which harmony scheme you choose, the 60-30-10 distribution rule makes it work in real designs:
60% Dominant color: backgrounds, large surfaces, overall feeling. Usually the lightest or most neutral color in your scheme.
30% Secondary color: navigation bars, cards, sidebars, secondary buttons. Provides contrast against the dominant color.
10% Accent color: call-to-action buttons, links, icons, highlights. The most visually intense color, used sparingly for maximum impact.
Example with a split-complementary scheme (blue, red-orange, yellow-orange): - 60%: Light blue backgrounds and white surfaces - 30%: Navy blue navigation, card headers, text - 10%: Red-orange for buttons and important links
The yellow-orange might not even appear as a surface color but instead as hover states, notification badges, or subtle decorative elements.
This ratio works because it creates visual hierarchy. Your eye is drawn to the accent color precisely because it is rare. If you used all three colors equally, nothing would stand out and the design would feel busy.
Breaking the 60-30-10 rule intentionally is fine for specific sections (a bold hero section might invert the ratio), but the overall page should follow this distribution.

Dark Mode Color Harmony
Color harmony rules still apply in dark mode, but the execution changes:
Reduce saturation: fully saturated colors on dark backgrounds cause eye strain and accessibility issues. Reduce saturation by 10 to 20% for dark mode versions of your colors.
Increase lightness of text colors: text that looks great on white (dark gray, dark blue) becomes invisible on dark backgrounds. Use lighter versions of your text colors, but avoid pure white (#FFFFFF) which creates too much contrast on pure black.
Avoid pure black backgrounds: #121212 or #1A1A1A is easier on the eyes than #000000. The slight gray tone creates a more comfortable reading experience and lets you use darker grays for elevated surfaces (cards, modals).
Maintain contrast ratios: WCAG requires 4.5:1 contrast for normal text. What passes on a light background might fail on a dark background and vice versa. Check every text/background combination in both modes.
Accent colors may need adjustment: a red accent that is bold and visible on white might look dull on dark gray. Increase lightness and slightly increase saturation for accent colors in dark mode.
The Color Converter helps you quickly adjust HSL values to create dark mode variants of your light mode palette. Work in HSL to make systematic adjustments rather than guessing with hex codes.
FAQ
How many colors should a design palette have?
Most effective palettes use 3 to 5 colors: one primary, one secondary, one or two accents, and a neutral (gray family). Add a semantic set (green for success, red for error, yellow for warning) on top of that. More than 5 brand colors creates inconsistency and makes the palette harder to maintain.
Do color harmony rules work for data visualization?
Partially. Harmony ensures the chart looks pleasant, but data viz also needs distinct, distinguishable colors. Sequential data works well with analogous schemes. Categorical data needs distinct hues that happen to be harmonious. Use dedicated data viz palettes (like ColorBrewer) when accuracy matters more than aesthetics.
Can I break color harmony rules intentionally?
Absolutely. Intentional dissonance creates tension, urgency, or visual disruption. Warning banners, error states, and "breaking news" designs deliberately use clashing colors to grab attention. The key word is intentional. Breaking rules by accident looks unprofessional. Breaking them on purpose looks bold.
How do I choose colors for accessibility?
Start with harmony for aesthetics, then validate with contrast ratios. WCAG 2.1 requires 4.5:1 contrast for normal text and 3:1 for large text. Use tools like the contrast checker to verify every text and background combination. If a harmonious color fails contrast, adjust its lightness rather than changing the hue.
### How many colors should a design palette have.
CSS Layout Tools: Grid, Flexbox, Gradients and Shadows
A practical guide to CSS Grid, Flexbox, gradients, and box shadows. Learn when to use each layout technique and generate clean CSS code fast.
Edit Images in Your Browser: Resize, Compress, Convert
Handle common image tasks in your browser without installing software. Resize, compress, convert formats, and inspect EXIF metadata in seconds.
CSS Generators: Gradients, Flexbox, Grid and Shadows
Use CSS generators to create gradients, flexbox layouts, grid systems, and box shadows. Visual editors output ready-to-copy CSS for your project.
