Palette Library

API Docs

A calm palette for developer tools with a purple primary and a teal accent. Text reaches 17.81:1 in light mode and 16.97:1 in dark mode.

How to use it

API Docs's roles on a real interface, with the ratios stored for this palette.

  • Light mode: page #f6faff, cards #e7ebf0, and text #0a131e at 17.81:1; buttons #5b21b6 with #f6faff labels at 8.57:1; highlights #14b8a6 with #0a131e text at 7.50:1.
  • Dark mode: page #0f1112, cards #161a1f, and text #eff3f7 at 16.97:1; buttons #b19aff with #0f1112 labels at 8.05:1; highlights #14b8a6 with #0f1112 text at 7.60:1.
  • Links: #5b21b6 reaches 8.57:1 on the light page, and #b19aff reaches 8.05:1 on the dark page.
  • The accent as text: In light mode, keep #14b8a6 for fills and badges, not text: it reaches only 2.37:1 on the page.

Preview

The same palette on a small interface in light and dark.

Light mode

A place for your ideas

Start with colors that work together.

Your next project

A surface for the details that matter.

Get startedNew

Explore your palette →

Dark mode

A place for your ideas

Start with colors that work together.

Your next project

A surface for the details that matter.

Get startedNew

Explore your palette →

Roles

Five roles and their two foregrounds. Copy the exact HEX values.

RoleLightDark
Background
#f6faff
#0f1112
Surface
#e7ebf0
#161a1f
Text
#0a131e
#eff3f7
Primary
#5b21b6
#b19aff
Primary Foreground
#f6faff
#0f1112
Accent
#14b8a6
#14b8a6
Accent Foreground
#0a131e
#0f1112

Contrast matrix

Five required pairs per mode, judged on the final 8-bit colors.

Light mode

Scroll the table sideways on a small screen.

light mode: foreground rows on background columns
Foreground / BackgroundBackgroundSurfacePrimaryAccent
Text17.81:1AAArequired15.59:1AAArequired2.07:1Fail7.50:1AAA
Primary8.57:1AAArequired7.50:1AAA1.00:1Fail3.60:1AA large
Accent2.37:1Fail2.07:1Fail3.60:1AA large1.00:1Fail
Primary Foreground1.00:1Fail1.14:1Fail8.57:1AAArequired2.37:1Fail
Accent Foreground17.81:1AAA15.59:1AAA2.07:1Fail7.50:1AAArequired

Dark mode

Scroll the table sideways on a small screen.

dark mode: foreground rows on background columns
Foreground / BackgroundBackgroundSurfacePrimaryAccent
Text16.97:1AAArequired15.67:1AAArequired2.10:1Fail2.23:1Fail
Primary8.05:1AAArequired7.43:1AAA1.00:1Fail1.05:1Fail
Accent7.60:1AAA7.02:1AAA1.05:1Fail1.00:1Fail
Primary Foreground1.00:1Fail1.08:1Fail8.05:1AAArequired7.60:1AAA
Accent Foreground1.00:1Fail1.08:1Fail8.05:1AAA7.60:1AAArequired

AAA: normal text ≥ 7:1. AA: normal text ≥ 4.5:1. AA large: large text ≥ 3:1 (24 px, or 18.66 px bold). UI: required component contrast ≥ 3:1. Fail: below 3:1. Required marks the five pairs ColorLint checks in each mode. Other pairs are informational.

ColorLint checks color contrast only. Passing pairs do not mean a page is accessible.

Exports

Both modes, with the exact values the Palette Generator exports.

CSS variables

/* ColorLint palette (v1). Light values in :root; dark values in .dark. */

:root {
  --background: #f6faff;
  --surface: #e7ebf0;
  --text: #0a131e;
  --primary: #5b21b6;
  --primary-foreground: #f6faff;
  --accent: #14b8a6;
  --accent-foreground: #0a131e;
}

.dark {
  --background: #0f1112;
  --surface: #161a1f;
  --text: #eff3f7;
  --primary: #b19aff;
  --primary-foreground: #0f1112;
  --accent: #14b8a6;
  --accent-foreground: #0f1112;
}

Tailwind v4

/* ColorLint palette for Tailwind CSS v4 (palette v1). */
/* Paste after @import "tailwindcss". Add the "dark" class to <html> for dark mode. */

@custom-variant dark (&:where(.dark, .dark *));

:root {
  color-scheme: light;
  --background: #f6faff;
  --surface: #e7ebf0;
  --text: #0a131e;
  --primary: #5b21b6;
  --primary-foreground: #f6faff;
  --accent: #14b8a6;
  --accent-foreground: #0a131e;
}

.dark {
  color-scheme: dark;
  --background: #0f1112;
  --surface: #161a1f;
  --text: #eff3f7;
  --primary: #b19aff;
  --primary-foreground: #0f1112;
  --accent: #14b8a6;
  --accent-foreground: #0f1112;
}

@theme inline {
  --color-background: var(--background);
  --color-surface: var(--surface);
  --color-text: var(--text);
  --color-primary: var(--primary);
  --color-primary-foreground: var(--primary-foreground);
  --color-accent: var(--accent);
  --color-accent-foreground: var(--accent-foreground);
}

Compared with similar palettes

  • Compared with Graphite Console, which shares the Developer tools topic: text reaches 17.81:1 in light mode against 18.45:1, the primary is purple where Graphite Console's is gray, and both use a teal accent.
  • Compared with Terminal Glow, which shares the Developer tools topic: text reaches 17.81:1 in light mode against 13.92:1, the primary is purple where Terminal Glow's is green, and the accent is teal where Terminal Glow's is purple.