CSS anchor-name Property Reference
The CSS anchor-name property is a experimental property in CSS Anchor Positioning. Review its formal syntax, computed behavior, and practical declarations.
Updated 2026-08-12
anchor-name overview
The CSS anchor-name property is a experimental property in CSS Anchor Positioning. Review its formal syntax, computed behavior, and practical declarations.
The property is not inherited by default. Use an explicit global keyword when inheritance is intended.
Syntax and formal definition
| Field | Value |
|---|---|
| Formal syntax | none | <dashed-ident># |
| Initial value | none |
| Applies to | allElementsThatGenerateAPrincipalBox |
| Inherited | No |
| Percentages | no |
| Computed value | asSpecified |
| Animation type | discrete |
| Media | visual |
| Specification group | CSS Anchor Positioning |
| Status | Experimental |
Practical examples
These declarations demonstrate valid ways to set anchor-name. The initial and inherit global keywords remain available even when a property-specific value is preferable.
.reset-example {
anchor-name: initial;
}
.inherit-example {
anchor-name: inherit;
}
@supports (anchor-name: initial) {
.supported {
anchor-name: initial;
}
}