Core Web Vitals budgets for custom websites
Budgets agreed before design, and measured the way visitors meet the page.
· 4 min read · By WebSurge Technologies
Speed is easiest to get when it is a requirement from the first design, and hardest to fix when it is a final polish. We set a performance budget before design starts and check it at every step.
The three Core Web Vitals
Google publishes three measurements of real visits, called the Core Web Vitals. A page passes when at least 75 percent of visits are rated good on each of them.
| Measure | What it captures | Rated good | Our budget |
|---|---|---|---|
| Largest contentful paint (LCP) | How soon the main content appears | 2.5 s or less | Under 1.8 s |
| Interaction to next paint (INP) | How quickly the page responds to taps and clicks | 200 ms or less | Under 100 ms |
| Cumulative layout shift (CLS) | How much the layout jumps while loading | 0.1 or less | 0 |
We also target Lighthouse scores of 95 to 100. Lighthouse is lab data from a simulated load, so it is a useful guide but not the same as what real visitors experience. Field data is reported in tools such as Search Console after enough real visits.
Techniques that move the numbers
For loading (LCP)
- Serve responsive images in a modern format such as WebP, with width and height set, and preload the first large image.
- Self-host fonts, subset them and preload only the ones used above the fold.
- Inline the critical stylesheet, or keep it small, and avoid render-blocking scripts.
- Serve pages compressed. This matters when measuring: a local test without compression shows worse numbers than visitors see.
For stability (CLS)
- Set dimensions on every image and embed, so space is reserved before they load.
- Use fallback fonts with matching size metrics, so text does not reflow when the web font arrives.
- Reserve space for banners, cookie notices and ads instead of inserting them above content.
For responsiveness (INP)
- Ship less JavaScript, and split what remains so that no single task blocks the page.
- Avoid heavy work in click handlers, and defer analytics and third-party scripts until they are needed.
An example
LuxPines is a site of 396 guides. Keeping it fast meant responsive WebP images with their sizes set, self-hosted fonts, an inlined stylesheet and almost no JavaScript. The project README records Lighthouse scores of 94 to 100 for performance and 100 for accessibility, best practices and SEO. Those are lab scores from local test runs.
Measure the way visitors meet the page
We test through compression, on a mobile profile, and with scripts that check things a score does not, such as color contrast on the rendered page. A budget that is not measured is only a wish.
How to measure, and which numbers to trust
There are two kinds of data, and they answer different questions.
- Lab data comes from a simulated visit, for example from Lighthouse. It is repeatable and good for finding causes, but it is one device on one connection.
- Field data comes from real visits. Google collects it from Chrome users in the Chrome User Experience Report, and shows it in PageSpeed Insights and in the Core Web Vitals report in Search Console. It reflects a rolling window of recent weeks, so it lags behind a fix.
Use lab data to improve and field data to confirm. If you want your own field data, Google’s open-source web-vitals script reports the three measures from real visitors.
A sensible order of work
- Find the largest element on the page, which is usually a hero image or a heading, and make it arrive early.
- Fix images: right size, modern format, dimensions set, and
fetchpriority="high"on the one that is the largest element. - Fix fonts: self-host, subset, preload the one or two that matter and match the fallback font’s metrics.
- Reduce JavaScript, and load scripts that are not needed for the first view later.
- Audit third-party scripts such as analytics, chat widgets and ads, which are the most common source of slow interaction and layout shift.
Common traps
- Lazy-loading the main image. Lazy-loading is right for images below the fold and wrong for the largest element in the first view.
- Carousels and sliders that load several large images before the first one is shown.
- Late banners. A cookie notice or promo bar that pushes the page down after it has rendered causes layout shift. Reserve its space or overlay it.
- Web fonts that swap late and change the size of every line of text.
- Interaction delays from long tasks, such as large scripts that run when a visitor taps a menu.
Keep the budget from slipping
Performance usually degrades one small addition at a time. Run the checks in the build pipeline so that a change that breaks the budget fails before it ships, and re-measure after every release that adds a script, a font or an image-heavy section.
Keep reading
- Case study: LuxPines
- Our cloud, performance and architecture service
- A technical SEO checklist for custom-built websites
Have a project in mind? Book a free consultation.