Website Color Schemes

Your scheme — five roles

Live preview — a mini website in this scheme

Your Business

A headline in your colors

This is a live preview. The header, button, and card below recolor themselves from the scheme above.

Card one

A short description.

Card two

Another short description.

Click any role swatch to set it as the current color; the Copy buttons copy a code.

Generate a harmonious website color scheme with a role breakdown (background, surface, primary, accent, text) and a live preview — plus 8 industry presets for restaurants, law firms, medical practices, and real estate, each with its WCAG contrast ratio.

A good website scheme has five colors with five jobs: background, surface, primary, accent, and text. Generate one above, or start from an industry preset below.

What the five roles mean

A website scheme is not just five pretty colors — each color has a job. Background covers most of the page (usually near-white), Surface is the color of cards and panels sitting on the background, Primary is the main brand color for headers and links, Accent is the loud color reserved for buttons and calls to action, and Text is the body copy color. The generator above assigns all five from one harmony rule, and the preview shows them working as a real page. A good check is the 60-30-10 rule: about 60% background, 30% surface and primary, 10% accent.

Industry presets

These eight sets are editorial picks from this site's editors — starting points for a type of business, not a standard. Each set's text-on-background ratio is computed at build time and must pass WCAG AA (4.5:1) for normal text; the ratio is shown under every set.

Restaurant — Warm Bistro

Editorial pick: warm browns and amber for a cozy, appetite-friendly bistro site.

RoleColor
Background#FFF8F0
Surface#FFFFFF
Primary#B45309
Accent#DC2626
Text#1C1917

Text #1C1917 on background #FFF8F0: 16.60:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Restaurant — Fresh Café

Editorial pick: fresh greens for a café or salad bar that wants to read healthy and bright.

RoleColor
Background#F0FDF4
Surface#FFFFFF
Primary#15803D
Accent#EA580C
Text#052E16

Text #052E16 on background #F0FDF4: 14.24:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Law firm — Classic Firm

Editorial pick: navy and white with a gold-toned accent — the traditional, authoritative law-firm look.

RoleColor
Background#FFFFFF
Surface#F1F5F9
Primary#1E3A8A
Accent#B45309
Text#0F172A

Text #0F172A on background #FFFFFF: 17.85:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Law firm — Modern Practice

Editorial pick: near-black primary with a cyan accent — a modern firm that wants to look sharp rather than old-fashioned.

RoleColor
Background#F8FAFC
Surface#FFFFFF
Primary#0F172A
Accent#0E7490
Text#1E293B

Text #1E293B on background #F8FAFC: 13.98:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Medical — Clean Clinic

Editorial pick: sky blue and emerald on white — calm, clean, and clinical without feeling cold.

RoleColor
Background#FFFFFF
Surface#F0F9FF
Primary#0369A1
Accent#059669
Text#164E63

Text #164E63 on background #FFFFFF: 9.11:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Medical — Calm Care

Editorial pick: teal-led palette for a therapy, dental, or wellness practice that wants a softer feel.

RoleColor
Background#F8FAFC
Surface#FFFFFF
Primary#0F766E
Accent#0284C7
Text#134E4A

Text #134E4A on background #F8FAFC: 9.06:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Real estate — Luxury Homes

Editorial pick: deep amber-brown on warm white — a premium feel for high-end listings.

RoleColor
Background#FFFFFF
Surface#FAF7F2
Primary#78350F
Accent#B45309
Text#1C1917

Text #1C1917 on background #FFFFFF: 17.49:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

Real estate — Modern Agency

Editorial pick: confident blue with a green accent — a modern agency site that needs to feel both trustworthy and fresh.

RoleColor
Background#F8FAFC
Surface#FFFFFF
Primary#1D4ED8
Accent#059669
Text#0F172A

Text #0F172A on background #F8FAFC: 17.06:1 — passes WCAG AA for normal text (4.5:1) and AAA (7:1).

Normal text: AA Pass   AAA Pass

Large text (18pt+, or 14pt bold+): AA Pass   AAA Pass

How to use a scheme

Copy the scheme as CSS variables (the generator has a button for that), paste the variables into your stylesheet, and use only those five colors across the site. If you change one color, change it in the variables — never add a sixth color by hand. And before you ship, check the text color against the background in the contrast checker, and look at the scheme in the color blind simulator: a scheme that only works for people with perfect color vision fails a tenth of your visitors.

Frequently asked questions

How many colors should a website have?

Five is a good number: a background, a surface, a primary brand color, one accent, and a text color. Three to five colors is the usual advice — more than five usually looks messy.

What is the 60-30-10 rule for websites?

A classic design rule: 60% of the page is the dominant color (usually a light neutral background), 30% is a secondary color (sections, cards, headers), and 10% is the accent color for buttons, links, and highlights.

What is the best color scheme for a business website?

There is no single best scheme — it depends on the business. Blue schemes are the standard for trust and professionalism (law, finance, tech); green suits health and environmental brands; warm colors suit food and retail. The industry presets above are starting points, not rules.

How do I know if my website colors are accessible?

Check the text color against its background: normal text needs a contrast ratio of at least 4.5:1 to pass WCAG AA, and 7:1 for AAA. Every preset on this page shows its text-on-background ratio, and the generator shows the ratio for each scheme it makes.

Related tools

Palette Generator · How to Pick Colors for a Website · Contrast Checker · Color Wheel · What Color Goes with Blue