Hacker News new | ask | show | jobs
by nchmy 310 days ago
> each KB of JavaScript sent to the client was costing the company $100,000 per year. How much is Kroger sending today? 2.4 Megabytes. Out of a chonky 4 MB payload. Assuming they could rebuild the site to hit a target of 450 KB, that's conservatively $435,000,000 per year.

This math isn't mathing for me, no matter how I slice it. Can someone help?

1 comments

I also think they made a mistake, but it doesn't look like a huge one?

4 MB ~= 4000 kB, (4000 kB - 450 kB) * $100,000/kB/year = $355,000,000/year

(With a bit of fiddling to get the same answer as them, I think they may have done this: (4000 kB + 350 kB) * $100,000/kB, though I wouldn't want to guess why this error happened).

Hmm. But the JS is only 2.4mb, so not sure why the 4mb is probably being used.

Whatever the case, it's still immense numbers. So large, in fact, that I was skeptical about it. But Kroger has 150 billion in revenues and 2.5 billion in profits. I have to figure the loss is revenues, not profits - that would, indeed, be too high.

Author here, good catch! This was an error from a previous draft that I forgot to update. I'll update the post to reflect the correct figures.