ToolSlash LogoToolSlash
Tools →

Accessible Color Palette Generator

Guide

Creating WCAG-Compliant Accessible Color Palettes

Color accessibility is a core pillar of digital product design. The Web Content Accessibility Guidelines (WCAG 2.1) require sufficient luminance contrast between foreground text and background colors to ensure digital experiences remain accessible to individuals with visual impairments or varying screen environments.

WCAG Contrast Ratio Thresholds

  • Level AA (Normal Text): Minimum contrast ratio of 4.5:1 for text below 18pt (or bold below 14pt).
  • Level AA (Large Text & UI Components): Minimum contrast ratio of 3.0:1 for large headings (18pt+ or bold 14pt+) and interactive button borders/icons.
  • Level AAA (Enhanced Contrast): Minimum contrast ratio of 7.0:1 for normal body text and 4.5:1 for large text.

Relative Luminance and Perceptual Lightness

Contrast is calculated using the relative luminance of sRGB colors according to the formula: (L1 + 0.05) / (L2 + 0.05), where L1 is the lighter color and L2 is the darker color on a scale from 0.0 (pitch black) to 1.0 (pure white).