Optimizing Largest Contentful Paint (LCP) in Real-world React Applications

Dr. Oluka IsaacDr. Oluka Isaac
5 min read

How faster paint times in your React UI translate into happier users, better conversion, and healthier business metrics.

Introduction — The Business of Performance

LCP isn’t a frontend metric. It’s a product success metric.

Let’s be honest — nobody talks about LCP at product roadmap meetings.
But they should.
Because behind every slow load is:

  • A user who bounces before reading your value proposition

  • A lost signup

  • A cart abandoned

  • An ad budget wasted

If you run a digital product or write software for people who do, here’s the equation:

⚡ Faster perceived load = More engagement → More conversions → Higher revenue.

And one of the biggest culprits?
Largest Contentful Paint (LCP) — the time it takes for your app’s most important visible content to show up.

Let’s unpack what it is, how to measure it, why it often tanks in React apps, and how to fix it — with real business impact in mind.

What Exactly Is LCP?

Largest Contentful Paint (LCP) measures how long it takes the browser to render the largest visible element within the viewport. This is usually:

  • A hero image

  • A headline (<h1>)

  • A video poster

So yes, it’s the first thing that tells a user “Hey, this app is working”.
Google recommends LCP under 2.5 seconds on mobile. Beyond that, user attention drops, and bounce rate spikes.

Image showing description of an LPC

Why Should Founders and Product Teams Care?

  • First impressions drive trust.

  • 1 second delay can reduce conversions by up to 20%.

  • A low LCP score can hurt your search rankings, ad performance, and user retention.

If you’re spending money driving traffic to your React app and users are still staring at a blank screen after 3 seconds, you’re burning both time and capital.

Measuring LCP in React Apps

You can’t fix what you don’t measure. Here’s how to track LCP like a product-minded engineer:

1. Developer Tools

  • Open → Performance → Record

  • Look for LCP in the waterfall

2. Lighthouse Report

  • One-click audit inside Dev Tools

  • Gives you LCP in context of other Core Web Vitals

3. Web Vitals in Production

Use Google’s web-vitals:

import { onLCP } from 'web-vitals';

onLCP((metric) => { // Send to analytics tool reportMetric('LCP', metric.value); });

Why this matters:

Field data > lab data. Your Lighthouse score doesn’t always exactly reflect what users on 3G in Lagos or rural Texas are actually experiencing.

Tool stack used to analyze and optimize LCP in React apps.

Why React Apps Struggle With LCP

React is awesome for dynamic UIs, but its default mode (client-side rendering) defers meaningful paint until hydration happens.

Common LCP killers:

  • Large hero images loaded late

  • Custom fonts blocking text rendering

  • Heavy JS bundles delaying hydration

  • Lazy-loading everything, even above-the-fold content

React isn’t slow. But without optimization, it can behave like it is.

LCP occurs after hydration in React apps, explaining perceived slowness.

How to Improve LCP in React — with a Business Mindset

1. Prioritize Hero Content (What Users See First)

If your CTA is hidden behind a slow-loading image, your funnel is already leaking.

  • Use modern formats (.webp, .avif)

  • Use loading="eager" for above-the-fold images

  • Define width/height to avoid layout shifts

  • Avoid rendering the hero section only after hydration

<img src="/hero.webp" width={1200} height={600} alt="Smart money tracking, simplified." loading="eager" />

2. Use Font Display Strategies

Pretty fonts shouldn’t delay your pitch.

  • Use font-display: swap so text appears with fallback

  • Don’t load 9 weights when you only use 2

@font-face { font-family: 'Poppins'; src: url('/fonts/poppins.woff2') format('woff2'); font-display: swap; }

/* Without it, users see a blank heading for seconds = no message delivered = bounce.*/

3. Show Value Before Hydration

Avoid the temptation to delay rendering everything until React is fully loaded. Instead:

  • Show static content early

  • Hydrate interactive components below-the-fold

  • Use loading states only when necessary

const CTA = React.lazy(() => import('./CallToAction'));

<Suspense fallback={<div>Get started</div>}>

</Suspense>

Think like this:

Don’t block value behind JavaScript. Give users something useful instantly.

4. Reduce JS Execution Time

React apps often include everything but the traditional book libraries.

  • Audit bundle size with tools like source-map-explorer

  • Avoid third party libraries unless critical

  • Debounce high-frequency renders

  • Use functional components + memo for optimization

5. Avoid Layout Thrashing

LCP isn’t just about speed — it’s about stability.

  • Set aspect ratios for media

  • Avoid late DOM injections (e.g. third-party scripts that reflow content)

img {
aspect-ratio: 16 / 9;
width: 100%;
}

/* Google penalizes layout shifts. Users perceive it as broken UI. Both affect conversion. */

Case Study: From 4.5s to 1.9s

Before:

  • Hero image loaded lazily

  • Font loaded with no swap

  • Everything hydrated before meaningful paint

After:

  • Optimized WebP image loaded eagerly

  • font-display: swap

  • Above-the-fold content rendered first

Performance before and after optimization — LCP improved from 4.5s to 1.9s.

Result:

  • LCP dropped from 4.5s → 1.9s

  • Bounce rate dropped ~18%

  • Conversion rate increased ~11%

Final Thoughts: Performance Is Product Strategy

LCP as a product metrics:

  • affects how quickly your users “get it”

  • determines whether they stay or leave

  • influences how much revenue your product earns

As product engineers, our job isn’t just to write fast code, it’s to build fast products that solve user problems, grow metrics, and create trust.

If your user can’t see your app in under 2.5 seconds, it doesn’t matter how beautiful your dashboard is — they’re gone.

1
Subscribe to my newsletter

Read articles from Dr. Oluka Isaac directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Dr. Oluka Isaac
Dr. Oluka Isaac

I Build scalable products and write about my experience, health innovation, frontend engineering, product thinking, and the future of tech in Africa.