At Hitabis, we’re deeply involved in Green Coding — after all, we developed our own tool, Oaklean, to measure energy consumption at the code level. Our experience shows: the biggest potential is often NOT where you’d first expect it.
After comparing runtime vs. runtime, we wanted to go a step further. What about bundlers? The choice of bundler has a massive impact on production builds that process large amounts of data daily. That adds up quickly. So choosing the right bundler is a major lever for saving electricity and server costs.
We built a TypeScript project with different bundlers, then ran it 50 times with identical test data and measured energy consumption in millijoules (mJ) using our open-source tool Oaklean (https://www.oaklean.io/). We looked at an older Node version, the current one, and the LTS version.
| Bundler | Bun | Node@22 | Node@24 | Node@25 |
|---|---|---|---|---|
| Bun Bundler | 509 mJ | 897 mJ | 853 mJ | 888 mJ |
| TSC | 1103 mJ | 1547 mJ | 1493 mJ | 1403 mJ |
| esbuild | 1136 mJ | 1702 mJ | 1380 mJ | 1402 mJ |
| webpack | 1078 mJ | 1627 mJ | 1488 mJ | 1516 mJ |
| rollup | 1132 mJ | 1729 mJ | 1431 mJ | 1392 mJ |
| parcel | 1209 mJ | 1514 mJ | 1435 mJ | 1475 mJ |
1. The Bun Bundler is unbeatable: at 509 mJ it uses ~50% less than TSC and ~40% less than all other bundlers.
2. Node@24 and Node@25 are more efficient than Node@22: For the Bun Bundler, Node@24 is optimal; for TSC/TypeScript, Node@25 offers slight advantages.
3. Bun Runtime + Bun Bundler = Maximum Efficiency: the combination consumes only 509 mJ (Bun→Bun) vs. 1702 mJ (Node@22→esbuild).
The Bun Bundler is the most energy-efficient JavaScript bundler — whether for Bun or Node runtime. Combined with Bun or Node@24, energy consumption in the build process can be reduced by ~50%. For Green Coding, switching is worthwhile not just for the runtime, but also for the build tool chain.