place-items

A shorthand for setting both align-items and justify-items in a single property. It's incredibly useful for quick centering in CSS Grid.

Quick example

.grid-container {
  display: grid;
  place-items: center;
  /* perfectly centers content both ways */
}

Quick facts

Initial value
See individual properties
Inherited
No
Applies to
all elements
Animation type
discrete

Values

align-itemsjustify-items

place-items Browser Support

Widely available Since 2015 95% global usage

This feature is well established and works across many devices and browser versions. It has been available across browsers since 2015.

Safe to use without fallbacks.

59+
45+
11+
79+
ESC