What are Core Web Vitals? What do they do? Do they matter?

Core Web Vitals are a set of metrics that measure the user experience of a website. These metrics are designed to provide website owners and developers with a clear understanding of how their website performs in terms of loading speed, interactivity, and visual stability. The three Core Web Vitals metrics are Largest Contentful Paint (LCP), First Input Delay (FID), and Cumulative Layout Shift (CLS). These metrics are critical to delivering a good user experience on the web and are used as part of Google’s ranking algorithm to evaluate website quality.

Text of "core web vitals" pointing to LCP, FID, CLS

Here is a summary of each Core Web Vital category and its impact in table form:

CategoryDefinitionImpact
Largest Contentful Paint (LCP)Measures loading performance and the speed at which the largest content element is displayed on the page.Slow LCP can lead to poor user experience, lower engagement, and higher bounce rates.
First Input Delay (FID)Measures interactivity and the time it takes for a website to respond to user input.High FID can lead to poor user experience, lower engagement, and lower conversions.
Cumulative Layout Shift (CLS)Measures stability and the amount of unexpected layout shifts that occur on a page.High CLS can lead to poor user experience, lower engagement, and lower conversions.

Core Web Vitals are considered essential for website optimization because they directly affect the user experience of a website. A website that loads quickly, is responsive to user interactions, and doesn’t have unexpected layout shifts provides a better user experience than a site that takes too long to load, is slow to respond, and has frequent layout shifts.

Good Core Web Vitals metrics scores can improve a website’s visibility in search engine results and lead to higher engagement and conversion rates. Additionally, enhancing Core Web Vitals can help ensure a website is accessible to a broader audience, including users with slow internet connections or older devices.

The importance of Core Web Vitals lies in their ability to directly impact the user experience of a website and, in turn, positively impact the website’s search engine ranking, engagement, and conversions.

A graph showing a positive trend.

Core Web Vitals are measured using a combination of user-centered metrics and lab-based tools.

  1. User-centered metrics: These metrics are based on real-world data collected from website users. For example, the Largest Contentful Paint (LCP) metric measures the loading performance of a website by tracking the time it takes for the largest image or text block on a page to load. The First Input Delay (FID) metric measures the interactivity of a website by tracking the time it takes for the website to respond to the first user interaction (such as a click).
  2. Lab-based tools: These tools simulate a real-world browsing experience by loading websites under controlled conditions and measuring performance metrics. For example, Google PageSpeed Insights is a lab-based tool that provides website owners with a score for Core Web Vitals and recommendations for improvement.

The scores for Core Web Vitals are generated by analyzing the data collected from these sources and are intended to provide a comprehensive picture of the user experience of a website. The scores are then used to evaluate the quality of a website and can impact its search engine ranking.

The holy trinity of user experience:

1. Largest Contentful Paint (LCP)

Largest Contentful Paint (LCP) is a metric used to measure the loading performance of a website. It tracks the time it takes for the largest image or text block on a page to load and display to the user. The LCP metric is considered an essential indicator of a website’s loading speed and user experience, as it provides a clear picture of how long it takes for the main content of a page to become visible to the user.

Improving LCP involves optimizing website content and code to ensure that the largest and most essential elements of a page load quickly, providing users a smooth and fast browsing experience. A good LCP score is generally considered to be 2.5 seconds or less. Users may perceive a website with a slower LCP score as slow, which can negatively impact engagement, conversions, and overall user experience.

Largest Contentful Paint (LCP) is considered an essential metric for website performance because it directly impacts the user experience. A fast LCP score means that the main content of a page is visible to the user quickly, providing a quick and smooth browsing experience. In contrast, a slow LCP score can result in a slow and frustrating user experience, leading to high bounce rates, low engagement, and decreased conversions.

LCP is also a ranking factor for search engines such as Google. A fast LCP score can improve a website’s visibility in search engine results and increase organic traffic. In contrast, a slow LCP score can result in lower search engine rankings and reduced visibility.

In summary, the importance of LCP lies in its ability to directly impact a website’s user experience and search engine visibility. Improving LCP is crucial for providing a fast and smooth browsing experience, increasing engagement and conversions, and improving search engine rankings.

Several common issues can impact the Largest Contentful Paint (LCP) metric, including:

  1. Slow server response times: If a website’s server takes a long time to respond, it can slow down the page’s loading, affecting LCP.
  2. Large images: Large images can take a long time to load, negatively impacting LCP.
  3. Blocking CSS and JavaScript: If critical CSS and JavaScript resources are not loaded quickly, it can delay the page’s loading, affecting LCP.
  4. Third-party scripts: Third-party scripts, such as advertisements or analytics tracking code, can slow down the loading of a page, impacting LCP.
  5. Unoptimized code: Poorly optimized website code, such as long chains of render-blocking scripts, can slow down the loading of a page, affecting LCP.

