Body text on the page: #FAECDD on #0F0A0616.9 to 1. Meets AAA text contrast, the strictest level.
A web color palette is a set of hex codes with one job each: a page color, a surface for cards, a border for dividers and outlines, an accent for buttons and links, and a text color. Every palette below lists its colors in that order, and its checks show whether its best text pair clears the WCAG bar of 4.5 to 1.
The same colors on a web page
The dark theme from the photo above, a light theme and a bold one, on a small site. Open one in Hue42 to put your own accent in.
Swipe to compare 3 palettes
Body text on the page: #1E1A14 on #FAF6F116.0 to 1. Meets AAA text contrast, the strictest level.
Body text on the page: #260534 on #FCF0DC16.1 to 1. Meets AAA text contrast, the strictest level.
Pick a photo, get a UI theme
Tap any color to copy its hex code.

Gallery Blue
A bright light theme: warm white page, linen panels, a stone border, cobalt buttons and links, charcoal text. The border can outline inputs on the page but is too faint on the panels, so use it as a divider there.
Hex codes, names and checks
| Color | Hex | RGB | Role |
|---|---|---|---|
| Seashell | #FAF6F1 | 250, 246, 241 | Tint |
| Almond | #EDE2DA | 237, 226, 218 | Neutral |
| Taupe | #908476 | 144, 132, 118 | Neutral |
| Sapphire | #0048C1 | 0, 72, 193 | Base |
| Soot | #1E1A14 | 30, 26, 20 | Anchor |
- A readable pair. Best text pairing is 16.0:1 (4.5:1 passes WCAG AA).
- Light to dark range. Lightness spans 75 points of 100.
- Every color distinct. No two colors are close enough to be confused.
- Holds up colorblind. Colors stay distinguishable under common color vision types.
- Room to breathe. There is a quiet color for surfaces and backgrounds.

Pool Deck
A sunny booking or travel site: sand page, deeper sand cards, a pool teal border, terracotta buttons and links, deep teal text. On the sand cards, keep terracotta to buttons and large text.
Hex codes, names and checks
| Color | Hex | RGB | Role |
|---|---|---|---|
| Linen | #FCF2E3 | 252, 242, 227 | Tint |
| Beige | #EBD3B5 | 235, 211, 181 | Analog |
| Light Peacock | #42878D | 66, 135, 141 | Accent |
| Paprika | #BC442A | 188, 68, 42 | Base |
| Bayou | #00282B | 0, 40, 43 | Anchor |
- A readable pair. Best text pairing is 14.1:1 (4.5:1 passes WCAG AA).
- Light to dark range. Lightness spans 71 points of 100.
- Every color distinct. No two colors are close enough to be confused.
- Holds up colorblind. Colors stay distinguishable under common color vision types.
- Room to breathe. There is a quiet color for surfaces and backgrounds.

Neon Street
A dark theme with a neon edge: near black page, blue black cards, a plum border, hot pink buttons and links, ice blue text. Label pink buttons in the page color, not white, and keep the border to dividers.
Hex codes, names and checks
| Color | Hex | RGB | Role |
|---|---|---|---|
| Jet | #020A13 | 2, 10, 19 | Anchor |
| Abyss | #0B1F2B | 11, 31, 43 | Neutral |
| Light Fig | #673D59 | 103, 61, 89 | Analog |
| Vivid Peony | #DE67B1 | 222, 103, 177 | Base |
| Light Powder | #CFF2FE | 207, 242, 254 | Tint |
- A readable pair. Best text pairing is 16.8:1 (4.5:1 passes WCAG AA).
- Light to dark range. Lightness spans 80 points of 100.
- Every color distinct. No two colors are close enough to be confused.
- Holds up colorblind. Colors stay distinguishable under common color vision types.
- Room to breathe. There is a quiet color for surfaces and backgrounds.

Paper and Ink
A docs or reading site: paper page, tan cards for code and notes, a stone border, deep red links, near black ink. The red sits close to the ink, so underline links inside body text.
Hex codes, names and checks
| Color | Hex | RGB | Role |
|---|---|---|---|
| Linen | #FAF3E6 | 250, 243, 230 | Tint |
| Pearl | #E9DCC8 | 233, 220, 200 | Neutral |
| Taupe | #8D857A | 141, 133, 122 | Neutral |
| Ruby | #9C2527 | 156, 37, 39 | Base |
| Soot | #1A1812 | 26, 24, 18 | Anchor |
- A readable pair. Best text pairing is 16.0:1 (4.5:1 passes WCAG AA).
- Light to dark range. Lightness spans 76 points of 100.
- Every color distinct. No two colors are close enough to be confused.
- Holds up colorblind. Colors stay distinguishable under common color vision types.
- Room to breathe. There is a quiet color for surfaces and backgrounds.

