CSS text-spacing-trim Property Reference
The CSS text-spacing-trim property is a experimental property in CSS Text. Review its formal syntax, computed behavior, and practical declarations.
Updated 2026-08-12
text-spacing-trim overview
The CSS text-spacing-trim property is a experimental property in CSS Text. Review its formal syntax, computed behavior, and practical declarations.
The computed value normally inherits from the parent element when no declaration wins the cascade.
Syntax and formal definition
| Field | Value |
|---|---|
| Formal syntax | space-all | normal | space-first | trim-start |
| Initial value | normal |
| Applies to | textElements |
| Inherited | Yes |
| Percentages | no |
| Computed value | asSpecified |
| Animation type | discrete |
| Media | visual |
| Specification group | CSS Text |
| Status | Experimental |
Practical examples
These declarations demonstrate valid ways to set text-spacing-trim. The initial and inherit global keywords remain available even when a property-specific value is preferable.
CSS
.reset-example {
text-spacing-trim: initial;
}
.inherit-example {
text-spacing-trim: inherit;
}
@supports (text-spacing-trim: initial) {
.supported {
text-spacing-trim: initial;
}
}