Improving LCP requires identifying and fixing these issues and implementing best practices for website optimization, such as using a fast and reliable hosting provider, compressing images, and minimizing third-party scripts.

Several strategies can be used to improve the Largest Contentful Paint (LCP) metric:

  1. Optimize images: Compress images and reduce their size, or use lazy loading to delay the loading of images until they are needed.
  2. Minimize render-blocking resources: Minimize render-blocking CSS and JavaScript files by including only the critical CSS needed to display above-the-fold content and deferring the loading of non-critical resources.
  3. Improve server response time: Use a fast and reliable hosting provider, and optimize database and server configurations to reduce server response time.
  4. Minimize third-party scripts: Minimize the use of third-party scripts, and load these scripts asynchronously to prevent them from blocking the loading of the main content.
  5. Implement resource prioritization aka “Lazy Loading”: Prioritize the loading of critical resources, such as the main content, above non-critical resources, such as advertisements or tracking code. 
  6. Use code optimization techniques: Implement best practices for website code optimization, such as minimizing render-blocking scripts, using a fast and reliable hosting provider, and minimizing the use of heavy plugins.

What is Lazy Loading?

Lazy loading is a technique used in web development to defer the loading of non-critical resources until they are actually needed. This can help speed up a web page’s loading and improve performance, particularly for large or media-heavy pages.

In the context of images, lazy loading involves only loading images visible in the viewport and deferring the loading of images that are not yet visible. This can reduce the amount of data that needs to be loaded and significantly improve page load times, particularly on mobile devices with slow connections.

Lazy loading can be implemented using JavaScript or using browser APIs, such as the Intersection Observer API. The technique is supported in modern browsers and can be used with other optimization strategies, such as image compression, to further improve website performance.

2. First Input Delay (FID)

A fast FID score, typically less than 100 milliseconds, indicates that a website is responsive and provides a good user experience. A slow FID score, on the other hand, can indicate that the website is unresponsive and slow to respond to user input, resulting in a poor user experience.

Improving FID requires identifying and fixing any issues that are slowing down the responsiveness of a website, such as long task times, slow server response times, and blocking JavaScript or CSS files. By improving FID, website owners can provide a faster and more responsive experience for users, improving the overall user experience and enhancing search engine visibility.

First Input Delay (FID) is an important metric for measuring the responsiveness of a website and the user experience it provides. A fast FID score, typically less than 100 milliseconds, indicates that a website quickly responds to user interactions, providing a good user experience. On the other hand, a slow FID score can indicate that the website is unresponsive and slow to respond to user input, resulting in a poor user experience.

A fast and responsive website is crucial for providing a good user experience, particularly for websites that require user interaction, such as forms or games. A slow and unresponsive website can lead to frustration and increase the likelihood of users leaving the site, impacting both the user experience and search engine visibility.

Improving FID requires identifying and fixing any issues that are slowing down the responsiveness of a website, such as long task times, slow server response times, and blocking JavaScript or CSS files. By improving FID, website owners can provide a faster and more responsive experience for users, improving the overall user experience and search engine visibility.

Several common issues can impact the First Input Delay (FID) metric:

  1. Long task times: A task is an action that blocks the main thread and affects the responsiveness of a website. Tasks that take longer than 50 milliseconds can cause a delay in FID.
  2. Slow server response times: A slow server response time can delay the loading of critical resources, such as scripts or images, and affect the responsiveness of a website.
  3. Blocking JavaScript or CSS files: JavaScript or CSS files blocking the main thread can cause a delay in FID, as the browser cannot respond to user input until the blocking resources have loaded.
  4. Excessive layout or style recalculations: Layout or style recalculations occur when the layout or style of a page changes, and can cause a delay in FID if they take too long or occur too frequently.
  5. Unoptimized JavaScript: Unoptimized JavaScript code can take longer to execute, slowing down the responsiveness of a website and affecting FID.

