Core Web Vitals Interview Questions

Reviewed by Mark Dickie · Last updated

6 questions on this page you can answer and see marked on the spot. Go to the first one

Core Web Vitals are Google's set of standardized metrics that measure real-world web page performance across three dimensions: loading, interactivity, and visual stability. For an interview you should know the current three metrics (LCP, INP, CLS) along with their thresholds, what causes each to fail, and the common fixes. You should also be ready to discuss Lighthouse, PageSpeed Insights, and the web-vitals JavaScript library, and how to read field data versus lab data.

MetricWhat it measuresGoodNeeds improvementPoor
LCPTime to largest visible element render≤ 2.5 s≤ 4 s> 4 s
INPInteraction latency across the page≤ 200 ms≤ 500 ms> 500 ms
CLSVisual layout shift score≤ 0.1≤ 0.25> 0.25

What does a Core Web Vitals interview test?

Interviews on this topic check whether you can connect a metric to its root cause and propose a concrete fix. Expect to explain why INP replaced FID in March 2024, how layout shift is scored, and what the difference between lab and field data means for optimization strategy.

How do you optimize each metric?

  1. LCP: preload the largest element (often an image or hero), use a CDN, reduce server response time (TTFB), and cut render-blocking resources.
  2. INP: break up long tasks, reduce JavaScript execution time, use requestIdleCallback or scheduler.yield(), and defer non-critical scripts.
  3. CLS: set explicit width and height on images and embeds, reserve space for ads, and avoid inserting content above existing elements.

Key facts

  • Tarmac has 16 Web Platform interview questions on this topic, 10 of them on this page, at difficulty 1–5 of 5.
  • Tarmac tracked 748 job postings asking for Web Platform in November 2026.
  • Roles asking for Web Platform advertise a median base salary of US$187,116, across 152 job postings as of November 2026.
  • Tarmac last reviewed these Web Platform interview questions on 28 September 2026.

At a glance

Questions10 shown · 16 in the bank
Difficulty1–5 of 5
FormatsTrue / false, Fill in the blank, Multiple choice, Multiple answer, Short answer, Ordering, Flashcard

What you'll review

  1. core web vitals

Practice questions

Try one before you open the answer. Pick an option and press Check; it's marked on the spot.

Largest Contentful Paint (LCP) measures the time from when the user first navigates to a page to when the largest image or text block in the viewport is fully rendered. A 'Good' LCP score is 2.5 seconds or less.#

Options

Show answer

True. Largest Contentful Paint (LCP) measures how long it takes for the largest visible image or text block to render in the viewport from the start of page navigation. Google classifies an LCP of 2.5 seconds or less as 'Good', making this the target threshold for a positive user experience.

Why:

LCP does measure the render time of the largest content element visible in the viewport from the moment the user begins navigation. Google's thresholds classify LCP ≤ 2.5 s as 'Good', 2.5–4.0 s as 'Needs Improvement', and > 4.0 s as 'Poor'. Both parts of the statement are correct.

Complete the sentence: The three original Core Web Vitals introduced by Google are Largest Contentful Paint, _____, and Cumulative Layout Shift. In 2024, Google replaced First Input Delay with a new responsiveness metric called _____.#

Show answer

Complete the sentence: The three original Core Web Vitals introduced by Google are Largest Contentful Paint, First Input Delay, and Cumulative Layout Shift. In 2024, Google replaced First Input Delay with a new responsiveness metric called Interaction to Next Paint.

Why:

The original Core Web Vitals were LCP (loading), First Input Delay / FID (interactivity), and CLS (visual stability). In March 2024, Google officially replaced FID with Interaction to Next Paint (INP), which better captures the full responsiveness of a page across all user interactions rather than only the first one.

Which of the following metrics is not one of Google's three Core Web Vitals (as of 2024)?#

Options

Show answer

First Contentful Paint (FCP) is not a Core Web Vital. The three Core Web Vitals are Largest Contentful Paint (LCP), Interaction to Next Paint (INP), and Cumulative Layout Shift (CLS). FCP is a useful diagnostic metric in Lighthouse and PageSpeed Insights, but it does not count as an official Core Web Vital and does not directly influence Google Search ranking signals.

Why:

The three Core Web Vitals are LCP (loading), INP (interactivity — which replaced FID in March 2024), and CLS (visual stability). First Contentful Paint (FCP) is a diagnostic metric reported in Lighthouse and PageSpeed Insights, but it is NOT one of the three Core Web Vitals. LCP, INP, and CLS are the metrics that feed directly into Google Search ranking signals.

