npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

nestjs-benchmark

v0.0.1

Published

NestJS benchmark performance using NodeJS and Bun

Readme

Test Performance

  • All tests are executed on MacBook Air M1 with 16G RAM 256 GB.
  • Benchmarking tool:
  • The software version:

We will test 12 threads with 100 connections in 30s and 3 rounds

Node v20 Express ~ 18k req/30s

Node v20 Fastify ~ 71k req/30s

Bun v1 Express ~ 38k req/30s (211% with Node Express)

Bun v1 Fastify ~ 58k req/30s (80% with Node Fastify)

  • The benchmark result tell us:
    • Fastify is 4x faster than Express when using NodeJS 😍!
    • Fastify is 1.5x faster than Express when using Bun 🙌
    • Bun Fastify is slower than NodeJS Fastify??? 😮
    • Bun Express is 2x faster than NodeJS Express 😂

Test Build Package Dependencies

  • All tests are executed on MacBook Air M1 with 16G RAM 256 GB.
  • Now we try to install with >= 1000 packages dependencies so that we can checkout Bun or Pnpm faster
    • Bun v1.0.3
    • Pnpm v8.2.0

Without lockfile

Pnpm -> Done 24.1s

With lockfile

Pnpm without lockfile -> 5.9s

Feeling

  • With the benchmark result above. I surprise when Express (Bun) is increase performance but Fastify (Bun) is decrease performance
  • But this is only testing healthcheck so it not represent Bun can be improve NestJS faster than NodeJS
  • If your project is dependencies a lot of library or third-party so using Bun with Fastify is the good option to choose

Want to try in your computer

brew install wrk
  • To start with NodeJS
# install package dependencies
pnpm install
# start server
## Express
pnpm run start:dev
## Fastify
pnpm run start:dev -- --platform=fastify
  • To start with Bun
# install package dependencies
bun install
# start server
## Express
bun run src/main.ts
## Fastify
bun run src/main.ts --platform=fastify