Z-index

Utilities for controlling the stack order of an element


Class reference

ClassProperties
z-0z-index: 0;
z-10z-index: 10;
z-20z-index: 20;
z-30z-index: 30;
z-40z-index: 40;
z-50z-index: 50;
z-autoz-index: auto;

# Usage

Control the stack order (or three-dimensional positioning) of an element in Elements, regardless of order it has been displayed, using the .z-{index} utilities.

5
4
3
2
1
<div class="z-40 ...">5</div>
<div class="z-30 ...">4</div>
<div class="z-20 ...">3</div>
<div class="z-10 ...">2</div>
<div class="z-0 ...">1</div>

# Responsive

To control the z-index of an element at a specific breakpoint, add a {screen}: prefix to any existing z-index utility. For example, use md:z-50 to apply the z-50 utility at only medium screen sizes and above.

For more information about Elements’ responsive design features, check out the Responsive Design documentation.