# Gray Color (#808080)

> Gray is a CSS named color defined as hex code #808080.

- **URL**: https://swatchatlas.com/colors/gray/
- **Language**: English (en)
- **CSS Name**: `gray`
- **Date Published**: 2026-09-29
- **Date Modified**: 2026-09-29
- **Authority Citation**: W3C CSS Color Module Level 4 (https://www.w3.org/TR/css-color-4/#named-colors)

## Color Values
- **HEX**: #808080
- **RGB**: rgb(128, 128, 128)
- **HSL**: hsl(0, 0%, 50%)
- **HSV/HSB**: hsv(0, 0%, 50%)
- **CMYK**: cmyk(0%, 0%, 0%, 50%) (digital approximation, non-print)
- **OKLCH**: oklch(0.600 0.000 0.0)

## What Colors Go With Gray
Contrast is each color on Gray (WCAG 2.2); 4.5:1 or above is text-safe.
- **Black (#000000)**: 5.32:1, text-safe. Strong, readable text on gray.
- **White (#FFFFFF)**: 3.95:1, background or accent. Clean text and icons for large or bold labels.
- **Navy (#000080)**: 4.05:1, background or accent. A deep blue that gives a crisp, classic contrast.
- **Ivory (#FFFFF0)**: 3.91:1, background or accent. A warm off-white for backgrounds around gray.
- **Gold (#FFD700)**: 2.82:1, background or accent. A warm accent that lifts a gray palette.
- **Sky Blue (#87CEEB)**: 2.27:1, background or accent. A cool, airy accent for links and highlights.

## WCAG 2.2 Contrast Results
- **Pure Black (#000000) text on Gray**: 5.32:1 (Passes AA for all text; AAA for large text only)
- **Pure White (#FFFFFF) text on Gray**: 3.95:1 (Passes AA for large text only)
- **Dark Charcoal (#212529) text on Gray**: 3.91:1 (Passes AA for large text only)
- **Mid Gray (#666666) text on Gray**: 1.45:1 (Fails AA and AAA)

## FAQ
### Can I use black text on Gray?
Yes. Black text on Gray has a WCAG 2.2 contrast ratio of 5.32:1, which passes AA (4.5:1) for all text sizes but not the stricter AAA level (7:1) for body text.

### Can I use white text on Gray?
Only for large text. White text on Gray has a WCAG 2.2 contrast ratio of 3.95:1: enough for large text (3:1) but below the 4.5:1 needed for body text.

### What colors go with Gray?
Black, White, Navy, Ivory, Gold and Sky Blue all go well with Gray. Black (5.32:1) has enough contrast for text on Gray; White, Navy, Ivory, Gold and Sky Blue work better as a background or accent.

### What is the hex code for gray, and is it gray or grey?
The CSS named color gray is #808080, which is RGB(128, 128, 128). The spelling grey is also valid in CSS and gives exactly the same color.

## Background Download
- **Format**: PNG 1920x1080 solid background
- **URL**: https://swatchatlas.com/images/backgrounds/gray-1920x1080.png
