25 Comments

  1. Bridget
    · Reply

    This is a very important reminder for all of us. Not just for developers – I have clients who add too many images to their homepage slideshow because they can with WordPress, or designers who design websites with slideshows and lots of images/or processor heavy interactivity, or SEO consultants who want to track everything at the expense of loading loads of external scripts from every tracking company out there. Nobody wants to wait for all that extra stuff to load.

    I enjoy and always learn something from your articles Justin. Thank you for your sharing your writing with us. :)

    Report

    • Ryan Hellyer
      · Reply

      Where possible, I find it is helpful to limit the number of size of images which can be displayed on the site. This prevents site admins from unknowingly bloating their pages. Of course they then send an email demanding you remove the limitations, but at least I can say I tried to stop them from wrecking their own site :D

      Report

  2. Linda Oyedepo
    · Reply

    This is the best advice for developers I must say. I have always said it…it’s not all about the design, but speed really matters. That’s the reason why I wouldn’t mind using 5 years old theme without an update on my blog. Some current designs suck.

    Report

  3. Sonja London
    · Reply

    @justin – Glad you are bringing articles like this to WP Tavern. I recently did a custom site for a 501c4 homeowners association of a few thousand people who live in the hills. They have few services, much like you. We had to build a very powerful website for them that would load quickly over slow internet connections and mobiles. It has been a joy optimizing for the needs of the remote audience.

    Report

  4. Luis Colomé
    · Reply

    Lots of posts about optimization are talking about the cache plugins and minimize code, but sometimes we forget the basis.
    Love the article Justin!

    Report

  5. Michael Baierl
    · Reply

    Hi Justin,
    true words… and it reminds me of the fact why mobile phones get faster and need more CPU power each year… because developers don’t care.
    If you look at the original iPhone – amazing technology and a 400MHz CPU. Was fast enough, but then people started overusing it and not caring about performance… thus a faster CPU was needed…
    Same for the web. In my opinion most developers are simply not aware of the fact, that the internet might be slow or fail.
    So – good article!
    Michael

    Report

  6. Mike Schinkel
    · Reply

    Just a quick two cents worth.

    In my experience, developers who pursue “premature optimization” usually do so to the significant detriment of maintainability.

    Some developers are so focused on performance that they write code that is a nightmare to maintain for those that follow them, and ironically those that follow them often make modifications that are have significant performance costs, in large part because the “performant” code is far to clever for others to easily figure out.

    So I think the phrase “premature optimization” is really more about making sure developers also focus on other really important aspects of coding instead of getting fixated on performance at all costs.

    And as I said, #jmtcw.

    Report

  7. Shri
    · Reply

    As owner of a WordPress theme development company i have always tried to have less and less scripts which would mean lesser fancy stuff and bundling of plugins at the cost of speed.

    We have always kept our themes simpler for that very reason with no plugins bundled in order to have a faster website experience for all of our users.

    Because most of our customers from developing countries still use 2G or 3G speed internet.

    Report

  8. Larry
    · Reply

    Really hit the nail on the head like always. There’s a need to adapt to the constant improvements

    Report

  9. lana
    · Reply

    Funny post at wptavern. Somebody should check just this post – 116 HTTP requests! Yes, 116 one blog post :) Almost half of 1,4MB page is javascript :)
    Loading more than 4s from Europe.

    This website looks like a satire to optimization. Even somebody cool will optimize this website and remove 50% code, it is still bloated mess.

    I think this is state of the web and state of the WordPress in 2019.

    Report

  10. Pimento Cheese
    · Reply

    Hear, hear!

    Web design is getting out of hand to a point when the size and performance impact of sites and apps keeps growing at a much faster rate than even the powerful processors of today can keep up with. Many sites are almost unusable without an ad/script blocker. Just look at google.com – this page looks pretty much the same is did a decade ago but uses a lot more JS and is bigger in size.

    When hunting for WP themes, my eyes are always on the lookout for ones that have “speed and small size” as one of their selling points. Unfortunately, none of the default WP themes seem to care all that much about loading scripts and stylesheets like there is no tomorrow. GeneratePress is currently my favorite theme, although there are many others to choose from as well.

    Report

  11. Doro
    · Reply

    What is the page weight of Gutenberg editor page vs. Classic Editor page in backend? Democratize publishing only with enough bandwidth?

    Report

  12. Louis Reingold
    · Reply

    Thank you for eloquently stating what I have felt for years.

    I spend half the year in Truckee. It’s 3 hours from San Francisco and it gets a bunch of rich Bay Area tourists so you’d think the internet would be fast.

    Nope. Slower than molasses.

    Using a 100kb slider library when Unslider at 5kb would have sufficed hurts me up there. A lot.

    The problem isn’t helped by performance testing tools like GTMetrix that are on extremely fast connections. 1Mb loads on those tools in about the same amount of time 1kb would. The DNS lookup takes longer than the data transfer when your connection is that fast.

    This misleads people into thinking bloated web pages aren’t a big deal. But they are.

    For many of us, in the real world, internet speed is the main bottleneck.

    I made various videos promoting Oxygen’s performance and mocking other builders that output hundreds of kilobytes of bloat. The typical response from the other side (if they’d even respond) was that I was exaggerating the issue, playing it up for marketing purposes, and that internet connections are so fast now that no one notices.

    A blank page created with Divi now loads approximately 1Mb of scripts and styles.

    I hope that Gutenberg does not go the same way. A default WP install now loads Gutenberg’s default styles on all pages of the site, even if Gutenberg was not used to write the post.

    Report

  13. TonyT
    · Reply

    I don’t envy you! You have a lot to think about in the US. Here in EU, things are totally different. We have adequate basic services for everyone, including access to the Internet. (The government sees to that, it’s one of the reasons we pay firm taxes, especially rich people.) Mobile connections are fast, we’re now transitioning from 4G to 5G.
    It’s safe to say that the vast majority of the EU-based websites are targeted for EU. This means that loading a block of common library code isn’t really worth the fuzz unless your website is meant for users in the third world or US.
    30 years ago every KB -or should I say every byte- counted; I remember stuff being coded in assembler just to make it run faster and be able to fit it on a floppy disk :) I’m glad those days are over in EU and we can now focus on UX – including speed perception. I hope some day US will catch up again!

    Report

    • Ryan Hellyer
      · Reply

      That’s not true at all. I also live in the EU, and plenty of people here have horrendously slow connections. In particularly, once their mobile data runs out, they’re throttle capped to 64 kbps.

      And even if they have no data cap, that’s no reason to needlessly load a bunch of JavaScript. Even if it downloads quickly, the poor browser still needs to parse it all.

      Report

  14. Ryan Hellyer
    · Reply

    Thanks for highlighting this issue.

    The number of times I see jQuery loaded just for one teeny tiny task which could be done with a few lines of vanilla JS is ridiculously high. I often even have to convince people that jQuery isn’t present in every WordPress site by default. People seem to think it’s the standard tool for every single job.

    Report

  15. Parbat Chaudhari
    · Reply

    I haven’t checked it on desktop but on mobile it’s certainly looks better and clean than previous design.

    Report

  16. Ryan Hellyer
    · Reply

    All this talk of optimisation and new themes is making me think of all my personal stuff which needs upgraded. Thanks for adding to my motivation Justin :) I feel a big cleanup of the themes on my personal sites may be coming up sooner rather than later :D

    Report

  17. David Olier
    · Reply

    You are quite right. I have lost hours and hours trying to make simple, reduced and optimal solutions in the first steps of so many projects. The line between, as you said, smart decisions and premature optimization is so blurred.

    But as a general rule, the simpler the better works fine. Despite the fact that sometimes complex solutions must be built.

    Report

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: