PreviewingGo to this paletteOpen in generator
Code
/* Midnight Purple — colorset.net */
:root {
--color-1: #2E0854;
--color-2: #4B1373;
--color-3: #681E93;
--color-4: #8529B2;
--color-5: #1A0340;
--color-bg: #FAF4FF;
--color-surface: #F2EAF8;
--color-border: #DAD1E1;
--color-text: #19083A;
--color-muted: #6A6780;
--color-primary: #8529B2;
--color-on-primary: #FFFFFF;
--color-accent: #2E0854;
--color-on-accent: #FFFFFF;
}
@media (prefers-color-scheme: dark) {
:root {
--color-bg: #100C1D;
--color-surface: #1A1628;
--color-border: #2E2A40;
--color-text: #B19EBE;
--color-muted: #8C7E96;
--color-primary: #943BC3;
--color-on-primary: #FFFFFF;
--color-accent: #6A5DA0;
--color-on-accent: #FFFFFF;
}
}
Color values
| Color | HEX | RGB | HSL | OKLCH |
|---|---|---|---|---|
| 1 | ||||
| 2 | ||||
| 3 | ||||
| 4 | ||||
| 5 |
Roles & contrast
Original colors are kept; roles are adjusted only when needed for contrast.
| Role | Light mode | Dark mode |
|---|---|---|
| Background | adjusted for contrast · from #8529B2 | adjusted for contrast · from #1A0340 |
| Surface | derived | derived |
| Border | derived | derived |
| Text | adjusted for contrast · from #1A0340 | adjusted for contrast · from #8529B2 |
| Muted text | derived | derived |
| Primary | from palette · color 4 | adjusted for contrast · from #8529B2 |
| On primary | derived | derived |
| Accent | from palette · color 1 | adjusted for contrast · from #8529B2 |
| On accent | derived | derived |
Contrast
| Pair | Sample | Ratio | WCAG |
|---|---|---|---|
| Text on background | 17.10:1 | AAA pass 4.5:1 | |
| Text on surface | 15.74:1 | AAA pass 4.5:1 | |
| Muted text on background | 5.03:1 | AA pass 4.5:1 | |
| Label on primary | 7.10:1 | AAA pass 4.5:1 | |
| Label on accent | 16.42:1 | AAA pass 4.5:1 | |
| Primary on background | 6.58:1 | AA pass 3:1 | |
| Accent on background | 15.21:1 | AAA pass 3:1 |
| Pair | Sample | Ratio | WCAG |
|---|---|---|---|
| Text on background | 7.78:1 | AAA pass 4.5:1 | |
| Text on surface | 7.15:1 | AAA pass 4.5:1 | |
| Muted text on background | 5.07:1 | AA pass 4.5:1 | |
| Label on primary | 5.72:1 | AA pass 4.5:1 | |
| Label on accent | 5.70:1 | AA pass 4.5:1 | |
| Primary on background | 3.36:1 | AA Large pass 3:1 | |
| Accent on background | 3.37:1 | AA Large pass 3:1 |
Every color on every color
Rows are backgrounds and columns are text colors, using the actual palette colors. Ratios: AAA 7:1, AA 4.5:1, AA large text 3:1.
| Background / Text | #2E0854 (Text 1) | #4B1373 (Text 2) | #681E93 (Text 3) | #8529B2 (Text 4) | #1A0340 (Text 5) |
|---|---|---|---|---|---|
| #2E0854 | Same color | 1.28— | 1.72— | 2.31— | 1.13— |
| #4B1373 | 1.28— | Same color | 1.34— | 1.80— | 1.45— |
| #681E93 | 1.72— | 1.34— | Same color | 1.35— | 1.94— |
| #8529B2 | 2.31— | 1.80— | 1.35— | Same color | 2.61— |
| #1A0340 | 1.13— | 1.45— | 1.94— | 2.61— | Same color |
Shades
Shades and tints (50–950)
