WordPress Performance Optimisation

Complex WordPress sites, made fast again

The case study below is one of my own jobs: a complex WordPress site that had become slow and unstable, made to load in under a tenth of a second without changing the design or losing a single feature. I take on this work for site owners, and for web designers and agencies who need a hand with it.

Rod Fernandez

Rod Fernandez

Designer and developer

5.0 from 17 Google reviews
The diagnosis

A complex site that had quietly become slow

The site looked the part, but its main listing pages had ballooned to around 7 MB of page code and were taking over 11 seconds of server time to respond.

7 MB

of page code on the main listing pages, most of it the same styling repeated over and over and rebuilt on every visit.

Before

11.2s

of server time on the heaviest page before a visitor saw anything at all.

Before

Unstable

every attempt at caching (saving ready-made copies of pages) broke the sliders, the filters and the pop-up enquiry forms.

Before

The root cause

Around 6.4 MB of that 7 MB was the same styling code (CSS), which the page builder rebuilt for every item in the list and loaded again on every filter click. That's why caching kept breaking. More hosting wouldn't have fixed it either. The problem was in how the pages were built, and it had to be found.

The results

The same site, loading in under a tenth of a second

The pages now do the same job at a fraction of the weight. With that fixed, caching could be switched on safely, so visitors get a ready-made copy almost instantly.

Main listing page weight

Megabytes downloaded · lower is better

7.03 MBBEFORE1.01 MBAFTER-86%

Time before the page appears

Seconds of server time · lower is better

11.2sBEFORE0.03sAFTERcached
MeasureBeforeAfter
Main listing page weight7.03 MB1.01 MB (-86%)
Server time to first byte11.2sunder 0.1s
Typical visitor load (cached)6 to 11s~0.03s
Image library2.40 GB0.13 GB (-94%)
Video437 MB84 MB (-81%)
Design & every featuren/aPixel-identical, all working

Measured before and after on the same pages. Client details kept private; every figure is real, not estimated.

Verified, not claimed

Measured, pixel-checked and reviewed by the web designer who brought it to me

Pixel-exact

Automated before and after comparisons confirmed the design is completely unchanged.

Every feature

Filters, sliders, pop-up forms and CRM routing all retested in a real browser and working.

Reversible

Done on a test copy of the site first, with a full backup, so every change could be undone.

What the client said
“I can't recommend Rod highly enough. As a web designer, I'm comfortable handling most WordPress work myself, but I recently had a site that had developed some fairly complex performance and optimisation issues that were beyond my level of expertise. Rod was fantastic from start to finish. He took the time to properly investigate what was happening rather than just applying quick fixes, clearly explained the issues he found, and then worked through them methodically. The difference he has made to the site is amazing. It is significantly faster and more stable, and he managed to achieve that without compromising the design or functionality of what is quite a complex website. I wouldn't hesitate to recommend Rod to other designers, businesses or anyone needing help with a complex website.”
Anita Martin·E Digi Marketing·Verified Google review
For web designers & agencies

The person you call when the performance work gets hard

You know WordPress well. Now and then a site develops a speed or stability problem outside your usual work, and that's where I come in. I work with you, behind the scenes if you prefer, find the real cause and hand the site back faster and stable.

Where I usually come in

Page-builder and custom-loop bloat that makes pages far heavier than they need to be
Slow archives, heavy queries and caching that keeps breaking the site
Core Web Vitals and PageSpeed problems, the Google measures of how fast and steady a page feels
Migrations, hosting moves and technical work that sits outside a page builder
A separate test

Is it WordPress, or the page builder? The same page, built three ways

The case study above is one real client rescue. This is a separate test of my own. I built one page three ways and measured each in Google Lighthouse on a simulated phone, on my laptop, middle of three runs. Astro scored 94, a custom WordPress theme running the same front-end code scored 92, and WordPress with a free page builder scored 76.

The custom theme came within two points of Astro, so on that page the cost came from the page builder, not WordPress. The video shows every measurement and how I got it. Read the full write-up.