Forest Cabin
A dark green theme for a code editor: forest page, moss side panels, a pine border, a lime accent, misty white text. Lime buttons take dark green labels, never white.
Hex codes, names and checks
| Color | Hex | RGB | Role |
|---|---|---|---|
| Black Forest | #0D170D | 13, 23, 13 | Anchor |
| Cypress | #1F3022 | 31, 48, 34 | Neutral |
| Thyme | #617B4D | 97, 123, 77 | Accent |
| Light Matcha | #B4C96D | 180, 201, 109 | Base |
| Sea Salt | #E8F1EC | 232, 241, 236 | Tint |
- A readable pair. Best text pairing is 15.9:1 (4.5:1 passes WCAG AA).
- Light to dark range. Lightness spans 76 points of 100.
- Every color distinct. No two colors are close enough to be confused.
- Holds up colorblind. Colors stay distinguishable under common color vision types.
- Room to breathe. There is a quiet color for surfaces and backgrounds.

Indigo Door
A project or planning app: lilac white page, a lavender sidebar, a periwinkle border, indigo buttons and selected rows, deep navy text. For inputs, darken the border until it reaches 3 to 1 against the color around the field.
Hex codes, names and checks
| Color | Hex | RGB | Role |
|---|---|---|---|
| Snow | #F9F5FD | 249, 245, 253 | Tint |
| Lilac Mist | #E2D9F2 | 226, 217, 242 | Neutral |
| Light Aster | #8590B8 | 133, 144, 184 | Analog |
| Sapphire | #284CAC | 40, 76, 172 | Base |
| Navy | #05194E | 5, 25, 78 | Anchor |
- A readable pair. Best text pairing is 15.5:1 (4.5:1 passes WCAG AA).
- Light to dark range. Lightness spans 74 points of 100.
- Every color distinct. No two colors are close enough to be confused.
- Holds up colorblind. Colors stay distinguishable under common color vision types.
- Room to breathe. There is a quiet color for surfaces and backgrounds.
Two neutral themes, light and dark
Espresso and Teal
Open in Hue42A warm dark theme: espresso page, deep teal cards, a teal gray border, copper buttons and links, ivory text. Label copper buttons in espresso, not white, and keep the border to dividers.
#0F0A06 #082820 #365E5A #E48B54 #FAECDD
Slate Light
Open in Hue42A neutral light theme for an admin or settings screen: cool gray page, white cards, a slate border, a clear blue accent, ink text. The border can outline inputs on the white cards; on the gray page use it as a divider.
#E9EDF3 #FFFFFF #8B95A5 #2A55C4 #111827
Graphite Dark
Open in Hue42A neutral dark theme: graphite page, lighter cards, a slate border, a soft blue accent, off white text. Label blue buttons in the page color, not white, and keep the border to dividers.
#0E1116 #1B2028 #4A5363 #7AA2F7 #E6E9EF
Make it yours in Hue42
Start from a palette or your brand color
Open any palette here, or type your brand's hex code and let Hue42 build the rest around it. A screenshot or a product photo works too, and it stays on your device.
Keep what you like
Generate a new palette as often as you like. Lock the colors you want to keep and the rest change around them.
Check it, then copy it
Every palette gets five checks, among them its best text pair against 4.5 to 1. Select any color to copy its hex code, or export CSS, SCSS, Tailwind or JSON.

