Skip to main content
All CollectionsEditorial Strategy & SEO
How to Avoid CLS (Cumulative Layout Shift) Issues on Your Website
How to Avoid CLS (Cumulative Layout Shift) Issues on Your Website

Learn how to avoid CLS issues and improve user experience by minimizing unexpected content shifts on your website.

S
Written by Support Newsifier
Updated over a month ago

What is CLS (Cumulative Layout Shift)?

CLS stands for "Cumulative Layout Shift," one of Google’s Core Web Vitals used to measure the quality of user experience on a website. It tracks unexpected movements on a webpage as it loads, like when an ad appears and causes content to shift suddenly. This can be frustrating for users who lose their place while reading.

A low CLS score means fewer and smaller shifts, improving the overall experience for your readers.

Preventing CLS Issues by Setting Minimum Heights for Ads

As CLS is mostly affected by ads that vary in size, it is important to focus on how Ads are served on your website if you want to solve CLS issues. Serving ads of highly varied sizes can lead to cumulative layout shifts (CLS) on the page.

As Newsifier we have built a solution to prevent these CLS issues. With this solution, you can set a fixed minimal height for your Ad positions (see the images below). If you set a minimum height for the Ads position, it means that this space will be reserved for the Ad position where the Ad loads in. Without setting this minimum height, the Ad would shift the content down, but with setting this minimum height the Ad already has a space load and there will be no layout shift. So, setting this minimum height would ensure a low CLS score and a better experience for your readers.

Steps to Set Minimum Heights for Ad Positions

  1. Go to the Ad Settings section in the Newsifier admin panel.

  2. Select the ad position where you want to set a minimum height, you can insert the script you are looking for in the search field on the ads overview page.

  3. Enter the minimum height value for that position.

Steps to Set Minimum Heights for Ad Positions in Buildifier for Newsifier v2 sites.

  1. Go to the Ad Settings section in the Newsifier admin panel.

  2. Go to Buildifier (Site Builder)

  3. Navigate to a specific page from the left sidebar.

  4. Click on the Ad-block

  5. Enter the minimum height value for that position, either while adding the block, or from the options on the right side menu.

Once you set the minimum height, your ads will load into the reserved space without shifting content. Make sure to coordinate with your ad agency to serve ads that fit within the height you’ve set. Ads larger than the reserved space may still cause layout shifts.

By setting a minimum height for your ad positions, you ensure a better experience for your visitors and avoid frustrating layout shifts.

Did this answer your question?