From a 4.4-second wait to a page that reacts instantly
A marketing home page that looked fast on a fast laptop and felt broken on a phone. The audit traced 1.24 MB of JavaScript and a 1.4 MB hero image; the rebuild shipped a 480 KB page and moved every Core Web Vital into the good band.
Largest Contentful Paint
5.80 s1.40 s
−76%
Total Blocking Time
814 ms120 ms
−85%
JavaScript shipped
1.24 MB190 KB
−85%
Lighthouse performance
3899
+61 pts
Before and after
What was slowing it down → what changed
Before
The hero image shipped as a single 2400 px PNG at 1.4 MB to every device, including phones.
After
Generated responsive AVIF and WebP derivatives, served the right width per viewport, and preloaded only the hero candidate.
Before
1.24 MB of JavaScript, because a component library was imported site-wide for a handful of components.
After
Imported per-component, split routes, and removed two unused dependencies. JavaScript dropped to 190 KB.
Before
Analytics and chat widgets loaded synchronously before first paint, blocking the main thread for over 800 ms.
After
Deferred both until the page was interactive. Analytics still records the visit, just not before the visitor can read.
Before
Custom fonts loaded without preload, so the headline re-rendered after the first paint.
After
Preloaded the two font files actually used, with metric-tuned fallbacks and font-display: swap.
Before
HTML was rebuilt on every request with no cache headers: TTFB sat at 320 ms.
After
Pre-rendered the marketing pages, served them from the edge, and cached static assets with hashed filenames. TTFB: 160 ms.
The numbers
Lighthouse, same local production build, median of five runs
Performance
3899
Accessibility
92100
Best practices
83100
SEO
91100
| Metric | Before | After | Good threshold |
|---|---|---|---|
| LCPCWV | 5.80 s | 1.40 s | ≤ 2.5 s |
| INP (lab: TBT)CWV | 814 ms | 120 ms | ≤ 200 ms |
| CLSCWV | 0.00 | 0.00 | ≤ 0.10 |
| FCP | 1.20 s | 0.60 s | ≤ 1.8 s |
| TTFB | 320 ms | 160 ms | ≤ 800 ms |
| Page size | 1.41 MB | 480 KB | ≤ 2 MB |
| JavaScript | 1.24 MB | 190 KB | ≤ 500 KB |
| Requests | 54 | 24 | ≤ 80 |
| DOM nodes | 2,694 | 1,420 | ≤ 1,500 |
Lab data, not a promise: field results depend on your visitors' devices and networks. The thresholds above are the 75th-percentile targets Google uses.
The playbook
The same order of work applies to most sites
Measure the same thing twice
Run the same page on the same local production build, five times, and report the median. Changing tools or conditions between runs is how before/after tables end up meaningless.
Fix the LCP element first
Lighthouse names the element that paints last. Optimizing anything else before that one image or heading is guessing.
Cut JavaScript before writing more
Coverage reports show which bytes actually run. Every unused import in the first-load bundle is a direct tax on INP.
Reserve space for everything
Width and height on media, fixed slots for injected banners. CLS is almost always about space that was not reserved.
Defer third parties, do not delete them
Marketing rarely accepts removing analytics. Loading it after interaction keeps the data and gives the visitor the page first.
Verify with field data
CrUX needs up to 28 days to catch up. Watch the PageSpeed Insights field section over time, not just the lab score on launch day.
What it changed
- Every Core Web Vital landed in the good band on the same hardware and connection profile.
- The page now ships 66% less weight and 85% less JavaScript than before.
- Lighthouse performance moved from 38 to 99, measured on a local production build before and after.
Check it yourself
The tools and definitions behind every number above
- PageSpeed InsightsRun a test on any public URL
- Core Web Vitals: what each metric meansLCP, INP and CLS explained, with the thresholds used on this page.
- Largest Contentful Paint (LCP)Why the hero image decides when the page feels loaded.
- Interaction to Next Paint (INP)Responsiveness, and the metric that replaced FID in 2024.
- Cumulative Layout Shift (CLS)Visual stability, and how to stop content jumping.
- Chrome UX Report (CrUX)Real-user field data, collected over a rolling 28-day window.