In July we rebuilt the performance of a WordPress site we manage. We are publishing every number, including the starting point, because agencies rarely show you real before and after scores.
Here is where we began, measured on Lighthouse mobile:
| Metric | Before | After |
|---|---|---|
| Performance score | 25 | 73 (peak 80) |
| Largest Contentful Paint | 12.6s | 2.9s |
| Total Blocking Time | 19,590ms | ~420ms |
| First Contentful Paint | 7.6s | 2.7s |
| Speed Index | 15.3s | 4.0s |
A Total Blocking Time of 19.6 seconds is not a typo. For nearly twenty seconds the browser’s main thread was too busy to respond to a tap. On a mid-range Android that is not a slow website, it is a broken one.
What actually caused it
Three things, in order of damage.
1. The page builder was loading for pages it never rendered
The site runs a custom template that bypasses the page builder entirely. The builder’s CSS and JavaScript were still being enqueued on every one of those pages: slider libraries, carousel modules, form scripts, an anti-spam integration, icon fonts. None of it was used. All of it was parsed.
Dequeuing the unused handles on those templates removed the overwhelming majority of that 19.6 second blocking time. This is the single most common performance problem we find on WordPress sites, and it is almost always invisible in the page itself. The page looks fine. The main thread is on fire.
2. The hero was hidden until an animation library loaded
The hero section was set to opacity zero in CSS and only revealed once GSAP had loaded and initialised. It looked elegant. It also meant the largest element on the page could not be painted until a third-party script finished downloading and executing. That was roughly ten seconds of the 12.6 second LCP.
The fix is to render the hero visible by default and let the animation enhance it, rather than gate it. If the script never loads, the visitor still gets a page. If you take one thing from this article, take that.
3. Fonts were racing the renderer
We were loading fonts from a third-party host with no preload. The browser discovered them late, and text either flashed or sat invisible. Self-hosting the variable woff2 files and preloading them removed that whole category of problem, and it removed a DNS lookup and connection to another domain at the same time.
What we did not do
We kept Hotjar. It is now the largest remaining third-party cost on the site and we know it. It earns its place because the session recordings tell us things analytics cannot. That is a deliberate trade, made with the number in front of us, which is different from not knowing the number exists.
We also did not chase a perfect 100. Past a certain point you are optimising for a lab tool rather than a person on a train with two bars of signal. We stopped when the page felt instant on a real phone.
The fix that was not code
One finding did not have a code fix. The host’s dynamic caching was switched off at server level. Static files cached correctly, but every single PHP page was a cache miss on every request. The difference we measured between a cached and uncached response on the same page was roughly 6 milliseconds against 370 milliseconds, about sixty times.
No amount of front-end work fixes that. It is a toggle in a hosting panel. Before you spend a week optimising images, check whether your host is caching your pages at all.
What we would tell you to check first
- Open your site, view source, and look at what is loading. Every stylesheet and script you cannot account for is a candidate for removal on templates that do not use it.
- Check whether anything visible is hidden until JavaScript runs. Hero sections, headings and above-the-fold images especially.
- Confirm your host is actually caching HTML, not just images and CSS.
- Only then start compressing images.
Most performance work is removal, not addition. The fastest script is the one you never send.