z-index

The CSS property that sets which positioned elements appear in front of others.

In more detail

Picking arbitrary large numbers leads to escalating z-index wars. A design system defines a small scale of z-index tokens, for example dropdown, sticky, modal and toast, so layers always stack predictably.

Related terms

Taught in

References