CLS: What is Cumulative Layout Shift?

Optimize CLS to enhance user experience, increase engagement, and improve SEO. Contact Grumft for effective web optimization solutions.


CLS Cumulative Layout Shift

Have you ever wondered why some web pages seem to jump or shift during loading, disrupting your reading or navigation? This is known as Cumulative Layout Shift (CLS), a critical metric that significantly affects the user experience on websites and applications. For publishers and advanced developers, understanding and optimizing CLS is not just about improving usability but also a crucial factor for SEO success and converting visitors into customers.

Deepening Knowledge

Causes of CLS

CLS occurs when visible elements on the page shift in a way that the user does not expect, generally due to late content loading or dynamic insertions. The main causes include:

  • Images and videos without defined dimensions: When the browser does not know the size of a resource until it is loaded, it cannot reserve the appropriate space, resulting in sudden changes in the layout.
  • Dynamic ads: Ads that load in different sizes or that adjust after the initial load can push existing content, causing shifts.
  • Inserted widgets and iframes: Third-party content that adjusts after the main page has loaded can unexpectedly alter the layout.

Impacts of CLS

A high CLS leads to a poor user experience, increasing the likelihood of frustration and site abandonment. For e-commerce sites, this can mean direct sales loss, while for publishers, it results in low engagement rates and reduced reach.

SEO Consequences

Since Google’s update included user experience as a ranking factor, a high CLS can harm your site’s visibility in search results, impacting organic traffic and monetization opportunities.

Related Metrics

Besides CLS, metrics such as First Contentful Paint (FCP) and Largest Contentful Paint (LCP) are fundamental to understanding the overall user experience, providing insights into loading speed and visual stability of the page.

Strategies to Minimize CLS

Optimization of Images and Videos

Ensure that all images and videos have dimensions specified in HTML to prevent adjustments during loading. Prefer efficient file formats like WebP for images and H.264 for videos.

Implementation of Responsive Ads

Use fixed-size ad slots or ensure that space for ads is reserved before their loading. Modern frameworks like AMP offer specific solutions to avoid shifts caused by ads.

Avoid Scripts That Change the Layout

Identify and minimize the use of scripts that modify the layout after the page loads, such as pop-ups or cookie consent bars. Modern development tools can help track and correct these scripts.

Monitoring and Continuous Testing

CLS should be regularly monitored through tools like Google PageSpeed Insights and Lighthouse. A/B testing can also be useful to compare the impact of different layout adjustments.

Useful Tools and Resources

The use of tools such as Google Lighthouse, WebPageTest, and Chrome DevTools is recommended for analysis and monitoring of CLS. These tools provide detailed reports and practical recommendations for improvements.

Case Studies and Realistic Examples

Case studies from large publishers show that improvements in CLS have resulted in a significant increase in user retention and advertising revenue. Such practical examples highlight the applicability of the mentioned strategies in daily business life.

The Washington Post

A well-known example in the digital publishing industry is The Washington Post, which implemented technical improvements on its site to optimize the loading of images and ads. This resulted in a lower CLS, improving the user experience and potentially contributing to increased user retention and advertising revenue.

Yahoo! JAPAN News

By focusing on improving their Cumulative Layout Shift (CLS), Yahoo! JAPAN News achieved notable increases in user engagement metrics. They managed a 15% increase in page views per session and a 13% increase in session duration. Their efforts also led to a 1.72 percentage point decrease in bounce rate. They continuously monitored Core Web Vitals, including CLS, using tools like Google Search Console and Lighthouse to identify and correct issues. Technical details about the optimizations are available in the engineering team’s post from Yahoo! JAPAN News.

Conclusions and Next Steps

Understanding and optimizing Cumulative Layout Shift is essential for any publisher or developer who wants to offer a superior user experience and achieve success in the competitive digital environment. It’s important to highlight that Grumft’s tags do not interfere with the user experience, maintaining the integrity of your content and layout. For more information on how to optimize your site with effective solutions, do not hesitate to contact Grumft.

This article serves as a comprehensive guide, but remember that each site is unique, and the effective implementation of strategies may vary depending on the specifics of each case. The key to success lies in customization and constant adaptation to new technologies and best practices.

Quer receber nossos conteúdos?