WOWlayers
Color guide

How to Pick a Color Palette for a Website

A website palette is less about pretty swatches and more about jobs: which color is the page, which is the text, which says click here. Get those jobs right and almost any pleasant palette works.

Give each color one job

Websites use color in predictable places. Map your palette to them before you design anything:

JobTypical choice
Page backgroundWhite or a soft off-white
Body text and headingsYour darkest color, close to black
Buttons and linksYour main brand color
Section backgrounds and cardsA very light tint of the brand color, or a soft neutral
Highlights and badgesThe accent, used sparingly

If a color has no job, leave it out. Fewer colors used consistently look more professional than many used randomly.

Use the brand color sparingly

A common pattern is that most of the page is background, a fair share is text and neutrals, and only a small part is the brand color and accent. That is roughly what designers mean by the 60-30-10 rule: the exact numbers matter less than the idea that bright color is for emphasis. When every section is brightly colored, nothing stands out, including your call-to-action button.

Check contrast before you fall in love

Readable text matters more than any color choice. For normal-size text, aim for at least 4.5:1 contrast between text and its background, the WCAG AA level. Large headings need at least 3:1. Watch these trouble spots:

  • White text on light brand colors such as yellow, light green or sky blue.
  • Gray body text on white, which often falls below 4.5:1.
  • Link color on colored section backgrounds.

The palette generator shows each color's contrast against white and black, and the best text pairings within your palette, so you can fix problems before you build.

Plan for dark mode

Many visitors browse with dark mode on. You do not have to support it, but if you do, you need a dark background, a light text color and a slightly lighter brand color, because saturated colors that look good on white can feel harsh or dim on dark backgrounds. Check contrast again for the dark set.

Turn the palette into CSS

Store your colors once as CSS variables and reuse them everywhere. The palette generator's Copy CSS variables button gives you something like:

:root { --color-1: #1b2a41; --color-2: #3c6e71; --color-3: #f4f1ea; --color-4: #d9a441; --color-5: #ffffff; }

Rename them by job (for example --text, --brand, --bg, --accent) so future edits stay sane. Website builders usually have a theme or style panel where the same codes go.

Test on a real page

Swatches lie. Put your palette on a real layout with a headline, paragraphs, a button and a footer. Our website templates and the builder preview let you change the brand color and see the page update. Check it on your phone in bright light, where weak contrast shows up fast.

Keep going

Frequently asked questions

How many colors should a website have?

Usually three to five: background, text, a main brand color and one or two accents or neutrals.

What is the 60-30-10 rule?

A guideline that most of a design is a dominant neutral, a smaller part a secondary color, and a small part an accent. Treat it as a reminder to use bright colors sparingly, not as exact math.

What contrast ratio does website text need?

WCAG AA asks for at least 4.5:1 for normal text and 3:1 for large text. AAA asks for 7:1 for normal text.

Should my website colors match my logo?

Yes. Use the logo's main color for buttons and links so the site and logo feel like one brand.

How do I add a palette to my website?

Copy the HEX codes or CSS variables into your site's stylesheet or your builder's theme settings.