Перейти к основному содержимому

Benchmarks of JavaScript Package Managers

Last benchmarked at: Jun 14, 2026, 3:53 AM (daily updated).

This benchmark compares the performance of npm, pnpm, Yarn Classic, and Yarn PnP (check Yarn's benchmarks for any other Yarn modes that are not included here).

Each row's label lists which of cache, lockfile, and node_modules are warm/present before install runs. Quick mapping to the real world (ordered from slowest to fastest scenario):

  • clean: a brand-new clone — nothing cached, no lockfile, no node_modules.
  • cache: a developer reinstalling without a lockfile.
  • lockfile: a CI server doing its first install.
  • cache+lockfile: a developer reinstalling a known project.
  • cache+node_modules: the lockfile is deleted and install is run again.
  • node_modules: the cache and lockfile are deleted and install is run again.
  • cache+lockfile+node_modules: re-running install when nothing has changed.
  • lockfile+node_modules: the cache is deleted and install is run again.
  • update: dependency versions are bumped in package.json and install is run again.

Lots of Files

The app's package.json here

actioncachelockfilenode_modulesnpmpnpmpnpm 🦀YarnYarn PnP
install28.6s7.1s2s5.9s2.4s
install13.9s4.1s1.2s5.6s2.1s
install12.3s6s1.8s3.9s868ms
install8.8s2.2s537ms3.9s860ms
install1.7s558ms975ms5.5sn/a
install1.7s579ms74ms5.3sn/a
install1.3s509ms37ms3.5sn/a
install1.3s521ms40ms3.5sn/a
updaten/an/an/a6.3s7.8s1.8s4.2s2.1s
Graph of the alotta-files results

pnpm vs pnpm 🦀

pnpm v12 will use a new installation engine for fetching and linking written in Rust. See pacquet.

actioncachelockfilenode_modulespnpmpnpm 🦀
install7.1s2s
install6s1.8s
install4.1s1.2s
install2.2s537ms
install579ms74ms
install558ms975ms
install521ms40ms
install509ms37ms
updaten/an/an/a7.8s1.8s
Graph comparing pnpm versions on the alotta-files fixture