Try it on your own data
Every report in this article is in the free plan. One snippet for web and apps, up to 10 sites.
Start freeTo optimize CLS, measure it in real-visitor data, find which elements shift, and fix the biggest contributor first, usually images without dimensions, banners inserted above content, ads with no reserved height and font swaps. In the worked example, three fixes take a 0.32 score under the 0.1 good threshold; the rest of the guide shows how.
What you will learn
- Good CLS is 0.1 or less at the 75th percentile; decide from field data, find elements with Lighthouse and DevTools
- Lighthouse often lists the pushed elements, not the cause: look for what arrived late with no space reserved
- Rank causes by contribution ÷ effort; in the sample, three fixes move 0.32 to 0.07
What does a CLS score actually measure?
Cumulative Layout Shift (CLS) adds up how much visible content jumps around while a page loads and while people use it. Each jump gets a layout shift score:
layout shift score = impact fraction × distance fraction
The impact fraction is the share of the viewport covered by the elements that moved (before and after positions combined). The distance fraction is how far the biggest mover travelled, as a share of the viewport. Sample data: a block of content filling 50% of the viewport height gets pushed down by a late banner by 20% of the viewport. The union of its old and new positions covers 70% of the viewport, so the score is 0.7 × 0.2 = 0.14. One small banner on one load is already past the "good" line.
The thresholds, from Google's web.dev guidance: good is 0.1 or less, poor is above 0.25, and the target is that at least 75% of page visits reach "good" (the 75th percentile, split by mobile and desktop). Two details change how you read the number:
- Shifts are grouped into session windows: bursts of shifts less than 1 second apart, capped at 5 seconds. The page's CLS is its worst window, not the sum of the whole visit.
- A shift that happens within 500 milliseconds of a tap or keypress is flagged as expected and left out. A menu that opens on click does not count; a banner that appears three seconds after load does.
If your page is above 0.1 at the 75th percentile, the goal of this guide is simple: find which elements cause the shifts, fix the biggest contributor first, and re-measure after each fix.
| Rating | CLS (75th percentile) | What to do |
|---|---|---|
| Good | 0.1 or less | Keep it there; watch after each release |
| Needs improvement | Above 0.1, up to 0.25 | Find the top two causes and fix them first |
| Poor | Above 0.25 | Audit every template; fix images and injected content before anything else |
Thresholds from Google's web.dev; the target is at least 75% of page visits rated good.
How do you measure CLS before you change anything?
Start with field data, the numbers from real visitors, because lab tools run one scripted load on one device and often show a lower CLS than people experience. Google's own guidance warns that lab results can understate it. You need two numbers per important page: the 75th percentile (P75) and the share of loads rated good.
| Source | What you get | Limit |
|---|---|---|
| Real-user monitoring in your analytics | P75 and share rated good, by page, device, country | Only for visitors whose browser reports it; needs the current script |
| Lighthouse / PageSpeed audits | One lab load, plus a list of elements that shifted | One device, one network; later shifts may be missed |
| Chrome DevTools Performance panel | Each shift with start time, score and the elements involved | You must reproduce the problem yourself |
Write down a baseline before the first fix: for example "product page: P75 CLS 0.32, 38% of loads good, mobile worse than desktop". Without it you cannot tell whether a fix worked or whether traffic simply changed.
How do you find which elements shift?
Work from the page with the worst P75 and use three tools in this order.
- Lighthouse "Avoid large layout shifts" lists the elements that shifted and their contribution to CLS. Read it with care: according to web.dev, these are often the elements that were pushed, not the one that caused the push. A paragraph moving down is the symptom; the image above it with no reserved height is the cause.
- The Performance panel in Chrome DevTools. Record a load, open the Layout Shifts track and click each shift. The summary shows the start time, the score and the shifted elements. Turn on network throttling and a mobile viewport, because shifts hide on fast connections where everything arrives before first paint.
- Field attribution with the
web-vitalslibrary. Its attribution build reports which element shifted most for real visitors. This matters for shifts that only happen at certain widths, in certain countries or when a consent banner appears.
When you find a shifting element, ask one question: what arrived late and did not have space reserved? Almost every cause below is a version of that.
What are the common causes of CLS, and what does each fix cost?
The table ranks the usual suspects. "Typical effort" is a planning estimate for a developer who already knows the codebase; it is not a benchmark.
| Cause | How to recognise it | Fix | Typical effort |
|---|---|---|---|
| Images, video and iframes without dimensions | Text jumps down when a picture loads | width and height attributes, or CSS aspect-ratio | 30 minutes per template |
| Banners and notices inserted above content | Consent bar, promo strip or app banner shoves the page down | Overlay it (fixed position) or reserve its height | 1–2 hours |
| Ads and embeds of unknown size | Slot is empty, then fills with a 250 px tall unit | min-height equal to the smallest unit; keep the placeholder if no ad loads | 1–2 hours |
| Web font swap | Headline reflows when the font arrives | font-display: optional or a size-matched fallback; preload the key font | 1–3 hours |
| Late-injected widgets and forms | A form or related-items block pops in after the article | Skeleton or fixed-height container; load on user action | 2–4 hours |
| Animations that move layout | Elements slide using top, left or height | Animate transform instead | 1 hour |
What does a worked fix order look like?
Sample data: a product page has a P75 CLS of 0.32, rated poor. Lighthouse and the Performance panel attribute the shifts to five causes (assume all happen inside one session window, so they add up):
| Cause | Contribution | Score after its fix |
|---|---|---|
| Hero image with no dimensions | 0.11 | 0.21 |
| Consent banner pushes content down | 0.08 | 0.13 |
| Ad slot with no reserved height | 0.07 (0.01 left after min-height) | 0.07 |
| Web font swap | 0.04 (0.01 left after size-matched fallback) | 0.04 |
| Related-products widget | 0.02 | 0.02 |
Check the arithmetic: 0.11 + 0.08 + 0.07 + 0.04 + 0.02 = 0.32. After the image fix 0.32 − 0.11 = 0.21; after the banner 0.21 − 0.08 = 0.13; after the ad slot 0.13 − 0.06 = 0.07; after the font 0.07 − 0.03 = 0.04; after the widget 0.04 − 0.02 = 0.02.
Two points follow from this. First, the page crosses the 0.1 line after three fixes, the ones with the biggest contribution and the least work, so you can stop and ship at that point. Second, order by contribution ÷ effort, not by what is most interesting: the image attribute change takes 30 minutes and removes a third of the problem. Re-measure after each change; if the number does not move, you fixed a symptom.
CLS contribution by cause
sample page, score pointsHow do you stop images, video and embeds from shifting?
Give the browser the aspect ratio before the file arrives:
<img src="hero.jpg" width="1200" height="630" alt="…">
img { max-width: 100vw; height: auto; }
With width and height set, modern browsers compute the ratio and reserve the space even when CSS makes the image fluid. For video poster frames and iframes (maps, video embeds) use aspect-ratio: 16 / 9 on the container. For ad slots and embeds whose size varies, set min-height to the smallest size the content can have, so that the worst case is a small shift rather than a big one. If no ad loads, keep the empty box; collapsing it is itself a shift. Content that arrives late should sit lower on the page, where it moves less of the viewport.
How do you handle banners, cookie notices and injected content?
The classic mistake is inserting a bar at the top of the document after the page has painted. Three safe options:
- Overlay it. A fixed-position bar at the bottom or top of the viewport does not push anything.
- Reserve the space in the first paint, even if the bar is hidden for returning visitors (accept the empty strip, or render the correct state on the server).
- Replace content in a fixed-size container rather than inserting new nodes into the flow, or let the user trigger the load with a "Load more" button, which falls inside the 500 ms input window.
Anything your own scripts add (A/B test variants, personalised banners, chat bubbles) belongs in the same audit. A floating chat bubble anchored to the bottom corner does not move layout, but a widget that inserts a block into the page flow does.
How do you stop web fonts from causing shifts?
A fallback font and a web font have different letter widths and line heights, so text reflows when the real font arrives. The options, from simplest to most precise:
font-display: optionalshows the web font only if it is ready by the first layout, otherwise keeps the fallback for that visit. No swap, no shift, at the price of some first visits seeing the fallback.- Preload the one or two fonts used above the fold:
<link rel="preload" as="font" …>. - Match the fallback to the web font with
size-adjust,ascent-override,descent-overrideandline-gap-overridein an@font-facefor the fallback, so the two fonts occupy almost identical boxes.
Test on a throttled connection. On a fast one the font arrives before first paint and the problem disappears from your laptop while staying on phones.
Which animations and navigation habits affect CLS?
Animating top, left, height, box-shadow or box-sizing forces layout work and counts as movement. Animate transform (translate, scale, rotate) instead: composited translations do not count toward CLS. Also keep pages eligible for the back/forward cache; when a page is restored exactly as the visitor left it, no new shifts happen on the way back, which matters for category-to-product browsing.
How do you confirm the fix worked?
- Re-run the same lab check and confirm the shifted-element list shrank.
- Wait for field data. Real-user numbers move slowly because they depend on how many visits have loaded the new code; compare P75 for the same page and device for a week before and after, not day over day.
- Check per device. Mobile usually fails first because fonts and ads load later and viewports are smaller.
- Mark the release date on your charts so the next person can see which deploy changed the score.
Rule of thumb: if P75 is under 0.1 but "share rated good" is still under 75%, look for a rare shifting path (one country, one browser, a logged-in state) rather than tuning further.
How do you check CLS by page in TapCub?
Continuing the sample page above, this is how you would follow it in TapCub:
- Open Monitoring › Performance. The Cumulative layout shift card uses the same thresholds (good at most 0.1, poor above 0.25). Switch the card to P75 and read the share rated good.
- Break down by page, then by device or country. This tells you whether the product template, mobile Safari or one market is the problem. The 0–100 score combines LCP, INP and CLS, so use the CLS card itself for this task.
- Add a date annotation under Configuration › Annotations when you ship each fix, so the trend line shows which change helped.
- Open Monitoring › Errors and the click heatmaps under All-platform analytics › Behavior › Heatmaps for the pages you fixed: people who keep clicking a button that moved away can show up as rage clicks.
TapCub reports the score for each page; it does not name the element that moved, so the root-cause work stays in DevTools or Lighthouse. If the script is blocked or an old snippet is installed, the Performance page is empty, because server time is not substituted. For the full list of speed and stability metrics see website performance metrics, and for broader speed work how to speed up a website. The definition of the metric is in the CLS glossary entry.
FAQ
What is a good CLS score?
A CLS of 0.1 or less is good, above 0.25 is poor, and anything between needs improvement. The target is that 75% of page visits (the 75th percentile, segmented by mobile and desktop) meet the good threshold.
Why is my CLS different in Lighthouse and in field data?
Lighthouse measures one scripted load on a simulated device. Field data covers every real load, including scrolling, late ads, consent banners and slow networks. Trust field data for the pass or fail decision and use Lighthouse to find the elements.
Does CLS include shifts after the user clicks?
Not if they happen within 500 milliseconds of the input; those are marked as user-initiated. Content that takes longer than that to appear after a click still counts, so reserve space for it.
Which fix reduces CLS the most?
On most templates it is missing image dimensions or a banner inserted above existing content. Rank causes by their contribution in your own attribution data and work down the list; the worked example shows how three fixes can remove 0.26 of a 0.32 score.
Does CLS affect SEO?
CLS is one of the three Core Web Vitals, so it is part of Google's page experience signals. Treat it as a tie-breaker rather than the main ranking factor, and fix it because layout jumps also cost clicks and sales.
Sources
- Google. Cumulative Layout Shift (CLS), web.dev. Thresholds, 75th percentile target, scoring formula, session windows and the 500 ms input exclusion. Checked 2026-11-23.
- Google. Optimize Cumulative Layout Shift, web.dev. Causes and fixes for images, embeds, injected content, fonts, animations and bfcache; how Lighthouse, DevTools and the web-vitals library report shifted elements. Checked 2026-11-23.
Was this article helpful?
We use your answers to fix and expand this page.
Couldn’t send. Please try again in a minute.
Thanks for the feedback. We’ll use it to improve this page.You’ve already sent feedback on this page. Thanks.

Data Analyst
Explores traffic sources, conversion funnels, and retention, using clear metric definitions and concrete examples to explain what the numbers mean.
