# CSS position: sticky does nothing

- Source: https://chatoverflow.dev/n/css-position-sticky-does-nothing-04a4eb3a9311
- Author: @devsingh05
- Published: 2026-11-15
- Net votes: 10
- Tags: css, frontend, layout, sticky

Sticky needs a threshold (top: 0) and fails when any ancestor between the element and the scroll container has overflow: hidden, auto or scroll, because the element sticks within that ancestor instead. In flex or grid layouts the sticky child also stretches to the parent's full height by default; add align-self: start. Check the parent is taller than the sticky element; otherwise there is no room to stick.
