How to Improve Page Speed: 10 Practical Steps
Boosting your Google PageSpeed score and passing Core Web Vitals requires targeted engineering, not guesswork. Follow this step-by-step checklist to systematically eliminate render bottlenecks.
Modernize & Compress Media (Images & Video)
Images often make up over 60% of total payload. Convert legacy JPEG and PNG files to AVIF or WebP for 30–50% smaller file sizes with identical quality. Always specify width and height attributes to prevent layout shifts (CLS), and use loading="lazy" for below-the-fold images.
<img src="/hero.avif" alt="Hero banner" width="1200" height="600" fetchpriority="high" decoding="async" />Eliminate Render-Blocking JavaScript
Synchronous scripts in the HTML <head> halt the DOM parser. Add defer or type="module" so scripts download in parallel without delaying the initial paint. Split your bundles so only the JavaScript required for the initial viewport loads first.
<script src="/bundle.js" defer></script>Reduce Server Response Time (TTFB < 800ms)
If your origin server takes 1.5 seconds just to deliver the first HTML byte, reaching a 2.5s LCP is impossible. Cache database queries with Redis, enable page caching, and serve static HTML directly from CDN edge nodes.
Cache-Control: public, max-age=0, s-maxage=86400, stale-while-revalidate=3600Optimize Web Fonts (Prevent FOIT & FOUT)
Custom web fonts often block text rendering. Use font-display: swap to display system fallback fonts immediately. Preload critical fonts required above the fold and self-host fonts to eliminate third-party DNS handshakes.
<link rel="preload" href="/fonts/poppins.woff2" as="font" type="font/woff2" crossorigin />Break Up Long Tasks to Boost INP (< 200ms)
Any JavaScript task running longer than 50ms freezes the main thread. Break large loops into asynchronous chunks using scheduler.yield() or requestIdleCallback() so user taps and clicks can be processed immediately.
await new Promise((resolve) => setTimeout(resolve, 0)); // Yield main threadReserve Dynamic Element Dimensions for CLS
Late-loading banners, ad slots, and cookie consent modals cause content to jump suddenly. Use CSS aspect-ratio or min-height on parent containers so space is reserved before the content arrives.
.ad-slot { min-height: 250px; aspect-ratio: 16 / 9; }Audit & Lazy-Load Third-Party Scripts
Analytics, customer chat widgets, heatmaps, and remarketing pixels are often the biggest contributors to mobile sluggishness. Load chat widgets on click rather than on initial page load, and run non-essential trackers off the main thread.
// Load chat widget only after user clicks support buttonEnable HTTP/3 and Global Edge CDN
Deploy your site behind Cloudflare, Fastly, or AWS CloudFront. HTTP/3 with QUIC eliminates head-of-line blocking on packet-lossy mobile networks, improving performance for international visitors.
Protocol: HTTP/3 (QUIC) • Edge SSL Handshake < 30msLargest Contentful Paint (LCP)
Target: ≤ 2.5s
Interaction to Next Paint (INP)
Target: ≤ 200ms
Cumulative Layout Shift (CLS)
Target: ≤ 0.10
Frequently Asked Questions
Engineering answers for speed optimization
What is the fastest way to improve website loading speed?
The fastest quick wins are: 1) converting images to WebP/AVIF and setting explicit width/height; 2) deferring or async-loading non-critical JavaScript; 3) enabling server-side gzip or Brotli compression; and 4) deploying a global CDN to serve cached static assets close to your visitors.
Why is mobile PageSpeed score always lower than desktop?
Mobile tests simulate low-to-mid-range smartphone processors (with a 4x CPU slowdown factor) and throttled 4G cellular connections. JavaScript parsing, compilation, and execution take significantly longer on mobile hardware than on desktop multicore CPUs.
What causes render-blocking resources in Lighthouse?
Synchronous <script> tags and <link rel="stylesheet"> files in your HTML <head> pause the HTML parser while they are downloaded and executed. To fix this, inline critical CSS, load remaining stylesheets asynchronously, and add defer or type="module" to all scripts.
How do I fix a high Time to First Byte (TTFB)?
To bring TTFB under 800ms: optimize slow database queries, enable full-page edge caching via a CDN like Cloudflare or Fastly, upgrade server hosting, and use HTTP/2 or HTTP/3 to reduce TCP connection overhead.