I was expecting a speed boost…but nope
-
My idea was exporting to HTML to get a super-fast site, as I am using Divi and WP, and DIVI is heavy.
Result…same or worst…any clue?
I wanted to export HTML, as was easier than a Headless WP…:(
-
Hi @nicosaboti,
It’s a good question, thought I had an in-depth response somewhere from before, but couldn’t quickly find it, let me address here.
There are various pieces in the speed from a user entering your URL and the page being full loaded for them:
– browser caching
– DNS resolution
– edge caching
– server response time
– page content size
– page rendering timeBy simply converting to static, but hosting on the same server, we’re only really adjusting the server response time and if the server is able to handle the amount of requests without being overloaded/degrading performance, then there may be no difference (or negative performance, depending on if the server is optimized to serve static content or not).
If you’re page load size, with lots of HTML markup, images, CSS, JS, etc is say 1MB in the situation above, it’s still 1MB that has to make it to the user from your server – so like 1 KG of feathers vs 1 KG of bricks – little to no difference.
Let’s call that “on-page” optimizations, where improving the total content size will improve speeds regardless of where and how it’s hosted.
When you’ve trimmed that down as far as you can (ie, quick-win using the Autoptimize plugin), then you can move further down the chain and look at the server-response, caching and DNS speeds.
One of the biggest performance benefits that going static opens up is getting your whole site delivered from edge servers closest to your users. One of the fastest options today is hosting on S3 + CloudFront, others that may be similar are CloudFlare Workers. A little further down I’d put Netlify. This also depends on your user’s location. CloudFront/Cloudflare are generally fast globally. If you have a large amount of Indian visitors, then BunnyCDN may even offer better speeds, due to their investments in datacenters in that region. None of this is scientifically tested by me, so best to do your own testing. wp2static.com for example, is currently hosted on S3 + CloudFront. gulshankumar.net is one user hosting on BunnyCDN.
The other big performance benefit of static is the scalability. Testing 1 WP site with 1 user visiting the site vs 1,000 or 10,000 simultaneous visitors is very different. Most dynamic WordPress sites will not handle many concurrent users (without optimization/$$). That also still leaves the security vulnerabilities of a WordPress site exposed (another major benefit of going static, but will keep this focused on performance).
So, in testing, I suggest looking at which specific parts of your site loading are slow and address them, with the worst offenders first to get the most ROI.
Lastly, let’s look at extremes of caching:
If your whole site was cached forever on a user’s computer/browser, it would load immediately – awesome! But, how to ensure they get changes to the site? I’m not really well versed with browser-caching, edge-caching, but believe it to be a compromise one needs to make. Do you expect more repeat visitors than first-time users? Are those who are return visitors less likely to care about a slower load time as they’ve already invested themselves/hit engagement point with your content? Are you seeing such massive traffic that cache hits significantly affect your costs?
When using CloudFront, Cloudflare or such CDNs without a static site, just as a caching layer in front of your website, then the first request when there is a cache-miss, will hit your server. If you have many concurrent users, that can still bring down your dynamic WordPress site, similar to relying on caching plugins.
By hosting your whole site statically on “the edge”, there’s more chance users will get the site very quickly from their nearest location. I believe these providers handle things differently, so may only propagate the content to all of its edge servers based on demand, but generally, you’ll still get very fast initial page loads, even if it has to pull the content from a further location. This is thanks to their networks being so performant in general.
Most popular WordPress hosting isn’t about blazing performance. It’s about making $ by selling as many recurring subscriptions as possible, offering quick support to appease people and upselling you to slightly better performance.
Hope that gives a few ideas. Please let me know how your journey goes!
Cheers,
Leon
Wow Leon thanks of all, thank you.
Probably is not the first time someone asks, but the answer you provide has a lot of content.
I thought that many of the issues you mention your directly related to WP, and I see those are “global”.
I usually optimize WP with plugins and all the only suggestions, I was trying to get out of that kind of practice with an HTML site or Headless CMS.
This site was not optimized, I will try again after it is optimized, to check the differences.
Thanks!I am Sorry, but I still have my doubts. If I have to do all the same performance tasks as in WP, I don’t have any advantage in speed (I understand the security advantage).
But the plugin site says:
“WP2Static is a unique security and performance plugin for WordPress. It generates a snapshot of your WordPress site, which looks identical to your site’s audience, but with the complicated parts of a WordPress site removed from behind the scenes.”@nicosaboti – continuing on from above long description…
If you want to see how your site behaves with 1 user vs 1000 users, you can try something like wrk benchmarking tool: https://github.com/wg/wrk
If you run that with a bunch of connections against both a dynamic WP site and a static export of that site, you should see the requests per second, average response time and error rate vary extremely. The dynamic WP site will not be able to continually deliver quick responses to a large number of requests (imagine many site visitors).
If you don’t have or expect a large number of visitors to your site, maybe don’t worry about performance. There is a point of diminishing returns for any site/optimization.
WP2Static may still offer convincing security benefits to you then, but I’m not doing a hard sell (of a free software!) – just trying to clarify the potential benefits.
Who are your users? Are they on the same internet connection as you which has good connectivity speeds to your site? If those are the only ones, then regular hosting may be fine (ignoring security concerns).
If you want the globally fastest site, then going static and using top of class delivery (ie, CloudFront/Cloudflare) is still a compelling option for WP sites today.
There’s no shortcut to doing your on-page optimizations, though. If you have a heavy theme/plugins that generate a large page size, delivering that from a slow or fast server will still be serving too much content.
Again, every site is different. Is your content compelling for users or does it need sexying up with pretty designs? Will loading an extra 100kb of fonts improve your conversion rate more than the negative effect of the slow page load?
All questions to consider and find your compromise.
If this is a commercial site – maybe compare to your competitors – how heavy are their sites, how slow are they? Being faster than them would be a good initial target. Your site probably doesn’t need to load faster than Google or handle as much traffic.
Hope that’s more food for thought ??
Cheers,
Leon
- The topic ‘I was expecting a speed boost…but nope’ is closed to new replies.