Read the transcript

Same page, three builds: 94, 92 and 76

These are the same page. Same words, same pictures, and section by section they look near enough the same standing still. Now scroll them together. Two of them hold sections in place, wipe pictures in and move with your scrolling. The third mostly just fades things in.

Fade-ins are what the free version of Elementor gives you. Its scroll effects and sticky sections are Elementor Pro features, and the rest would take custom code, which I left out on purpose, because I wanted to see what the builder does on its own. It's also the one that scored lowest on a phone, in Google's Lighthouse test on my laptop. 76, against 92 and 94, middle of three

Who's talking, and why this page?

runs. I'm Rod Fernandez. This is my opinion as a developer, and I've measured what I could to back it up. I started building websites in FrontPage, back in the early days, then Dreamweaver, then writing the code myself by hand. When WordPress caught on, the people ordering the work wanted it, because "it's what everybody uses".

I didn't really agree with that as a reason, but I built client sites on WordPress for years. In my own work, and whenever WordPress wasn't required, I used Astro and Next.js, or plain hand-written code. I'm not stuck to one page builder. I custom build everything using what I think is the best tool for the job. This is the homepage of Zeta-Hybrid Tech.

It's my own site, so there's no client anywhere in this. It's heavy on motion, far more than most local business sites need. I picked it on purpose, to see how far a page builder could go towards what I'd normally build for this kind of site. There are three versions of it. The original is built in Astro, a tool that turns my code into plain, finished pages before anyone visits, with no WordPress at all.

The second is a custom WordPress theme. It's the same design and the same code running in your browser, so the only thing that changes is the platform underneath. The third is WordPress with Elementor, the free version, built only with Elementor's own widgets and settings, with no custom code and no extra plugins.

Does a faster site change what people do?

Speed's worth caring about for one reason: it changes what people do. Vodafone, the phone company, ran a proper A B test in Europe. Half their visitors got a faster version of the same page and half got the original. The faster one showed its main content 31% sooner, and it brought in 8% more sales and 15% more leads per visit. That's published on Google's web.dev site, from March 2021.

And in Australia, about half of all web visits come from phones, so the

How did I test the three builds?

phone result counts. I measure twice and cut once. With a speed test I run it three times and quote the middle result, because one run can swing a long way. Across six runs on my laptop, with no caching, the same Elementor page scored anywhere from 68 to 76. All three builds ran on the same laptop, on the same server software, through Lighthouse on a simulated phone, swapping between the sites each round.

And so nobody can say WordPress was set up to lose, I tested the theme as WordPress ships it and with the extras a careful developer strips out, and the Elementor copy with caching

Can Elementor free match the look?

and without it. Start with what Elementor got right, because it's a lot. Standing still, section by section, the copy looks near enough the same as the original. Every word matches, and the pictures were uploaded from the same files. Even the outlined word at the top, "systems", is done with Elementor's own text outline setting.

If all you need is the look, Elementor

What happens when you scroll?

can get you there. But it wasn't possible to build the motion I coded into the other two. Not in Elementor free, with its own tools and no custom code. I haven't tested Elementor Pro, so I'm not saying Pro can't do any of this. Here are the differences you'll notice, top to bottom.

The full list is on screen. On the original, a loading screen counts up to a hundred per cent, then wipes away, and a thin bar along the top fills as you scroll. The copy has neither. Move your mouse over the spacecraft and a circle follows it, showing what's inside the hull, with a readout that tracks your position. On the copy it's a still picture of the hull, and the labels never change.

The original also swaps your mouse pointer for its own dot and ring. The copy keeps the normal pointer. On a phone, the original shows that inside view on its own. The copy shows only the hull. The words "exotic development" have a metal sheen that moves across them.

