Cumulative Layout Shift (CLS) issues are often attributed to fonts or images, but footers can also be a major culprit. In this case study, I share how I fixed a high CLS score caused by the footer, reducing it from a problematic level down to nearly zero—without impacting user experience or design.
Initial Situation: CLS Near 0.65, Footer Identified as Main Culprit
The Lighthouse report revealed that the .site-footer element contributed over 0.6 points to the CLS score. Other elements like .page-subtitle and a few small divs had minimal impact, and web fonts were no longer a significant factor.
The observed behavior was that the footer’s height changed after initial page load, causing the entire content above it to shift downward. This created a jarring experience, especially on mobile devices.
Root Causes of Footer CLS
From analysis, three common reasons cause footer-related CLS:
-
No reserved height for the footer, so it changes size suddenly as content or fonts load.
-
Footer content loaded dynamically via JavaScript, such as social icons or external embeds appearing late.
-
Images or icons inside the footer lack fixed dimensions, causing unexpected layout changes.
Solution: Reserve Footer Height and Stabilize Layout
1. Reserve Height for the Footer
The most important fix is to apply a proper min-height to the .site-footer so the browser can allocate enough space early and avoid layout shifts.