Complete the following Core Web Vitals thresholds:#

Show answer

Complete the following Core Web Vitals thresholds:

  • LCP should occur within 2.5 seconds for a "Good" score.
  • CLS should be less than 0.1 for a "Good" score.
  • INP should be less than 200 milliseconds for a "Good" score.
Why:

Google defines "Good" thresholds for the three Core Web Vitals as: LCP ≤ 2.5 s (measures when the largest above-the-fold content element becomes visible); CLS < 0.1 (a unitless score measuring unexpected layout shifts); and INP < 200 ms (measures end-to-end latency of user interactions). Values between the Good and Poor thresholds are rated "Needs Improvement".

A page's LCP element is a hero <img> that is present in the initial HTML and served from the same origin. The image file is a 4 MB JPEG that is displayed at 800px wide. Which changes will reduce this page's LCP? Select all that apply.#

Options

Pick every one that applies.

Show answer

Raising the hero image's fetch priority and shrinking its file size both reduce LCP when the hero image is the LCP element. fetchpriority="high" makes the browser download it sooner, and a smaller, correctly sized WebP or AVIF file cuts download time. Lazy-loading or delaying the image's request does the opposite.

Why:

The hero image is the LCP element, so LCP is determined by when that image finishes downloading and painting. Adding fetchpriority="high" raises the image's network priority so it downloads earlier. Re-encoding the oversized 4 MB JPEG as a smaller WebP or AVIF resized to the 800px display width cuts the bytes the browser must fetch, shortening the download. Adding loading="lazy" delays fetching the LCP image, which increases LCP. A synchronous script in <head> blocks parsing and rendering before the image is even requested, which delays LCP. Setting the image source only after the load event means the image is not requested until late, which also delays LCP.

A product team is trying to improve their page's Interaction to Next Paint (INP) score. Which of the following interventions reduce INP by shortening one of its three sub-parts (input delay, processing time, or presentation delay) for the measured interaction? Select all that apply.#

Options

Pick every one that applies.

Show answer

Two interventions reduce INP by shortening one of its sub-parts: (1) breaking up long JavaScript tasks with scheduler.yield() or setTimeout so the main thread is free when the user interacts (shrinks input delay), and (2) minimizing DOM size and expensive style recalculations triggered by handlers so layout and paint complete faster (shrinks presentation delay). Image format changes, HTTP/2 stream limits, and blanket requestAnimationFrame wrapping do not.

Why:

INP measures the latency of discrete interactions from input until the next frame is painted, and is decomposed into input delay, processing time, and presentation delay. Yielding long tasks with scheduler.yield() or setTimeout keeps the main thread from being blocked when the user interacts, which reduces the input delay portion of INP for subsequent interactions — a well-established optimization in Google's INP guidance. Reducing DOM size and expensive style recalculations triggered by handlers shortens the layout/paint work the browser must do after the event callback, directly reducing presentation delay. Switching image formats to WebP reduces page weight and affects LCP/transfer cost, but does not change how quickly the main thread responds to an interaction. HTTP/2 concurrent-stream limits are a network-multiplexing concern unrelated to main-thread interaction latency. Unconditionally wrapping interaction-driven DOM updates in requestAnimationFrame defers the visual update to a later frame, which generally increases presentation delay for the measured interaction; Google's INP guidance specifically warns against using rAF as a blanket wrapper for interaction visual updates for this reason.

Explain what Cumulative Layout Shift (CLS) measures under the current Core Web Vitals definition, and describe two specific, distinct root causes that commonly produce a high CLS score on a production web page. For each cause, state the recommended fix.#

Show answer

CLS measures visual stability: how much visible content unexpectedly moves while the page is being viewed. Each unexpected layout shift has a score equal to the impact fraction (the fraction of the viewport affected) multiplied by the distance fraction (how far elements moved, relative to the viewport). Shifts are grouped into session windows, where consecutive shifts are less than 1 second apart and each window lasts at most 5 seconds; the reported CLS is the largest session window's total, not the sum of all shifts on the page. Shifts that occur within 500 ms of a user input such as a click or keypress are excluded. Two common causes: (1) Images or media without explicit width/height attributes. The browser does not reserve space for them, so when they load they push content down. Fix: set width and height attributes or use aspect-ratio in CSS so the space is reserved before the resource loads. (2) Dynamically injected content, such as ad banners, cookie consent bars, or lazy-loaded components, inserted above or within already-visible content, which shifts the content below it. Fix: reserve the space up front with a placeholder of the same dimensions (for example a min-height container), or insert the content in a location that does not push visible content, such as below existing content or outside the viewport.

