Step by step
- Use the yellow preview to confirm the background you intend to use. The ratios here apply specifically to #FFFF00.
- Choose black #000000 or a sufficiently dark text color. Dark gray #333333 has about 11.77:1 contrast on this yellow.
- Check the actual foreground and background in the finished design. WCAG AA requires at least 4.5:1 for normal text and 3:1 for large text; gradients and transparency need their own checks.
At a glance
| Text on #FFFF00 | Contrast ratio, rounded | WCAG AA text contrast |
|---|---|---|
| Black #000000 | 19.56:1 | Passes normal and large text |
| Dark gray #333333 | 11.77:1 | Passes normal and large text |
| White #FFFFFF | 1.07:1 | Fails normal and large text |
Related questions
Does white text pass if I make it bold?
Not at 1.07:1. Even qualifying large text needs at least 3:1 for WCAG AA contrast.
Do these numbers apply to pastel yellow?
No. Recalculate for the exact foreground and background colors. The table uses opaque #FFFF00 only.
Does passing this contrast check mean the whole page is accessible?
No. Text contrast is one requirement. Keyboard use, labels, focus visibility and other accessibility needs still matter.
More questions: yellow screen
Updated November 16, 2026.