font-weight
Sets the thickness or boldness of the font. Values can be keywords like 'bold' or numbers (e.g., 400 for regular, 700 for bold).
It is documented as part of the CSS Fonts specification.
Syntax
/* Usage Example */
strong {
/* Traditional bold weight */
font-weight: 700;
}
.thin-text{
/* Uses a light weight if the font supports it */
font-weight: 300;
}
/* Syntax */
font-weight: bolder;
font-weight: lighter;
/* Global values */
font-weight: inherit;
font-weight: initial;
font-weight: revert;
font-weight: revert-layer;
font-weight: unset;
font-weight Browser support
Widely available
Since
2015 96% global usage
This feature is well established and works across many devices and browser versions. It has been available across browsers since 2015.
2+
1+
1+
12+