On the copy they're flat light grey. The little "scroll down" line pulses on the original and sits still on the copy. The menu on the original stays at the top as you scroll, and its text turns dark when it passes over a light section. On the copy, the menu scrolls away with the top of the page. Elementor free can fix a menu in place, but it can't change the menu's colour over the light sections, and white links on a light background would disappear.

And because Elementor free's position setting can't change between screen sizes, the spacecraft, its label and the readout are each built twice, once for desktop and once for phone, with one of them hidden at each size. Both are still in the page's code. Three of the big full-width pictures further down are built twice the same way. The strip of words under the top section scrolls sideways forever on the original. On the copy it's a still row, cut off at the right-hand edge.

In the first section, each line of text slides up out of a mask. The copy fades whole blocks up instead, from further away. The rings and the glowing orb turn and drift as you scroll on the original, and they stand still on the copy. The orb's shading is close but not the same, because Elementor free's gradients take two colours and the original uses three. The counters count up on both.

Before they start, the original reads double zero and the copy reads a single zero, because the copy fakes the leading zero with a prefix. Next, a section that holds still on the original while you scroll. The picture starts as a dimmed, rounded capsule and opens out to the full width of the screen. A cyan scan line sweeps across it, the title slides in from both sides, and three notes appear one at a time. The copy can't hold a section still with its own tools, so it shows the finished picture at full width and full brightness, with the three notes fading up in a row.

Then "How I build". On the original, three chapters fade from one to the next on a single held screen, with pictures wiping in and a progress bar filling down the side. On the copy, the three chapters are stacked one after another, so you scroll past a long stack instead of one screen, and the blinking status lines are still. In the personal software section, the original keeps the picture in place while the steps scroll past it. The picture turns and scales as you go, a dial's needle rotates, and steps two and three stay dimmed until you reach them.

On the copy, the picture scrolls away with the page and doesn't move, the needle's fixed at twelve o'clock, and all three steps are at full strength from the start. The big lines of text that slide sideways as you scroll stand still on the copy. In the toolkit list, hovering over each item swaps the picture beside it, along with its number and label, from six different pictures. On the copy, the first one stays, and the other five can't be reached. The rows slide in one by one on the original, where the copy fades the whole list in at once.

The projects section holds still on the original while its picture grows from a framed rectangle to the whole screen and a veil over it lifts. The title halves drift and a card slides up. The copy shows the finished frame, and the card's frosted-glass blur isn't there, because Elementor free has no setting for it. In each of the four project sections, the screenshots wipe into view and move at a different speed from the page, the headings drift, and the text column stays put as you scroll. On the copy, things fade in and nothing stays put.

On the original, the bold start of each fact is brighter than the rest of the sentence. On the copy it's bold but the same colour. The blinking "awaiting approval" in the terminal is still. In "Ground rules", a circle opens over the picture as you scroll, a halo turns, and a "node sync" counter runs to a hundred in step with your scrolling. On the copy you get the finished picture, and the counter counts up once when it comes into view.

In "Principles", four statements take turns on one held screen, over a progress rail and a giant outlined "no." that turns. On the copy, the four statements are stacked, there's no rail, and the "no." is still and smaller, so it doesn't sit under the text. At the end, the closing words blur into focus and the rings turn as you scroll. On the copy they're still, and the last heading doesn't rise as you reach it. The original's text sizes and spacing adjust smoothly to any window.

The copy was matched at a standard laptop size and a standard phone size, so on other window shapes the spacing drifts, and on very wide screens the text keeps growing. And by default, Elementor loads its fonts from Google, every weight and italic, where the original carries only the five font files it uses. On phones, the original doesn't hold any sections still. That part's desktop only, and so is the mouse work. The wipes, slides and counters on the original run on phones and desktops.

Most of what's on that list is the limit of Elementor free, using its own tools, with no custom code. A few are defaults or this test's rules, and they're marked. I could write the custom code to put the motion back, and that's worth saying. But then it isn't a drag-and-drop site any more.

Which build is slowest on a phone?

So the Elementor copy does less, and on a phone it's still the slowest of the three. In Lighthouse on my laptop, middle of three runs, the first thing appears on screen at two point six seconds, against one point nine for the WordPress theme and one point seven for Astro. The biggest thing on screen takes four seconds, against two point six and two point five. While it loads, the phone spends 265 milliseconds too busy to respond to a tap, against 138 and 122. It asks for 40 files, against 15 and 16, and its page code is about four times the size of the original's, or about twice once it's compressed for sending.

It isn't a bigger download overall. It's the lightest of the three, at 368 kilobytes against about 500. What it has more of is code and requests, so the phone has more work to do. From the test reports, part of the gap comes from the scripts Elementor loads on top of WordPress, and from its default of loading fonts from Google. I didn't pull those apart file by file, so I won't put a number on each.

Does caching fix it?

The fair question is caching. A caching plugin saves a finished copy of each page, so the server doesn't build it from scratch every time. I added one, WP Super Cache, and the server's response dropped from a hundred and nine milliseconds to two. The cached copy scored 79, middle of three runs on my laptop, but its own three runs went from 74 to 82, and the time to the first thing and the biggest thing on screen barely moved. So on a phone, caching made no real difference.

The server wasn't where most of the time went. All of this is local, so a real web host would add network time to every

What about on a desktop?

build. On a desktop it's closer, and the Elementor copy comes out on top. All three score between 95 and 97, middle of three runs on my laptop, and Elementor's is the 97. On a desktop its screen fills in faster, and nothing holds up the browser while it loads. It's still slower to show the first thing, point eight of a second against point four, and slower to show the biggest thing.

On a phone, it goes the other way, by a lot more.

Was it WordPress or the page builder?

Which brings me back to the second build, because the thing that slowed this page down on a phone wasn't WordPress. My custom WordPress theme runs the same code in your browser as the Astro build, and it scored 92 on a phone, middle of three runs on my laptop. That's two points behind Astro's 94. Picture for picture, it's identical: thirty-eight places down the page on a phone, every one the same. The Elementor copy, on the same WordPress, scored 76.

That's sixteen points behind the theme and eighteen behind Astro. So it's not a WordPress thing. It's more like Elementor free. It adds more code, more requests and more work for the phone, for something that works better as custom code, just like the custom theme I built in WordPress from the same code. WordPress does add things.

The page's code comes out 54% bigger, and most of the extra is WordPress's own: styles for blocks this page doesn't use, emoji support, and a tag announcing the WordPress version. A careful developer can strip most of that, and that's the lean version. In an earlier set of runs on my laptop, the lean version scored 94, middle of three. The other cost is the server. On my laptop, WordPress takes forty-four milliseconds to answer, because PHP, the language WordPress is written in, builds the page first.

The Astro page is already built, and goes out in one. It does some good things on its own, too. Upload a picture and WordPress makes smaller copies of it, so a phone can load a smaller one, without anyone writing code. That's a real strength.

What does a WordPress site ask of you?

None of this makes WordPress a bad choice. It's a different kind of site to look after. As WordPress ships, without a cache, each page is built by PHP and a database when someone asks for it. Even with a cache, they're still running on the server along with every plugin, and anything running on a server needs patching, whoever built it. In the eleven days before I built this, PHP fixed two critical flaws that could let an attacker run their own code on a server, and the US government's cyber security agency listed both as being exploited five days later.

WordPress released fixes for twenty-two security flaws on the twenty-eighth of October, though sources disagree on whether any are being exploited. And the Elementor version I used still bundles a slider library with a security issue that was open on the first of November. There's a security-setting cost too. The Astro site runs a strict policy that only lets the page use styles and scripts from its own files. As WordPress ships, this page writes seven blocks of them straight into the page, which that policy would block, so they have to be stripped, allowed through one by one, or the policy loosened.

The Astro build is plain files, with no PHP and no database behind it for a visitor to reach. Its risk sits in the build tools on my machine, and to be fair, those need patching too, and on most hosting the host keeps PHP patched for you. The difference is what's exposed to the internet, and who's responsible

What does each build tell Google and AI tools?

for it. There's one more layer you can't see. A website can describe the business to Google and to AI tools, in code that visitors never see. The original carries all of that, written by hand, and so does the custom WordPress theme, exactly the same. Lighthouse gave the Elementor copy 92 for SEO, middle of three runs on my laptop, against 100 for the original.

The gap is a missing description for Google, because I didn't allow an SEO plugin in this test. The copy has none of the hidden business details either. Anyone building it for real would add a plugin for both. To be fair, none of that needs Astro. It needs someone who knows it matters to do it.

Who should edit a business website?

Here's what I've seen of how businesses end up on a page builder. In the conversations I've had with web design agencies over the years, most of them have told me they build visually, in a page builder. The ones that say they've got a developer on staff, from what I've seen, mostly modify page-builder templates, Elementor or Divi, and paste in snippets of code from somewhere else. I've never seen evidence that they write it themselves. That's my experience, not a survey.

So most of the agencies I've spoken to recommend WordPress with a page builder, because that's what they build with. "You can edit it yourself" is a great line in a sales meeting. But a business website should be edited by people who know what each part of the page is there to do. On this page, the spacecraft picture, its label and the readout are each built twice, once for desktop and once for phone, so a change to any of them has to be made in both. You should still be able to change your prices or your opening hours.

That's different from redesigning the page. And if a client or an agency needs to add content, I can just build them a headless CMS, a custom one for the site. That's an editing screen for the content, kept separate from the site your visitors load. The site stays Astro, without having to use WordPress or a page builder. If it's a dynamic site, one that changes for each person using it, I can build that too, using Next.js or React or any other framework that works for

Which framework fits which business?

the project. So here's where I've landed. You've seen the same page three ways, and I can build any of them. On a phone, the custom WordPress theme came within two points of Astro. The page builder is what cost this page, not WordPress.

For a team that publishes every week and wants to run the site themselves, WordPress can be the right call. I'm not anti WordPress. I just don't use it for what I do, because I prefer to match what the business needs to the framework I use, rather than being stuck to a website builder and matching the business to that. If it's an app, something people log into and use, that still needs to be found on Google, I build it in Next.js or React, which are tools for building web apps. If it's a site for a local business, it's almost always Astro, which turns into fast, plain files with no PHP or database behind them, and a headless CMS if they need to add content.

Test it yourself

The Astro version of this page is live at zeta-hybrid-tech.com, so you can test it yourself. Your numbers won't match mine exactly, because it's a different machine on a different network. Run it three times and take the middle one. And if you're not sure which build your business needs, send me your website and I'll tell you straight. The free review's linked below.

Another rebuild, measured

The same business, 13 seconds down to 1.5

Why is my website so slow? Same business, 13 seconds to 1.5 seconds

A slow homepage, measured: 13 seconds to show its main content on a simulated phone (Google Lighthouse, middle of three runs). The rebuild takes 1.5 seconds. I built both of them, for a fire training business, a few years apart.

Chapters
  1. 0:0013 seconds vs 1.5, same business
  2. 0:28What happened to the first site?
  3. 1:02How much faster is the rebuild, measured?
  4. 1:47Where did the 5.4 megabytes go?
  5. 2:24Does a faster site bring more enquiries?
  6. 3:37What else changed besides speed?
  7. 4:17Why did I rebuild it in Astro?
  8. 4:41Does your site have a fix or a ceiling?
Questions people ask first

WordPress performance FAQs

Next step

Got a WordPress site that's become slow?

A slow website doesn't always need rebuilding. Send it over for a free performance review and I'll tell you what's slowing it down and what fixing it would involve.

“Rod Fernandez Design has built our website, Nords Wharf Trading Post and continues to maintain and keep our internet presence even beyond his duties.”
Billy Edwards, Nords Wharf Trading Post
5.0 from 17 Google reviews