Names you will see in Hue42
- PageHue42: Anchor#0F0A06
- SurfaceHue42: Base#082820
- BorderHue42: Analog#365E5A
- AccentHue42: Accent#E48B54
- TextHue42: Tint#FAECDD
More UI themes
Orange Launch
Mint Shopfront
Sage Notebook
Harbor Night
Rose Studio
Lemon Kitchen
Use these colors in a website
Five roles, one job each
A token called blue-500 tells you what the color looks like. A token called accent tells you what it does, so you can change the color later without renaming anything.
These five are a starting point. A real product usually adds a few more: a muted text color and a hover fill come from the five, while status colors may need hues outside them, always with a word or an icon beside them.
- page.
- The background of the whole screen. Usually the lightest color in a light theme and the darkest in a dark one.
- surface.
- Cards, panels, sidebars and menus that sit on the page, one step away from it.
- border.
- Dividers and outlines, nothing else. Where it reaches 3 to 1 against the color behind it, it can outline an input. Below that it is a decorative divider, and a boundary that matters needs another cue, such as a fill or a label.
- accent.
- Buttons, links and the one thing you want noticed.
- text.
- Body copy and headings, with the strongest contrast against both page and surface.
Contrast in short
Normal size text needs a WCAG contrast ratio of 4.5 to 1. Large text, which WCAG sets at 24 CSS pixels, or about 18.7 pixels in bold, needs 3 to 1, and so do the parts that identify a control, such as an input outline, against the colors next to them. Each palette's checks show its best text pair, rounded down, never up.
The usual traps: a bright accent like lemon or orange is a fill, not a text color; a light accent in a dark theme takes dark labels on its buttons, not white; and a color that passes on the page can fail on a tinted card.
Dark mode is its own palette
Flipping black and white rarely works. Pure white text on pure black can glare, and a saturated accent that looks fine on light often vibrates on dark.
Build the dark theme as a separate set: a page that is not quite black, surfaces a little lighter than it, softer text and an accent with more lightness. Espresso and Teal, Neon Street, Forest Cabin, Harbor Night and Graphite Dark above are built that way. Then check every pair again from scratch.
Hover, focus and disabled states
You rarely need new colors for states. For hover and pressed, change the accent's lightness and keep its hue, then check the label on it and the surface around it again. A focus ring can be the accent itself, as long as it reaches 3 to 1 against the colors next to it, not only the page.
Inactive controls are exempt from the contrast rules, so a muted gray works there, but do not reuse that gray for text people need to read.
From palette to CSS variables
Give each role a custom property on the root, such as --page, --surface, --border, --accent and --text, and have your components read those names. A dark theme is then the same names with new values inside a prefers-color-scheme media query or under a data attribute.
Hue42's CSS export names its variables by the tool's own roles, such as --color-anchor, --color-base and --color-tint, which describe a color's place in the palette, not its job on a screen. Map them to your five names once by hex code, for example --page: var(--color-anchor) when the anchor is your page color. Hex, RGB and HSL describe the same color: #3B6FD8 is rgb(59, 111, 216) and about hsl(220, 67%, 54%).
Chart colors
Chart series need to stay apart from each other and from the plot background, so vary lightness as well as hue, and check them in grayscale and with a color vision simulation.
Do not let color carry the meaning alone: label lines directly, or add markers or dash patterns, so a reader who cannot tell two hues apart still can tell the series apart.
Questions people ask
What is a hex color code?
A hex code is a base-16 value after a hash sign that gives the red, green and blue amounts of a color. This page uses six-digit codes: #3B6FD8 means 3B red, 6F green and D8 blue. CSS also reads three-digit shorthand such as #FFF. In four-digit #RGBA the last digit sets opacity, and in eight-digit #RRGGBBAA the last two do.
What contrast ratio do I need for text?
Under WCAG level AA, normal text needs a contrast ratio of at least 4.5 to 1 against its background. Large text, 24 CSS pixels or about 18.7 pixels bold, needs 3 to 1. Check each text color on every surface it sits on, because a tinted card or a hover fill changes the result.
Why do some accents need dark labels on their buttons?
A light or bright accent, such as copper on a dark page or lemon on a light one, leaves too little contrast with white. The fix is a dark label from the same palette, usually the page color in a dark theme; the notes say which palettes need it. Check your button label against its fill yourself: a palette's best text pair does not validate every combination.
What are good colors for success, warning and error?
Green, amber and red are the common choices, with blue for information. Use darker versions for text and lighter tints for message backgrounds, and always add an icon or a word so the meaning does not depend on color alone. Amber is usually too light for text on a white page, so use it as a fill.
How do I copy the hex codes from this page?
Each palette on a photo card prints its five hex codes under its description as plain text you can select, and pressing a color on the card's strip copies its code. To get all five at once in the right format, open the palette in Hue42 and export it as CSS, SCSS, Tailwind or JSON.
Do I need an account to export a palette?
No. In the Hue42 color tool, CSS, SCSS, Tailwind, JSON and SVG exports can be copied or downloaded without an account. Pro adds design tokens with every shade and text pairing, and Figma variables through the free Tokens Studio plugin. Every palette here opens in the tool by link, ready to adjust and check first.
Build a palette around your brand color
Open any palette in the Hue42 color tool, put your own color in as the accent, and see whether the text pairs still pass. When it works, export it as CSS, SCSS, Tailwind or JSON.
Open these colors in Hue42