Why:

Current CLS (the Core Web Vitals definition since 2021) reports the largest session window of unexpected layout shifts, where shifts are grouped with gaps under 1 second and windows capped at 5 seconds. It does not sum every shift on the page. Each shift's score is impact fraction times distance fraction, and shifts right after user input are excluded. The two causes are distinct: unsized images and media, which leave no reserved space, and dynamically injected content that pushes visible content down. The fixes reserve layout space before the resource or content appears, or place injected content where it does not displace visible elements, such as below existing content or outside the viewport.

A browser navigates to a page whose LCP element is an <img>. Consider the following five milestones, where each milestone is defined as the first moment the described condition becomes true. Arrange them in the order in which they must occur.#

Put these in order

Show answer

The correct order is: TTFB → image request dispatched → first image byte received → first paint of the image → LCP entry recorded. Each milestone is a strict data-dependency of the next: the browser needs HTML bytes to discover the <img>, needs to send the request before bytes come back, needs some image bytes to paint any pixels, and per the Web Vitals spec the largest-contentful-paint renderTime corresponds to that first paint.

Why:

Each milestone is a strict data-dependency prerequisite of the next, giving a single uncontested total order. (s1) TTFB precedes everything — no HTML bytes means no parsing and no discovered <img>. (s2) The request for the image can only be dispatched after enough HTML has arrived to expose the tag or its preload hint, so s2 follows s1. (s3) The first image byte cannot arrive before the request has been sent, so s3 follows s2. (s4) The first paint of the image requires at least some image bytes to have been received and decoded (even progressive/streaming codecs need some bytes on hand), so s4 follows s3. (s5) The Web Vitals spec ties the LCP renderTime to the moment the element was first painted, so the entry cannot be recorded before that paint occurred; s5 follows s4. Note this version deliberately uses first-occurrence milestones (first byte, first paint) rather than completion gates, which sidesteps progressive-decode and tiled-rendering concerns — decode may overlap download and paint may overlap decode, but the first occurrence of each still respects this ordering.

For a single user interaction, what does its INP (Interaction to Next Paint) latency measurement actually span?#

Show answer

From the moment the browser receives the user's input to the moment it paints the next frame reflecting the visual result of that interaction — covering three parts together: input delay (time before the event handler starts, often due to a busy main thread), processing time (the handler's own execution), and presentation delay (time to render and paint the resulting frame). INP reports roughly the worst such interaction observed across the whole page visit, not just a handler's own runtime — a fast handler can still produce a slow INP if the main thread was busy beforehand or painting afterward is slow.

Why:

The common mistake is equating INP with 'how long my event handler function took.' The metric is end-to-end — input arrival to next paint — so a slow INP can come from main-thread contention before the handler even starts, or from expensive layout/paint work after it finishes, not just from the handler's own code.

Which statement correctly describes how the Cumulative Layout Shift (CLS) metric aggregates shift scores and which shifts it excludes?#

Options

Show answer

Cumulative Layout Shift (CLS) is the score of the largest session window, where windows last up to 5 seconds and close after a gap of more than 1 second between shifts. Layout shifts within 500 ms of a discrete input such as a click, tap, or key press are excluded, since those shifts are usually intentional.

Why:

CLS groups layout shifts into session windows that last at most 5 seconds and that close when there is a gap of more than 1 second between shifts. The page's CLS is the score of the largest such window. Shifts that happen shortly after a discrete input (pointerdown/mousedown, touch, or keydown), specifically within 500 ms, are flagged as having recent input and are excluded, because they are usually intentional, such as a click that expands an accordion. Scrolling is not a discrete input for this rule, so shifts within 500 ms of a scroll still count. Only the visible portion of a shifted element contributes to a shift's score, through the impact fraction. The keyed option is the only one that gets both the windowing and the exclusion rule right.

Sources

The official documentation these questions are checked against:

Related interview questions

Job market

See web-platform salaries and hiring demand from live job postings.

The other 6 questions

This page shows 10 and marks what you pick. That's as far as a page can go. A free account opens the other 6 and keeps every answer. What you miss comes back until it's right: after a day, then at longer gaps.

Start with this topic

Free · the whole bank · 100 answers per 30 days, each marked with written feedback

Interview booked? Practise the job ad instead

What moved, monthly

One email a month when the bulletin comes out: what moved in the markets we track, and the new question topics we published. Confirm your address to join. Unsubscribe any time.