Compony and the climate crisis

Introduction #

Someone asked us recently if there was something that Compony couldn't fix. 

We thought long and hard about it... and it turns out that no, there is nothing Compony couldn't help fix. 

Caution this article might contain minor traces of exaggeration.

Online Global warming #

It is now a fact that we are facing the 6th mass extinction because of global warming. If we could openly generalise, we could say that this approaching doom, divided people up in to 2 camps.

Camp A is doing their bits to reduce food waste, hold governments accountable for CO2-emissions, fly less by having stay-at-home-vacations and taking the bike instead of the car on shiny days. Meanwhile camp B consists of frozen individuals captured in their personal whataboutism that seems to justify silent numbness.

If whataboutism would cause the sound of thunder, ignorance surely would be the hammer throwing it's lightning. Within the webdev community we suffer of both. No matter if you are from camp A or camp shit, we collectively hold the false believe that our work holds no responsibility in the crisis, and when approached we quickly hurdle the words "Bitcoin" and "airplanes" around. While the infrastructure of the internet is build to outlive us as individuals, it seems to take higher priority than preserving human life itself.

2% of global carbon emissions come from the electricity used by the internet. That’s the same as the global aviation industry.

What if we start comparing building heavy websites full of trackers and Javascript bundles as the equivalent of taking long flights? Then maybe you could consider canceling your flight with React Air and instead take the lean bike. You will have to wear a helmet and the selfie won't look as fabulous, but hey, at least your offspring won't hate you in the future.

Is it a bird? Is it a plane? NO! It's modern superman shipping 6MB of hero-image! 

Enough with the analogies, let's talk about the pony in the room.

What can Compony do? #

The numbers.

*Puts on a a serious looking paper hat with the words "holistic scientist" printed on it*

According to BuiltWith, 2,91% of the top 1 million websites is running on a version of Drupal. If you look at the top 10.000 websites, 1 in 10 is built with Drupal. If we would take the average of page loads on the web happening, at least 2,91% will be served by a Drupal installation. It will likely be more, as 10% of page loads of the most visited websites come from Drupal. So in order to be modest, let's say that 3% of all page loads of websites in the world is served by a Drupal.

Drupal science

*Hastily scribbles the words pseudo-science on the back of the hat*

According to the http archive an average Drupal page weighs 1877kb. from which an average 63kb comes from CSS and 327kb from JS. 

If those Drupal sites would have been built with Compony, then it's been shown in our tests, that we ship 90% less CSS and 88% less JS on average per page load. We do this by only sending along the CSS and JS that actually is needed on any given page, using the libraries API.

If we apply these fat-cutting percentages on the average page size of an average Drupal site. Then that would mean that on average, Compony would be able to avoid loading 56kb of CSS and 287kb of JS on each page load. Together that is 343kb out of a on average weighing 1877kb page. If we put this in a different light, it means that we would effectively cut away 18.27% of unneeded stuff.

Global internet consumption

*Sweat stains starts appearing on the edges of the hat*

According to a study by the ACEEE from 2012, sending 1 GB of data down the line from datacenter through the network infrastructure to rendering on the end-user's device costs about 5.12kWh. Interestingly enough 38% of that energy consumption is on the end-users device. This number, in turn is then based upon the estimation that the internet "sends" 241 billion Gigabytes per year. While this is incredibly hard to measure, I'll trust the fine people of ACEEE did their best to get as close as humanly possible to estimate this.

Putting it all together

*smelly hat slowly slides crooked while losing credibility*

If we assume that 3% of the pages on the web are served with Drupal. Then we could also say that by using Compony, we can make 3% of the web 18.27% lighter. This slippery assumption would mean that Compony has the potential to make the web 0,5481% lighter by saving 1.320.921.000 GB of data per year or saving 6.763.115 megawatt hour worth of energy.

If we trust this energy example website, this means that if all Drupal sites were using Compony, we could use the left over energy to power 676.311 average American households per year, every year. Or we could toast 78 slices of bread for each person currently alive on this planet.

*Eats the smelly paper hat, to prove his sanity and mumbles: 
...But they'll have to come over on foot ... or that toast-idea will backfire.*

A serious note #

The point of this half-serious blogpost is to both have a laugh and in the meantime point the finger at ourselves.

Have a look on websitecarbon.com to check how much the emission your latest website produces. You will find out if your hosting partner is green or not. If they are not green, unfreeze your voice online, it's free and as their consumer, you have that power.

Actual relevant sources: