Notes

How I Used to Make Magento Fast (and How I Get 100/100 Now)

Page speed used to be a fight you could only half win. Here is how I used to claw back points on a Magento store, and how a headless build now hits a perfect score.

Adam Jackson 5 min read

Speed has always sold. A page that loads quickly keeps people on it, ranks better, and turns more visitors into customers. None of that is new. What has changed is how hard you have to work to get it.

A few years back I ran a small YouTube channel about Magento, and one of the videos was about page speed. The short version was: there are settings buried in the Magento admin that most people never touch, and turning them on can lift your score in an afternoon. That was true. It is still true. But it was also the ceiling, not the floor, and I want to show you why that matters now.

How I used to do it

I was reskinning and upgrading a client store to Magento 2.4.1, and I noticed the minification settings had never been turned on. So I ran a Lighthouse check on a normal product page, nothing fancy. The live site came back at 61 for performance. Not a disaster, but not good either.

The fix was about merging and minifying the CSS and JavaScript so the browser downloads fewer, smaller files. In developer mode those toggles sit right there in the admin under Advanced. In production mode they vanish from the screen, which is exactly why so many stores ship with them off and nobody notices. So you go in over SSH, set the merge and minify flags for both CSS and JavaScript, and redeploy the static content.

I left JavaScript bundling alone on purpose, because it tends to cause more problems than it solves. The deploy threw a couple of errors the first time, which is normal with Magento, so I forced a clean of the static content, ran the deploy again, and it went straight through. The next Lighthouse run on the dev site came back at 94. A genuine jump from a handful of settings, and worth doing on any Magento store.

The original video

Boost your Magento 2 page speed with a few admin settings, from the old AnotherMagentoDev channel.

So why am I telling you about a four-minute fix that already worked? Because 94 was about as far as that approach could take me. To get there I was still serving a full Magento front end: a heavy theme, a pile of JavaScript the platform insists on loading, and a server doing real work on every single request. Minifying and merging files trims the edges of all that. It does not remove it. There was always a hard limit, and it sat just short of a perfect score no matter how much I tuned.

How I do it now

These days I do not try to make a heavy platform lighter. I leave it out of the visitor's way entirely. The site people actually load is a static, prerendered front end built with Nuxt, served from a content delivery network close to wherever the visitor is. The content and the storefront data come from a separate system over an API, and the heavy work happens before anyone visits, not while they wait.

That is what headless means in plain terms. The shop window and the stockroom are pulled apart. The shop window is tiny and fast because it is just the bit the customer needs. The stockroom can be as big as you like, because the customer never has to load it.

The difference in practice is that a perfect score stops being a target you chase and becomes the starting point. There is simply far less to download, so there is far less to slow anything down.

A real example: Duffy's Creations

Duffy's Creations re-platformed from a traditional setup to a headless build, and the result scored 100 on Google PageSpeed. Not 94, not close enough. The full hundred.

That number is not a vanity badge. A site that loads that fast holds onto more of the people who arrive, gives Google one less reason to bury it, and feels instant on a phone over a patchy mobile signal, which is where most people now shop. The same store on the old approach would have spent its life fighting to stay in the nineties.

What changed, and why it matters to you

The honest summary is that speed used to be a maintenance job and now it is mostly baked in. With Magento I was tuning settings, redeploying static content, watching for the deploy to fall over, and still landing short of perfect. With a headless build there are fewer moving parts to go wrong, the fast result is the default rather than the reward, and the page stays fast as the site grows instead of getting slowly heavier.

For a business owner that means less time and money spent firefighting performance, a site that holds its ranking and its conversions, and one less thing on the list that quietly breaks when you are not looking. If you sell online and want this without running the platform yourself, that is what HD Commerce is for. It is a managed subscription we build and look after for you, fully customisable to how your business works, with no transaction fees taken out of your sales. You are not buying a box to maintain, and you are not handing a cut of every order to a marketplace. You get a fast store that someone keeps fast.

Originally published as a video in 2021, rewritten here.

Want a store that starts at 100, not 94

If your shop is slow and you are tired of tuning settings that only get you halfway, HD Commerce is a fully managed, fully customisable store built headless from the start, with no transaction fees on your sales.