Key Takeaways
Put an end to bouncing buttons and scrolling text while the page loads. Ways to reduce CLS score to zero.
Scrolls that Test the User's Patience: CLS
There are few experiences worse than the text you are trying to read suddenly scrolling down or the button changing its position just as you are about to click it. Google measures this instability with the Cumulative Layout Shift (CLS) metric and considers less than 0.1 as "good".
Why Does CLS Occur?
- Images and videos with unspecified sizes.
- Delayed loading fonts (FOIT/FOUT problem).
- Dynamically added ad spaces or widgets.
- Style changes due to late loading CSS files.
Solutions
- Add
widthandheightvalues to allandtags. - Space reservation using
aspect-ratioproperty in CSS - When using
font-display: swapfor font uploads, align the dimensions of the fallback font with the main font. - Create fixed-height containers for advertising spaces.
Related Service
Meta Ads & Performance
Stop ad budget leakage with server-side CAPI tracking and provably scalable ROAS