seniorCSS
Advanced Grid: What is CSS Subgrid?
Updated Apr 28, 2026
Short answer
Subgrid allows nested grid items to participate in their parent's sizing tracks, aligning nested content across sibling elements.
Deep explanation
Normally, a nested grid creates an entirely new grid context. With grid-template-columns: subgrid, the nested container adopts the column tracks of its parent. This is essential for aligning the headers, bodies, and footers of adjacent card components perfectly.
Unlock with a Pro subscription to view this section.
View pricingReal-world example
No real-world example available yet.
Unlock with a Pro subscription to view this section.
Upgrade to ProCommon mistakes
No common mistakes listed yet.
Unlock with a Pro subscription to view this section.
Upgrade to ProFollow-up questions
No follow-up questions available yet.
Unlock with a Pro subscription to view this section.
Upgrade to Pro