display: contents
The display: contents CSS declaration sets an element to display only its contents, not itself.
Status
Limited availability
MDN documentation
Specifications
Browser support (view on caniuse.com)
- Chrome ❌ See crbug.com/40866683
- Chrome Android ❌ See crbug.com/40866683
- Edge ❌ See crbug.com/40866683
- Firefox ❌ See https://bugzil.la/1791648,https://bugzil.la/1553549 Vendor position : positive
- Firefox for Android ❌ See https://bugzil.la/1791648,https://bugzil.la/1553549 Vendor position : positive
- Safari ❌ See webkit.org/b/255149 Vendor position : neutral (concerns: accessibility)
- Safari on iOS ❌ See webkit.org/b/255149 Vendor position : neutral (concerns: accessibility)
Developer signals
- State of CSS 2025: usage/gamechanger_feature question
- State of CSS 2025: usage/favorite_new_features question
- State of CSS 2025: usage/css_interoperability_features question
- State of CSS 2025: reading_list/reading_list question
- State of CSS 2025: other_features/other_features_pain_points question
- State of CSS 2025: layout/layout_pain_points question
- State of CSS 2025: features/all_features question
Developer signals
Votes: 0
If you want this feature to be available in all browsers, vote for it by adding a thumbs up reaction (👍) to this GitHub issue, and leave a comment with more information.
View as JSON | Edit this feature | Report an issue | Web-features entry: source, dist