Skip to content

CSS named color

Firebrick #B22222

Firebrick (CSS keyword firebrick) has the hex code #B22222 and the RGB value rgb(178, 34, 34): a medium-dark, vivid red.

Firebrick#B22222

A deep brick red (#b22222), darker than red. It is a readable choice for error text because it passes WCAG AA on white, which pure red (3.99:1) does not.

Color codes for Firebrick

Color codes for Firebrick
CSS keywordfirebrick
HEX#B22222
RGBrgb(178, 34, 34)
HSLhsl(0, 68%, 42%)
HWBhwb(0 13% 30%)
OKLCHoklch(49.7% 0.18 26.8)
CMYK (naive, no ICC profile)cmyk(0%, 81%, 81%, 30%)
Decimal11,674,146
Hue familyReds

Contrast and accessibility

On firebrick, white text has a contrast ratio of 6.67:1 and passes AA for normal text; black text reaches 3.14:1.

WCAG 2.2 contrast ratios (success criteria 1.4.3 and 1.4.6: AA needs 4.5:1 for normal text and 3:1 for large text, AAA needs 7:1 and 4.5:1). APCA Lc is the lightness contrast from the APCA-W3 0.0.98G model proposed for WCAG 3; a higher absolute value is more readable, and Lc 75 is its suggested minimum for body text.

Contrast and accessibility
PairRatioAAAA largeAAAAAA largeAPCA Lc
Black text on firebrick3.14:1FailPassFailFail22.7
White text on firebrick6.67:1PassPassFailPass−86.4
Firebrick text on white6.67:1PassPassFailPass81.3
Firebrick text on black3.14:1FailPassFailFail−20.5

Tints and shades

Each step mixes firebrick with white (tints) or black (shades) in gamma-encoded sRGB, the same result as color-mix(in srgb, firebrick, white 25%) in CSS.

Tints (mixed with white)

  1. 5%
    #b62d2d
  2. 15%
    #be4343
  3. 25%
    #c55959
  4. 35%
    #cd6f6f
  5. 45%
    #d58585
  6. 55%
    #dc9c9c
  7. 65%
    #e4b2b2
  8. 75%
    #ecc8c8
  9. 85%
    #f3dede
  10. 95%
    #fbf4f4

Shades (mixed with black)

  1. 5%
    #a92020
  2. 15%
    #971d1d
  3. 25%
    #861a1a
  4. 35%
    #741616
  5. 45%
    #621313
  6. 55%
    #500f0f
  7. 65%
    #3e0c0c
  8. 75%
    #2d0909
  9. 85%
    #1b0505
  10. 95%
    #090202

Color harmonies

Rotating the hue in OKLCH while keeping lightness and chroma, firebrick's complementary color is #007280 (close to teal), its analogous colors are #AA2164 and #9C4700, and its triadic partners are #007B0E and #3456C7. For text on top, white gives the higher contrast.

Color harmonies
HarmonyRotationColor
Complementary+180°#007280
Analogous−30°, +30°#aa2164#9c4700
Triadic+120°, +240°#007b0e#3456c7
Split-complementary+150°, +210°#007661#006ba4

Computed in OKLCH: the hue is rotated by 180° (complementary), ±30° (analogous), ±120° (triadic) and 180° ±30° (split-complementary) while lightness and chroma stay fixed. Results that fall outside sRGB are brought back with the CSS Color 4 gamut mapping algorithm. Because this uses OKLCH, the values differ from tools that rotate hue in HSL, but every color keeps the same perceived lightness.

Warm or cool?

Firebrick is a warm color: its hue is 0° on the HSL wheel, in the red, orange and yellow range (0° to about 70°, plus reds above 330°) that is conventionally called warm.

Nearest named and Tailwind colors

Distance is ΔE OK, the Euclidean distance in OKLab multiplied by 100. Values under about 2 are hard to tell apart side by side.

Nearest CSS named colors

Nearest CSS named colors
ColorHEXΔE OK
brown#a52a2a2.6
sienna#a0522d8.4
crimson#dc143c8.9

Nearest Tailwind v4 colors

Nearest Tailwind v4 colors
ColorHEXΔE OK
red-700#c100073.4
orange-800#9f2d004.7
red-800#9f07125.3

Code snippets

CSS
.element {
  color: firebrick;
  background-color: #b22222;
  border-color: rgb(178 34 34);
  outline-color: oklch(49.7% 0.18 26.8);
}
Tailwind CSS
<div class="bg-[#b22222] text-white">...</div>

/* or register it once in your CSS (Tailwind v4) */
@theme {
  --color-firebrick: #b22222;
}
/* then use bg-firebrick, text-firebrick, border-firebrick */
SwiftUI
import SwiftUI

extension Color {
  static let firebrick = Color(red: 0.698, green: 0.133, blue: 0.133)
}
Jetpack Compose
import androidx.compose.ui.graphics.Color

val Firebrick = Color(0xFFB22222)
Flutter
import 'package:flutter/material.dart';

const firebrick = Color(0xFFB22222);
Android XML
<!-- res/values/colors.xml -->
<color name="firebrick">#B22222</color>

Frequently asked questions

What is the hex code for firebrick?
The hex code for firebrick is #B22222. The same color is rgb(178, 34, 34), hsl(0, 68%, 42%) and oklch(49.7% 0.18 26.8), and in CSS you can also write the keyword firebrick directly.
Is firebrick a warm or cool color?
Firebrick is a warm color: its hue is 0° on the HSL wheel, in the red, orange and yellow range (0° to about 70°, plus reds above 330°) that is conventionally called warm.
What colors go with firebrick?
Rotating the hue in OKLCH while keeping lightness and chroma, firebrick's complementary color is #007280 (close to teal), its analogous colors are #AA2164 and #9C4700, and its triadic partners are #007B0E and #3456C7. For text on top, white gives the higher contrast.
Can you use white text on firebrick?
White text on firebrick has a contrast ratio of 6.67:1, which passes AA for normal text but not AAA under WCAG 2.2. Black text reaches 3.14:1 and passes AA only for large text (24 px, or 18.66 px bold, and up). In APCA terms that is Lc −86.4 for white and Lc 22.7 for black.
What is the RGB value of firebrick?
Firebrick is rgb(178, 34, 34): red 178, green 34 and blue 34 on the 0 to 255 scale, or 69.8%, 13.3% and 13.3%. As a decimal integer it is 11674146.

Last reviewed by Arielton Oberek.