Here are some examples of how to improve First Input Delay (FID):

  1. Minimize long tasks: Use techniques such as code splitting and dynamic imports to break up long tasks into smaller, more manageable pieces. Also, try to minimize the use of blocking JavaScript and CSS files and use the defer and async attributes where appropriate.
  2. Optimize server response times: Make sure that the server is configured to deliver resources as quickly as possible and that the network connection between the server and the browser is fast and reliable.
  3. Minimize blocking resources: Minimize the number of blocking JavaScript and CSS files, and use the defer and async attributes where appropriate.
  4. Reduce layout and style recalculations: Avoid making unnecessary changes to the layout or style of a page, and use techniques such as CSS transitions and animations to minimize the impact of layout changes.
  5. Optimize JavaScript code: Optimize JavaScript code to reduce the time it takes to execute, using techniques such as code splitting and dynamic imports and minimizing the use of blocking JavaScript and CSS files.

3. Cumulative Layout Shift (CLS)

Cumulative Layout Shift (CLS) is a metric used to measure the stability of a website’s layout. It quantifies the amount of unexpected layout movement that occurs during the loading of a page, including things like layout changes caused by slow-loading images or dynamically injected content.

CLS is expressed as a fractional value, with a score of 1.0, meaning that the entire viewport shifted during the page loading. The goal is to have a CLS score as close to 0 as possible, indicating that the layout of the page is stable and does not shift unexpectedly.

CLS is an important metric for measuring the user experience, as unexpected layout shifts can be disorienting and lead to frustration, mainly if they occur while a user is trying to interact with the page. By reducing CLS, website owners can provide a more stable and predictable user experience, improving the overall user experience and search engine visibility.

Cumulative Layout Shift (CLS) is an important metric for measuring the user experience, as it quantifies the stability of a website’s layout. A high CLS score can be disorienting and lead to frustration, particularly if unexpected layout shifts occur while a user tries to interact with the page.

For example, if a user is about to click a button on a page, but the button moves just before they click, it can result in a missed click and confusion for the user. This type of unexpected layout movement can lead to frustration and a poor user experience, particularly for users with motor impairments who may have trouble precisely clicking small targets.

By reducing CLS, website owners can provide a more stable and predictable user experience, improving the overall user experience and search engine visibility. A low CLS score indicates that the page layout is stable and does not shift unexpectedly, which can lead to improved user engagement and conversions, as well as higher search engine visibility and rankings.

Several common issues can impact the Cumulative Layout Shift (CLS) score of a website:

  1. Unsized images: Using images without specified width and height can cause layout shifts when the images are loaded, as the layout of the page adjusts to accommodate the new content.
  2. Web fonts: Loading web fonts can cause a layout shift if the text is initially displayed with a fallback font and then changes to the desired font once it is loaded.
  3. Dynamically injected content: Adding content dynamically to a page, such as through ads or user-generated content, can cause layout shifts if the new content pushes existing content down the page.
  4. Layout changes during page load: Making layout changes during the loading of a page, such as adding or removing elements, can cause unexpected layout shifts.
  5. Poor resource prioritization: Prioritizing resources that are not critical to the initial render of the page, such as non-critical JavaScript or large images, can result in layout shifts as the content loads.

There are several strategies that website owners can use to improve their Cumulative Layout Shift (CLS) score:

  1. Specify image dimensions: Specifying the width and height of images can prevent layout shifts when the images are loaded, as the layout of the page will already accommodate the new content.
  2. Use font loading strategies: Loading web fonts asynchronously or using font-display: swap can help prevent layout shifts caused by loading web fonts.
  3. Place ads and other dynamic content within containers: Placing dynamic content, such as ads, within containers with a specified size can help to prevent layout shifts caused by the injection of new content.
  4. Avoid layout changes during page load: Making layout changes after the page’s initial render can help prevent unexpected layout shifts during the page’s loading.
  5. Prioritize critical resources: Loading critical resources, such as above-the-fold content, first can help to prevent layout shifts as the content loads.
  6. Use animations for layout changes: Using animations to smoothly transition between layouts can help to prevent sudden and unexpected layout shifts.

Improving these metrics can lead to a better user experience, higher engagement, increased conversions, and improved search engine visibility and rankings.

In addition to optimizing for Core Web Vitals, website owners should also consider other website optimization and user experience factors, such as mobile responsiveness, website speed, and user-friendly navigation, to provide a comprehensive and positive user experience.

In short, website optimization and user experience are critical to the success of a website and should be given the attention they deserve.

In conclusion, website optimization and user experience are crucial factors for success in today’s digital landscape. A fast-loading, stable, and responsive website can lead to improved user engagement, conversions, and search engine visibility, while a slow-loading, unstable, and unresponsive website can lead to frustration and a poor user experience, potentially causing users to leave the site.

Read more from our blog